Bluetooth: MGMT: Fix not checking if BT_HS is enabled
commit b560a208cda0297fef6ff85bbfd58a8f0a52a543 upstream. This checks if BT_HS is enabled relecting it on MGMT_SETTING_HS instead of always reporting it as supported. Change-Id: I765cd569da2ca946c8cf5728dc91901813015d9c Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
b5d13b47dc
commit
732346770e
|
@ -1185,6 +1185,10 @@ static int set_link_security(struct sock *sk, struct hci_dev *hdev, void *data,
|
|||
|
||||
BT_DBG("request for %s", hdev->name);
|
||||
|
||||
if (!enable_hs)
|
||||
return cmd_status(sk, hdev->id, MGMT_OP_SET_HS,
|
||||
MGMT_STATUS_NOT_SUPPORTED);
|
||||
|
||||
if (!lmp_bredr_capable(hdev))
|
||||
return cmd_status(sk, hdev->id, MGMT_OP_SET_LINK_SECURITY,
|
||||
MGMT_STATUS_NOT_SUPPORTED);
|
||||
|
|
Loading…
Reference in New Issue