diff options
author | Luiz Augusto von Dentz <luiz.von.dentz@intel.com> | 2021-12-22 23:21:59 +0300 |
---|---|---|
committer | Marcel Holtmann <marcel@holtmann.org> | 2021-12-23 01:01:35 +0300 |
commit | 4fc9857ab8c6cfe2152df3288c8cf3300b929f1a (patch) | |
tree | e06266d1052627f279fe3785f98777831e9398e2 /net/bluetooth/mgmt.c | |
parent | 6cd29ec6ae5e3694b779e02da9f3e50ae4398b59 (diff) | |
download | linux-4fc9857ab8c6cfe2152df3288c8cf3300b929f1a.tar.xz |
Bluetooth: hci_sync: Add check simultaneous roles support
This attempts to check if the controller can act as both central and
peripheral simultaneously and in case it does skip suspending
advertising or in case of directed advertising don't fail if scanning.
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Diffstat (limited to 'net/bluetooth/mgmt.c')
-rw-r--r-- | net/bluetooth/mgmt.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/net/bluetooth/mgmt.c b/net/bluetooth/mgmt.c index 962bb747d2cd..3326d9459dd3 100644 --- a/net/bluetooth/mgmt.c +++ b/net/bluetooth/mgmt.c @@ -3916,10 +3916,7 @@ static int read_exp_features_info(struct sock *sk, struct hci_dev *hdev, #endif if (hdev) { - if (test_bit(HCI_QUIRK_VALID_LE_STATES, &hdev->quirks) && - (hdev->le_states[4] & 0x08) && /* Central */ - (hdev->le_states[4] & 0x40) && /* Peripheral */ - (hdev->le_states[3] & 0x10)) /* Simultaneous */ + if (hci_dev_le_state_simultaneous(hdev)) flags = BIT(0); else flags = 0; |