fix bluetooth hci_dev quirks API change since v6.16-rc7

This commit is contained in:
Jianfeng Liu
2025-07-23 11:17:24 +08:00
committed by leggewie
parent f0d1697c55
commit c093f2e581
2 changed files with 27 additions and 1 deletions

View File

@@ -534,7 +534,7 @@ driver_uwe5622() {
fi fi
fi fi
if linux-version compare "${version}" ge 6.15; then if linux-version compare "${version}" ge 6.16; then
process_patch_file "${SRC}/patch/misc/wireless-uwe5622/uwe5622-v6.16.patch" "applying" process_patch_file "${SRC}/patch/misc/wireless-uwe5622/uwe5622-v6.16.patch" "applying"
fi fi
fi fi

View File

@@ -194,3 +194,29 @@ index 4abfa9d04e1..a8e824e5742 100644
#else #else
ack_info = (struct sprdwl_tcp_ack_info *)data; ack_info = (struct sprdwl_tcp_ack_info *)data;
#endif #endif
diff --git a/drivers/bluetooth/hci_ldisc.c b/drivers/bluetooth/hci_ldisc.c
index d958822bbbd..c4bad03e409 100644
--- a/drivers/bluetooth/hci_ldisc.c
+++ b/drivers/bluetooth/hci_ldisc.c
@@ -670,7 +670,7 @@ static int hci_uart_register_dev(struct hci_uart *hu)
// bluetooth devices
if (hdev->manufacturer == 0xffff && hu->tty->driver &&
strncmp(hu->tty->driver->name, "ttyBT", 5) == 0)
- set_bit(HCI_QUIRK_BROKEN_PARK_LINK_STATUS, &hdev->quirks);
+ hci_set_quirk(hdev, HCI_QUIRK_BROKEN_PARK_LINK_STATUS);
if (test_bit(HCI_UART_RAW_DEVICE, &hu->hdev_flags))
hci_set_quirk(hdev, HCI_QUIRK_RAW_DEVICE);
diff --git a/net/bluetooth/hci_sync.c b/net/bluetooth/hci_sync.c
index b8b4e929d46..2dd886ee4ab 100644
--- a/net/bluetooth/hci_sync.c
+++ b/net/bluetooth/hci_sync.c
@@ -4190,7 +4190,7 @@ static int hci_setup_link_policy_sync(struct hci_dev *hdev)
link_policy |= HCI_LP_HOLD;
if (lmp_sniff_capable(hdev))
link_policy |= HCI_LP_SNIFF;
- if (lmp_park_capable(hdev) && !test_bit(HCI_QUIRK_BROKEN_PARK_LINK_STATUS, &hdev->quirks))
+ if (lmp_park_capable(hdev) && !hci_test_quirk(hdev, HCI_QUIRK_BROKEN_PARK_LINK_STATUS))
link_policy |= HCI_LP_PARK;
cp.policy = cpu_to_le16(link_policy);