Message ID | 1701246570-3564-2-git-send-email-quic_zijuhu@quicinc.com |
---|---|
State | Superseded |
Headers | show |
Series | Bluetooth: Support SCO offload for QCA2066 | expand |
diff --git a/net/bluetooth/hci_conn.c b/net/bluetooth/hci_conn.c index a09071059214..21b59d674717 100644 --- a/net/bluetooth/hci_conn.c +++ b/net/bluetooth/hci_conn.c @@ -346,7 +346,7 @@ static int hci_enhanced_setup_sync(struct hci_dev *hdev, void *data) bt_dev_dbg(hdev, "hcon %p", conn); /* for offload use case, codec needs to configured before opening SCO */ - if (conn->codec.data_path) + if (conn->codec.data_path && hdev->get_codec_config_data) configure_datapath_sync(hdev, &conn->codec); conn->state = BT_CONNECT;
Explicitly add non NULL checking before calling hdev->get_codec_config_data(). Signed-off-by: Zijun Hu <quic_zijuhu@quicinc.com> --- net/bluetooth/hci_conn.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)