summaryrefslogtreecommitdiff
path: root/net/bluetooth
diff options
context:
space:
mode:
Diffstat (limited to 'net/bluetooth')
-rw-r--r--net/bluetooth/mgmt.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/bluetooth/mgmt.c b/net/bluetooth/mgmt.c
index c3af3b87dbb5..3c579a45cff0 100644
--- a/net/bluetooth/mgmt.c
+++ b/net/bluetooth/mgmt.c
@@ -6102,7 +6102,7 @@ static int set_external_config(struct sock *sk, struct hci_dev *hdev,
if (hci_dev_test_flag(hdev, HCI_UNCONFIGURED) == is_configured(hdev)) {
mgmt_index_removed(hdev);
- if (test_and_change_bit(HCI_UNCONFIGURED, &hdev->dev_flags)) {
+ if (hci_dev_test_and_change_flag(hdev, HCI_UNCONFIGURED)) {
hci_dev_set_flag(hdev, HCI_CONFIG);
hci_dev_set_flag(hdev, HCI_AUTO_OFF);