mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-01-12 09:32:12 +00:00
bluetooth pull request for net:
- hci_sync: avoid dup filtering when passive scanning with adv monitor - hci_qca: don't call pwrseq_power_off() twice for QCA6390 - hci_qca: fix QCA6390 support on non-DT platforms - hci_qca: fix a NULL-pointer derefence at shutdown - l2cap: always unlock channel in l2cap_conless_channel() -----BEGIN PGP SIGNATURE----- iQJNBAABCAA3FiEE7E6oRXp8w05ovYr/9JCA4xAyCykFAmaz31QZHGx1aXoudm9u LmRlbnR6QGludGVsLmNvbQAKCRD0kIDjEDILKWFED/sEriekg1KhHB9zVz4ekw+m BXYWmGgrt0NGCEW5nOEnLhVRDsSN6uOM/dsi5OmY6PBuLZ9xa1EwNB6W6e8ExgX0 s+Sh9ADeiY8BRmyG6IFVx7vbHkYKwQgN4WKFm9tNcdrfcwCTxWXFAb37Zr3SlxcQ q2smRsSCnJaTTSGEL0+fqQo0OV/bNxDxOI2tbMlU3kKtlgiDSnW/+Ka3Fxm6gEu2 i4pUcsKP6iDw21grjkqvGgTApiqAZKlhJhz3OfBjbJVIBnaOu0BJVTubiC3nwXik VzltNIh+fz9cG1FImduEya45ajeVZuB+ATSlS2PStiBrdnBIu3C23i6lle56Xe0W CQ8nngc7+jK1dUQZdOHfE0QsXHFXWT+4BOi3AiJcXuMv1RmFig59RZWGpj8ju/qI N+segoopblHbajEvohSTN+fkx0abratLg+yWYGLb0psR8DMg+TcCiO4tS9L4EhUe eg/JoNWi+sIuB3+PjxlO/MC5FYBzVx8q3OQFxR/+t7zeBN/cjA6iR5UbBxLU7TVK tqkJAPg4pN0ZhKDMK8t+iWmSzZ2xKrMyYrDm6HvAFxbD5tqDH/pepqq15P89jBR/ x+s5t57AvqbEnKQOVeyNIEP/en4OnC2NxLfClfX5w+UwXxJI2eYgfoc7Q+2/iWzL K9g5aTokM3Uz6YUem3vOcw== =TMuy -----END PGP SIGNATURE----- Merge tag 'for-net-2024-08-07' of git://git.kernel.org/pub/scm/linux/kernel/git/bluetooth/bluetooth Luiz Augusto von Dentz says: ==================== bluetooth pull request for net: - hci_sync: avoid dup filtering when passive scanning with adv monitor - hci_qca: don't call pwrseq_power_off() twice for QCA6390 - hci_qca: fix QCA6390 support on non-DT platforms - hci_qca: fix a NULL-pointer derefence at shutdown - l2cap: always unlock channel in l2cap_conless_channel() * tag 'for-net-2024-08-07' of git://git.kernel.org/pub/scm/linux/kernel/git/bluetooth/bluetooth: Bluetooth: hci_sync: avoid dup filtering when passive scanning with adv monitor Bluetooth: l2cap: always unlock channel in l2cap_conless_channel() Bluetooth: hci_qca: fix a NULL-pointer derefence at shutdown Bluetooth: hci_qca: fix QCA6390 support on non-DT platforms Bluetooth: hci_qca: don't call pwrseq_power_off() twice for QCA6390 ==================== Link: https://patch.msgid.link/20240807210103.142483-1-luiz.dentz@gmail.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
commit
b928e7d19d
@ -2160,7 +2160,7 @@ static void qca_power_shutdown(struct hci_uart *hu)
|
||||
qcadev = serdev_device_get_drvdata(hu->serdev);
|
||||
power = qcadev->bt_power;
|
||||
|
||||
if (power->pwrseq) {
|
||||
if (power && power->pwrseq) {
|
||||
pwrseq_power_off(power->pwrseq);
|
||||
set_bit(QCA_BT_OFF, &qca->flags);
|
||||
return;
|
||||
@ -2187,10 +2187,6 @@ static void qca_power_shutdown(struct hci_uart *hu)
|
||||
}
|
||||
break;
|
||||
|
||||
case QCA_QCA6390:
|
||||
pwrseq_power_off(qcadev->bt_power->pwrseq);
|
||||
break;
|
||||
|
||||
default:
|
||||
gpiod_set_value_cansleep(qcadev->bt_en, 0);
|
||||
}
|
||||
@ -2416,11 +2412,14 @@ static int qca_serdev_probe(struct serdev_device *serdev)
|
||||
break;
|
||||
|
||||
case QCA_QCA6390:
|
||||
qcadev->bt_power->pwrseq = devm_pwrseq_get(&serdev->dev,
|
||||
"bluetooth");
|
||||
if (IS_ERR(qcadev->bt_power->pwrseq))
|
||||
return PTR_ERR(qcadev->bt_power->pwrseq);
|
||||
break;
|
||||
if (dev_of_node(&serdev->dev)) {
|
||||
qcadev->bt_power->pwrseq = devm_pwrseq_get(&serdev->dev,
|
||||
"bluetooth");
|
||||
if (IS_ERR(qcadev->bt_power->pwrseq))
|
||||
return PTR_ERR(qcadev->bt_power->pwrseq);
|
||||
break;
|
||||
}
|
||||
fallthrough;
|
||||
|
||||
default:
|
||||
qcadev->bt_en = devm_gpiod_get_optional(&serdev->dev, "enable",
|
||||
|
||||
@ -3019,6 +3019,20 @@ static int hci_passive_scan_sync(struct hci_dev *hdev)
|
||||
} else if (hci_is_adv_monitoring(hdev)) {
|
||||
window = hdev->le_scan_window_adv_monitor;
|
||||
interval = hdev->le_scan_int_adv_monitor;
|
||||
|
||||
/* Disable duplicates filter when scanning for advertisement
|
||||
* monitor for the following reasons.
|
||||
*
|
||||
* For HW pattern filtering (ex. MSFT), Realtek and Qualcomm
|
||||
* controllers ignore RSSI_Sampling_Period when the duplicates
|
||||
* filter is enabled.
|
||||
*
|
||||
* For SW pattern filtering, when we're not doing interleaved
|
||||
* scanning, it is necessary to disable duplicates filter,
|
||||
* otherwise hosts can only receive one advertisement and it's
|
||||
* impossible to know if a peer is still in range.
|
||||
*/
|
||||
filter_dups = LE_SCAN_FILTER_DUP_DISABLE;
|
||||
} else {
|
||||
window = hdev->le_scan_window;
|
||||
interval = hdev->le_scan_interval;
|
||||
|
||||
@ -6774,6 +6774,7 @@ static void l2cap_conless_channel(struct l2cap_conn *conn, __le16 psm,
|
||||
bt_cb(skb)->l2cap.psm = psm;
|
||||
|
||||
if (!chan->ops->recv(chan, skb)) {
|
||||
l2cap_chan_unlock(chan);
|
||||
l2cap_chan_put(chan);
|
||||
return;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user