2019-05-27 08:55:05 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
Bluetooth: Properly disable remote wakeup for MT7922/MT7925 on Ryzen platform
It is reported that a remote wakeup could cause MT7922/MT7925's btusb
interface completely unresponsive. Resetting the xHCI root hub doesn't
help at all, and recovering from such a state needs a power cycle.
All reports seen to be relevant to Ryzen-based laptops. These NICs are
usually used as OEM components thanks to some sort of reference designs.
Their popularity on other platforms is unclear. While there is still a
chance that the quirk may exist on other platforms, be cautious and only
apply the quirk to direct children of Ryzen platforms's root hubs for
the time being. In most cases the root hub is on the SoC or PCH, which
needs the quirk. Unfortunately, this can't distinguish root hubs on PCIe
add-in cards. Such roughness should be acceptable, as PCIe USB
controller add-in cards are less commonly used nowadays. On the other
hand, applying the quirk doesn't hurt any functionalities either, as the
device can still be used as a wakeup source if desired. Theoretically,
we could retrieve the root hub's PCI vendor ID with some hierarchy
magic, but that's too intrusive...
Meanwhile, though device_set_wakeup_capable(false) is the correct fix
for other NICs with fake remote wakeup capabilities, doing so for
MT7922/MT7925 effectively prevents it from being used as wakeup
sources as per userspace requests. Hence, return -EBUSY on runtime
suspend to prevent the interface from being autosuspended while it's
still opened, which has the same effect as
device_set_wakeup_capable(false), since disabling remote wakeup simply
causes the USB core to gate runtime autosuspend as well due to
needs_remote_wakeup == 1. The interface can be safely autosuspended as
long as remote wakeup is disabled, i.e., after closing the HCI device.
Specifically, the interface may still take the advantage of remote
wakeup in order to wake up the system from sleep if userspace has
enabled it as a wakeup source.
Fixes: e31d761628ad ("Bluetooth: btmtk: Disable remote wakeup for MT7922/MT7925")
Tested-by: Rafael Passos <rafael@rcpassos.me>
Signed-off-by: Rong Zhang <i@rong.moe>
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
2026-09-02 02:19:18 +08:00
|
|
|
|
2018-02-20 09:06:18 +01:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
2018-01-08 10:44:16 +01:00
|
|
|
|
2013-04-19 09:57:43 -07:00
|
|
|
|
2019-06-02 08:02:48 +08:00
|
|
|
|
2017-02-01 14:24:09 -08:00
|
|
|
|
|
|
|
|
|
2017-02-24 14:24:29 +08:00
|
|
|
|
2019-01-24 15:28:14 -08:00
|
|
|
|
2021-12-03 14:38:13 -08:00
|
|
|
|
2024-10-01 15:35:57 -04:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-04-16 09:53:35 +00:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2015-04-06 00:52:12 -07:00
|
|
|
|
2015-04-05 22:52:11 -07:00
|
|
|
|
2015-05-14 10:49:09 +02:00
|
|
|
|
2021-10-19 05:30:12 +08:00
|
|
|
|
2015-04-05 22:52:11 -07:00
|
|
|
|
2015-04-05 22:52:16 -07:00
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
2012-01-13 09:32:20 +10:30
|
|
|
|
|
|
|
|
|
2017-11-13 14:44:16 +01:00
|
|
|
|
2022-10-25 14:12:57 -07:00
|
|
|
|
2015-05-25 23:53:40 +05:30
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-03-03 14:17:07 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2022-03-03 14:17:07 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-12-16 21:12:47 +01:00
|
|
|
|
Bluetooth: btusb: Check for unexpected bytes when defragmenting HCI frames
Some Barrot based USB Bluetooth dongles erroneously send one extra
random byte for the HCI_OP_READ_LOCAL_EXT_FEATURES command. The
consequence of that is that the next HCI transfer is misaligned by one
byte causing undefined behavior. In most cases the response event for
the next command fails with random error code.
Since the HCI_OP_READ_LOCAL_EXT_FEATURES command is used during HCI
controller initialization, the initialization fails rendering the USB
dongle not usable.
> [59.464099] usb 1-1.3: new full-speed USB device number 11 using xhci_hcd
> [59.561617] usb 1-1.3: New USB device found, idVendor=33fa, idProduct=0012, bcdDevice=88.91
> [59.561642] usb 1-1.3: New USB device strings: Mfr=0, Product=2, SerialNumber=0
> [59.561656] usb 1-1.3: Product: UGREEN BT6.0 Adapter
> [61.720116] Bluetooth: hci1: command 0x1005 tx timeout
> [61.720167] Bluetooth: hci1: Opcode 0x1005 failed: -110
This patch was tested with the 33fa:0012 device. The info from the
/sys/kernel/debug/usb/devices is shown below:
T: Bus=01 Lev=02 Prnt=02 Port=02 Cnt=01 Dev#= 12 Spd=12 MxCh= 0
D: Ver= 2.00 Cls=e0(wlcon) Sub=01 Prot=01 MxPS=64 #Cfgs= 1
P: Vendor=33fa ProdID=0012 Rev=88.91
S: Product=UGREEN BT6.0 Adapter
C:* #Ifs= 2 Cfg#= 1 Atr=c0 MxPwr=100mA
I:* If#= 0 Alt= 0 #EPs= 3 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
E: Ad=81(I) Atr=03(Int.) MxPS= 16 Ivl=1ms
E: Ad=02(O) Atr=02(Bulk) MxPS= 64 Ivl=0ms
E: Ad=82(I) Atr=02(Bulk) MxPS= 64 Ivl=0ms
I:* If#= 1 Alt= 0 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
E: Ad=03(O) Atr=01(Isoc) MxPS= 0 Ivl=1ms
E: Ad=83(I) Atr=01(Isoc) MxPS= 0 Ivl=1ms
I: If#= 1 Alt= 1 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
E: Ad=03(O) Atr=01(Isoc) MxPS= 9 Ivl=1ms
E: Ad=83(I) Atr=01(Isoc) MxPS= 9 Ivl=1ms
I: If#= 1 Alt= 2 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
E: Ad=03(O) Atr=01(Isoc) MxPS= 17 Ivl=1ms
E: Ad=83(I) Atr=01(Isoc) MxPS= 17 Ivl=1ms
I: If#= 1 Alt= 3 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
E: Ad=03(O) Atr=01(Isoc) MxPS= 25 Ivl=1ms
E: Ad=83(I) Atr=01(Isoc) MxPS= 25 Ivl=1ms
I: If#= 1 Alt= 4 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
E: Ad=03(O) Atr=01(Isoc) MxPS= 33 Ivl=1ms
E: Ad=83(I) Atr=01(Isoc) MxPS= 33 Ivl=1ms
I: If#= 1 Alt= 5 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
E: Ad=03(O) Atr=01(Isoc) MxPS= 49 Ivl=1ms
E: Ad=83(I) Atr=01(Isoc) MxPS= 49 Ivl=1ms
Now the device is initialized properly:
> [43.329852] usb 1-1.4: new full-speed USB device number 4 using dwc_otg
> [43.446790] usb 1-1.4: New USB device found, idVendor=33fa, idProduct=0012, bcdDevice=88.91
> [43.446813] usb 1-1.4: New USB device strings: Mfr=0, Product=2, SerialNumber=0
> [43.446821] usb 1-1.4: Product: UGREEN BT6.0 Adapter
> [43.582024] Bluetooth: hci1: Unexpected continuation: 1 bytes
> [43.703025] Bluetooth: hci1: Unexpected continuation: 1 bytes
> [43.750141] Bluetooth: MGMT ver 1.23
Link: https://github.com/bluez/bluez/issues/1326
Signed-off-by: Arkadiusz Bokowy <arkadiusz.bokowy@gmail.com>
Tested-by: Arkadiusz Bokowy <arkadiusz.bokowy@gmail.com>
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
2025-08-27 18:40:16 +02:00
|
|
|
|
2026-08-24 13:32:27 +08:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2013-10-11 07:46:18 -07:00
|
|
|
|
Bluetooth: btusb: fix NXP IW610 composite device handling
The NXP IW610 module exposes itself as a composite USB device
(0471:0215) with three interfaces: two real Bluetooth HCI interfaces
(class 0xe0) and one vendor-specific WiFi interface (class 0xff) used
by mwifiex-nxp.
The composite device's whole USB descriptor reports class 0xe0/01/01
(Bluetooth), so btusb_table's generic USB_DEVICE_INFO(0xe0, 0x01, 0x01)
entry matches every interface, not just the two real HCI ones -- btusb
ends up binding the WiFi interface too, and mwifiex-nxp never gets it.
Fix:
1. In btusb_table (the table the USB core actually matches against),
explicitly ignore the WiFi interface via BTUSB_IGNORE, ahead of the
generic entry.
2. In quirks_table, scope the existing BTUSB_MARVELL entry to the BT
interface class instead of matching the whole device by VID/PID
(harmless either way since quirks_table isn't consulted for initial
binding, but keep it correct).
Not upstream anywhere: checked NXP's own i.MX kernel fork
(nxp-imx/linux-imx), no IW610 references in btusb.c on any branch --
their reference designs wire this chip differently (WiFi over SDIO
per their release notes), so they never hit this.
Signed-off-by: Nicolas Thibert <nithibert@gmail.com>
Cc: stable@vger.kernel.org
Assisted-by: LLM (Claude Sonnet 5, Anthropic)
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
2026-09-08 10:01:08 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-01-28 20:27:34 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-07-17 11:12:25 -06:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2012-08-25 19:28:06 +02:00
|
|
|
|
2015-03-22 15:52:38 +01:00
|
|
|
|
2015-10-20 00:53:33 +02:00
|
|
|
|
2012-08-25 19:28:06 +02:00
|
|
|
|
2013-06-04 21:40:26 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2011-09-21 11:41:45 +02:00
|
|
|
|
2012-03-28 16:41:11 -04:00
|
|
|
|
2011-09-21 11:41:45 +02:00
|
|
|
|
2010-08-20 16:24:07 +09:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2010-07-14 10:29:27 +04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2010-08-20 16:24:06 +09:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2010-11-04 08:04:33 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2011-09-07 02:28:10 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2011-03-24 14:51:21 -03:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2011-09-04 18:01:42 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
2015-01-01 17:34:37 -08:00
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:26 +01:00
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
2015-01-26 20:35:32 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Bluetooth: btusb: Add support for Foxconn/Lenovo BCM43142A0 (105b:e065)
Recently salvaged this 'BCM43142A0' WiFi/Bluetooth module from a Lenovo laptop
and noticed it doesn't work automatically, because the USB IDs are missing
from btusb.c.
Plugging in the adapter on Linux 4.1 (dmesg):
usb 3-3.3.3: new full-speed USB device number 90 using xhci_hcd
usb 3-3.3.3: New USB device found, idVendor=105b, idProduct=e065
usb 3-3.3.3: New USB device strings: Mfr=1, Product=2, SerialNumber=3
usb 3-3.3.3: Product: BCM43142A0
usb 3-3.3.3: Manufacturer: Broadcom Corp
usb 3-3.3.3: SerialNumber: 0090A286559E
/sys/kernel/debug/usb/devices:
T: Bus=03 Lev=03 Prnt=22 Port=02 Cnt=02 Dev#= 90 Spd=12 MxCh= 0
D: Ver= 2.00 Cls=ff(vend.) Sub=01 Prot=01 MxPS=64 #Cfgs= 1
P: Vendor=105b ProdID=e065 Rev= 1.12
S: Manufacturer=Broadcom Corp
S: Product=BCM43142A0
S: SerialNumber=0090A286559E
C:* #Ifs= 4 Cfg#= 1 Atr=e0 MxPwr= 0mA
I:* If#= 0 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=01 Prot=01 Driver=(none)
E: Ad=81(I) Atr=03(Int.) MxPS= 16 Ivl=1ms
E: Ad=82(I) Atr=02(Bulk) MxPS= 64 Ivl=0ms
E: Ad=02(O) Atr=02(Bulk) MxPS= 64 Ivl=0ms
I:* If#= 1 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=01 Driver=(none)
E: Ad=83(I) Atr=01(Isoc) MxPS= 0 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 0 Ivl=1ms
I: If#= 1 Alt= 1 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=01 Driver=(none)
E: Ad=83(I) Atr=01(Isoc) MxPS= 9 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 9 Ivl=1ms
I: If#= 1 Alt= 2 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=01 Driver=(none)
E: Ad=83(I) Atr=01(Isoc) MxPS= 17 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 17 Ivl=1ms
I: If#= 1 Alt= 3 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=01 Driver=(none)
E: Ad=83(I) Atr=01(Isoc) MxPS= 25 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 25 Ivl=1ms
I: If#= 1 Alt= 4 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=01 Driver=(none)
E: Ad=83(I) Atr=01(Isoc) MxPS= 33 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 33 Ivl=1ms
I: If#= 1 Alt= 5 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=01 Driver=(none)
E: Ad=83(I) Atr=01(Isoc) MxPS= 49 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 49 Ivl=1ms
I:* If#= 2 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=ff Prot=ff Driver=(none)
E: Ad=84(I) Atr=02(Bulk) MxPS= 32 Ivl=0ms
E: Ad=04(O) Atr=02(Bulk) MxPS= 32 Ivl=0ms
I:* If#= 3 Alt= 0 #EPs= 0 Cls=fe(app. ) Sub=01 Prot=01 Driver=(none)
Support for the chipset was added in commit 88f9b65 and a similar BCM43142
based device was added in commit 8f0c304.
To work around the issue, I got the firmware
(BCM43142A0_001.001.011.0122.0153) off a Windows installation of Broadcom
bluetooth driver and converted it to a .hcd -file via. hex2hcd and placed it
in /lib/firmware/brcm/BCM.hcd. After that:
$ echo "105b e065 0 19ff 0239" > /sys/bus/usb/drivers/btusb/new_id
...(plug in the adapter)
usb 3-3.3.3: new full-speed USB device number 91 using xhci_hcd
usb 3-3.3.3: New USB device found, idVendor=105b, idProduct=e065
usb 3-3.3.3: New USB device strings: Mfr=1, Product=2, SerialNumber=3
usb 3-3.3.3: Product: BCM43142A0
usb 3-3.3.3: Manufacturer: Broadcom Corp
usb 3-3.3.3: SerialNumber: 0090A286559E
Bluetooth: hci0: BCM: chip id 70
Bluetooth: hci0: BCM (001.001.011) build 0000
bluetooth hci0: firmware: direct-loading firmware brcm/BCM.hcd
Bluetooth: hci0: BCM (001.001.011) build 0154
Bam, now it works for me!
/sys/kernel/debug/usb/devices:
T: Bus=03 Lev=03 Prnt=22 Port=02 Cnt=02 Dev#= 92 Spd=12 MxCh= 0
D: Ver= 2.00 Cls=ff(vend.) Sub=01 Prot=01 MxPS=64 #Cfgs= 1
P: Vendor=105b ProdID=e065 Rev= 1.12
S: Manufacturer=Broadcom Corp
S: Product=BCM43142A0
S: SerialNumber=0090A286559E
C:* #Ifs= 4 Cfg#= 1 Atr=e0 MxPwr= 0mA
I:* If#= 0 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=01 Prot=01 Driver=btusb
E: Ad=81(I) Atr=03(Int.) MxPS= 16 Ivl=1ms
E: Ad=82(I) Atr=02(Bulk) MxPS= 64 Ivl=0ms
E: Ad=02(O) Atr=02(Bulk) MxPS= 64 Ivl=0ms
I:* If#= 1 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=01 Driver=btusb
E: Ad=83(I) Atr=01(Isoc) MxPS= 0 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 0 Ivl=1ms
I: If#= 1 Alt= 1 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=01 Driver=btusb
E: Ad=83(I) Atr=01(Isoc) MxPS= 9 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 9 Ivl=1ms
I: If#= 1 Alt= 2 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=01 Driver=btusb
E: Ad=83(I) Atr=01(Isoc) MxPS= 17 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 17 Ivl=1ms
I: If#= 1 Alt= 3 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=01 Driver=btusb
E: Ad=83(I) Atr=01(Isoc) MxPS= 25 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 25 Ivl=1ms
I: If#= 1 Alt= 4 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=01 Driver=btusb
E: Ad=83(I) Atr=01(Isoc) MxPS= 33 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 33 Ivl=1ms
I: If#= 1 Alt= 5 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=01 Driver=btusb
E: Ad=83(I) Atr=01(Isoc) MxPS= 49 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 49 Ivl=1ms
I:* If#= 2 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=ff Prot=ff Driver=(none)
E: Ad=84(I) Atr=02(Bulk) MxPS= 32 Ivl=0ms
E: Ad=04(O) Atr=02(Bulk) MxPS= 32 Ivl=0ms
I:* If#= 3 Alt= 0 #EPs= 0 Cls=fe(app. ) Sub=01 Prot=01 Driver=(none)
Signed-off-by: Santtu Rekilä <sare@r00t3d.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2015-10-05 15:45:27 +03:00
|
|
|
|
2017-07-06 14:41:13 +03:00
|
|
|
|
|
|
|
|
|
Bluetooth: btusb: Add support for Foxconn/Lenovo BCM43142A0 (105b:e065)
Recently salvaged this 'BCM43142A0' WiFi/Bluetooth module from a Lenovo laptop
and noticed it doesn't work automatically, because the USB IDs are missing
from btusb.c.
Plugging in the adapter on Linux 4.1 (dmesg):
usb 3-3.3.3: new full-speed USB device number 90 using xhci_hcd
usb 3-3.3.3: New USB device found, idVendor=105b, idProduct=e065
usb 3-3.3.3: New USB device strings: Mfr=1, Product=2, SerialNumber=3
usb 3-3.3.3: Product: BCM43142A0
usb 3-3.3.3: Manufacturer: Broadcom Corp
usb 3-3.3.3: SerialNumber: 0090A286559E
/sys/kernel/debug/usb/devices:
T: Bus=03 Lev=03 Prnt=22 Port=02 Cnt=02 Dev#= 90 Spd=12 MxCh= 0
D: Ver= 2.00 Cls=ff(vend.) Sub=01 Prot=01 MxPS=64 #Cfgs= 1
P: Vendor=105b ProdID=e065 Rev= 1.12
S: Manufacturer=Broadcom Corp
S: Product=BCM43142A0
S: SerialNumber=0090A286559E
C:* #Ifs= 4 Cfg#= 1 Atr=e0 MxPwr= 0mA
I:* If#= 0 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=01 Prot=01 Driver=(none)
E: Ad=81(I) Atr=03(Int.) MxPS= 16 Ivl=1ms
E: Ad=82(I) Atr=02(Bulk) MxPS= 64 Ivl=0ms
E: Ad=02(O) Atr=02(Bulk) MxPS= 64 Ivl=0ms
I:* If#= 1 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=01 Driver=(none)
E: Ad=83(I) Atr=01(Isoc) MxPS= 0 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 0 Ivl=1ms
I: If#= 1 Alt= 1 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=01 Driver=(none)
E: Ad=83(I) Atr=01(Isoc) MxPS= 9 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 9 Ivl=1ms
I: If#= 1 Alt= 2 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=01 Driver=(none)
E: Ad=83(I) Atr=01(Isoc) MxPS= 17 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 17 Ivl=1ms
I: If#= 1 Alt= 3 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=01 Driver=(none)
E: Ad=83(I) Atr=01(Isoc) MxPS= 25 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 25 Ivl=1ms
I: If#= 1 Alt= 4 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=01 Driver=(none)
E: Ad=83(I) Atr=01(Isoc) MxPS= 33 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 33 Ivl=1ms
I: If#= 1 Alt= 5 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=01 Driver=(none)
E: Ad=83(I) Atr=01(Isoc) MxPS= 49 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 49 Ivl=1ms
I:* If#= 2 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=ff Prot=ff Driver=(none)
E: Ad=84(I) Atr=02(Bulk) MxPS= 32 Ivl=0ms
E: Ad=04(O) Atr=02(Bulk) MxPS= 32 Ivl=0ms
I:* If#= 3 Alt= 0 #EPs= 0 Cls=fe(app. ) Sub=01 Prot=01 Driver=(none)
Support for the chipset was added in commit 88f9b65 and a similar BCM43142
based device was added in commit 8f0c304.
To work around the issue, I got the firmware
(BCM43142A0_001.001.011.0122.0153) off a Windows installation of Broadcom
bluetooth driver and converted it to a .hcd -file via. hex2hcd and placed it
in /lib/firmware/brcm/BCM.hcd. After that:
$ echo "105b e065 0 19ff 0239" > /sys/bus/usb/drivers/btusb/new_id
...(plug in the adapter)
usb 3-3.3.3: new full-speed USB device number 91 using xhci_hcd
usb 3-3.3.3: New USB device found, idVendor=105b, idProduct=e065
usb 3-3.3.3: New USB device strings: Mfr=1, Product=2, SerialNumber=3
usb 3-3.3.3: Product: BCM43142A0
usb 3-3.3.3: Manufacturer: Broadcom Corp
usb 3-3.3.3: SerialNumber: 0090A286559E
Bluetooth: hci0: BCM: chip id 70
Bluetooth: hci0: BCM (001.001.011) build 0000
bluetooth hci0: firmware: direct-loading firmware brcm/BCM.hcd
Bluetooth: hci0: BCM (001.001.011) build 0154
Bam, now it works for me!
/sys/kernel/debug/usb/devices:
T: Bus=03 Lev=03 Prnt=22 Port=02 Cnt=02 Dev#= 92 Spd=12 MxCh= 0
D: Ver= 2.00 Cls=ff(vend.) Sub=01 Prot=01 MxPS=64 #Cfgs= 1
P: Vendor=105b ProdID=e065 Rev= 1.12
S: Manufacturer=Broadcom Corp
S: Product=BCM43142A0
S: SerialNumber=0090A286559E
C:* #Ifs= 4 Cfg#= 1 Atr=e0 MxPwr= 0mA
I:* If#= 0 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=01 Prot=01 Driver=btusb
E: Ad=81(I) Atr=03(Int.) MxPS= 16 Ivl=1ms
E: Ad=82(I) Atr=02(Bulk) MxPS= 64 Ivl=0ms
E: Ad=02(O) Atr=02(Bulk) MxPS= 64 Ivl=0ms
I:* If#= 1 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=01 Driver=btusb
E: Ad=83(I) Atr=01(Isoc) MxPS= 0 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 0 Ivl=1ms
I: If#= 1 Alt= 1 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=01 Driver=btusb
E: Ad=83(I) Atr=01(Isoc) MxPS= 9 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 9 Ivl=1ms
I: If#= 1 Alt= 2 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=01 Driver=btusb
E: Ad=83(I) Atr=01(Isoc) MxPS= 17 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 17 Ivl=1ms
I: If#= 1 Alt= 3 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=01 Driver=btusb
E: Ad=83(I) Atr=01(Isoc) MxPS= 25 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 25 Ivl=1ms
I: If#= 1 Alt= 4 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=01 Driver=btusb
E: Ad=83(I) Atr=01(Isoc) MxPS= 33 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 33 Ivl=1ms
I: If#= 1 Alt= 5 #EPs= 2 Cls=ff(vend.) Sub=01 Prot=01 Driver=btusb
E: Ad=83(I) Atr=01(Isoc) MxPS= 49 Ivl=1ms
E: Ad=03(O) Atr=01(Isoc) MxPS= 49 Ivl=1ms
I:* If#= 2 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=ff Prot=ff Driver=(none)
E: Ad=84(I) Atr=02(Bulk) MxPS= 32 Ivl=0ms
E: Ad=04(O) Atr=02(Bulk) MxPS= 32 Ivl=0ms
I:* If#= 3 Alt= 0 #EPs= 0 Cls=fe(app. ) Sub=01 Prot=01 Driver=(none)
Signed-off-by: Santtu Rekilä <sare@r00t3d.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2015-10-05 15:45:27 +03:00
|
|
|
|
2017-02-10 14:02:45 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2012-04-13 14:45:55 -04:00
|
|
|
|
2014-12-03 19:32:22 +01:00
|
|
|
|
|
|
|
|
|
2012-04-13 14:45:55 -04:00
|
|
|
|
2015-02-02 18:50:14 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-02-18 18:26:19 +02:00
|
|
|
|
2014-05-08 15:50:01 -07:00
|
|
|
|
|
|
|
|
|
2012-08-06 15:36:49 -03:00
|
|
|
|
2014-07-21 14:02:33 +02:00
|
|
|
|
2015-01-17 05:29:12 +01:00
|
|
|
|
|
|
|
|
|
2014-07-21 14:02:33 +02:00
|
|
|
|
2013-09-21 19:14:43 +01:00
|
|
|
|
2015-03-27 15:11:41 -07:00
|
|
|
|
|
|
|
|
|
2013-09-21 19:14:43 +01:00
|
|
|
|
2014-02-15 12:01:09 +01:00
|
|
|
|
2015-03-27 15:11:41 -07:00
|
|
|
|
|
|
|
|
|
2014-02-15 12:01:09 +01:00
|
|
|
|
2017-01-10 15:41:13 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-12-05 14:09:36 +03:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-07-06 13:29:58 +02:00
|
|
|
|
2014-07-06 14:53:55 +02:00
|
|
|
|
|
|
|
|
|
2014-07-06 13:29:58 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-08-22 12:20:24 +02:00
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-10-17 14:39:27 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2010-11-26 17:35:46 +05:30
|
|
|
|
2014-02-18 18:26:19 +02:00
|
|
|
|
|
|
|
|
|
2015-02-13 21:05:11 +02:00
|
|
|
|
2014-02-18 18:26:19 +02:00
|
|
|
|
2010-11-26 17:35:46 +05:30
|
|
|
|
2012-06-08 14:32:50 +02:00
|
|
|
|
2011-05-09 16:11:16 -07:00
|
|
|
|
2010-11-26 17:35:46 +05:30
|
|
|
|
2011-01-26 17:10:59 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2011-02-11 15:38:53 +05:30
|
|
|
|
2014-02-18 18:26:19 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-06-06 20:25:40 +03:00
|
|
|
|
2014-10-06 16:31:49 +05:30
|
|
|
|
2016-02-10 00:49:11 +03:00
|
|
|
|
2014-02-18 18:26:19 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-04-17 11:37:13 -07:00
|
|
|
|
2014-02-18 18:26:19 +02:00
|
|
|
|
|
|
|
|
|
2015-06-18 20:41:51 +03:00
|
|
|
|
2015-05-02 13:36:58 +03:00
|
|
|
|
2014-12-09 07:44:51 +02:00
|
|
|
|
2016-02-28 11:04:06 +03:00
|
|
|
|
2017-01-05 13:19:53 +03:00
|
|
|
|
2014-02-18 18:26:19 +02:00
|
|
|
|
2015-10-05 19:29:33 +03:00
|
|
|
|
2014-02-18 18:26:19 +02:00
|
|
|
|
2014-08-08 12:33:56 +01:00
|
|
|
|
2014-02-18 18:26:20 +02:00
|
|
|
|
2013-03-15 11:00:39 +08:00
|
|
|
|
2018-04-26 14:18:19 +02:00
|
|
|
|
2013-03-12 04:41:58 +09:00
|
|
|
|
2012-03-14 22:01:21 +02:00
|
|
|
|
2014-01-16 15:37:11 +01:00
|
|
|
|
2014-01-16 16:02:58 +01:00
|
|
|
|
2014-02-18 18:26:19 +02:00
|
|
|
|
2013-03-18 23:45:11 +08:00
|
|
|
|
2015-10-16 11:45:26 +03:00
|
|
|
|
2014-02-18 18:26:19 +02:00
|
|
|
|
2012-04-19 14:53:45 +08:00
|
|
|
|
2013-08-30 17:41:40 +08:00
|
|
|
|
2015-05-13 11:39:24 +08:00
|
|
|
|
2014-02-18 18:26:19 +02:00
|
|
|
|
|
|
|
|
|
2012-12-11 11:41:20 +08:00
|
|
|
|
2016-02-10 15:33:17 +03:00
|
|
|
|
2013-07-15 09:29:03 +05:30
|
|
|
|
2014-11-25 20:19:52 +03:00
|
|
|
|
2015-01-18 00:16:51 +03:00
|
|
|
|
2014-07-08 19:25:08 +05:30
|
|
|
|
2016-03-04 01:32:19 +03:00
|
|
|
|
2015-06-06 20:29:25 +03:00
|
|
|
|
2016-05-09 17:36:11 -03:00
|
|
|
|
2016-07-12 01:35:18 +03:00
|
|
|
|
2011-02-11 15:38:53 +05:30
|
|
|
|
2011-02-15 10:20:07 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2012-05-02 22:33:40 +02:00
|
|
|
|
2012-08-07 19:48:10 +05:30
|
|
|
|
2014-02-18 18:26:19 +02:00
|
|
|
|
2012-05-02 22:33:40 +02:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
2020-09-17 21:09:23 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-05-18 10:25:46 -07:00
|
|
|
|
|
|
|
|
|
2020-09-17 21:09:23 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-06-29 22:34:20 +02:00
|
|
|
|
|
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
2020-09-29 12:23:51 +08:00
|
|
|
|
2022-10-30 01:22:54 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2022-10-30 01:22:54 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2022-10-30 01:22:54 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2022-10-30 01:22:54 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2025-07-15 07:27:07 -07:00
|
|
|
|
|
|
|
|
|
2022-10-30 01:22:54 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2025-07-15 07:27:07 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-10-30 01:22:54 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2022-10-30 01:22:54 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2022-10-30 01:22:54 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2025-07-15 07:27:07 -07:00
|
|
|
|
|
|
|
|
|
2022-10-30 01:22:54 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2022-10-30 01:22:54 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2025-07-15 07:27:07 -07:00
|
|
|
|
|
|
|
|
|
2022-10-30 01:22:54 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2022-10-30 01:22:54 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2022-10-30 01:22:54 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2022-10-30 01:22:54 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2022-10-30 01:22:54 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2022-10-30 01:22:54 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2025-07-15 07:27:07 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-07-15 07:27:08 -07:00
|
|
|
|
|
|
|
|
|
2020-09-29 12:23:51 +08:00
|
|
|
|
2022-04-25 23:01:29 +08:00
|
|
|
|
|
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2024-09-23 16:55:19 +08:00
|
|
|
|
|
|
|
|
|
2024-09-20 02:58:14 -07:00
|
|
|
|
|
|
|
|
|
2025-01-21 19:46:42 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-01-16 00:34:31 +01:00
|
|
|
|
|
|
|
|
|
2025-01-21 19:46:42 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-09-26 04:08:49 -07:00
|
|
|
|
|
|
|
|
|
2025-01-21 19:46:42 -08:00
|
|
|
|
|
|
|
|
|
2024-12-12 16:02:55 -08:00
|
|
|
|
|
|
|
|
|
2025-01-21 19:46:42 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-04-25 23:01:29 +08:00
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
2008-11-30 12:17:26 +01:00
|
|
|
|
2014-02-18 18:26:19 +02:00
|
|
|
|
|
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:26 +01:00
|
|
|
|
|
|
|
|
|
2008-09-23 00:16:35 +02:00
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
2008-11-30 12:17:26 +01:00
|
|
|
|
|
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:26 +01:00
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:26 +01:00
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
2008-11-30 12:17:27 +01:00
|
|
|
|
2008-11-30 12:17:26 +01:00
|
|
|
|
2008-11-30 12:17:27 +01:00
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
2008-11-30 12:17:26 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
2008-11-30 12:17:27 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2016-09-01 17:22:37 +02:00
|
|
|
|
|
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
2015-01-01 17:34:37 -08:00
|
|
|
|
2015-06-08 12:02:10 +03:00
|
|
|
|
2015-01-01 17:34:37 -08:00
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-07-07 00:12:04 +02:00
|
|
|
|
|
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
|
|
|
|
|
2014-07-07 00:12:04 +02:00
|
|
|
|
|
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
2015-01-28 19:41:42 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2016-09-28 16:18:35 +05:30
|
|
|
|
2015-01-28 19:41:42 -08:00
|
|
|
|
Bluetooth: btusb: fix NXP IW610 composite device handling
The NXP IW610 module exposes itself as a composite USB device
(0471:0215) with three interfaces: two real Bluetooth HCI interfaces
(class 0xe0) and one vendor-specific WiFi interface (class 0xff) used
by mwifiex-nxp.
The composite device's whole USB descriptor reports class 0xe0/01/01
(Bluetooth), so btusb_table's generic USB_DEVICE_INFO(0xe0, 0x01, 0x01)
entry matches every interface, not just the two real HCI ones -- btusb
ends up binding the WiFi interface too, and mwifiex-nxp never gets it.
Fix:
1. In btusb_table (the table the USB core actually matches against),
explicitly ignore the WiFi interface via BTUSB_IGNORE, ahead of the
generic entry.
2. In quirks_table, scope the existing BTUSB_MARVELL entry to the BT
interface class instead of matching the whole device by VID/PID
(harmless either way since quirks_table isn't consulted for initial
binding, but keep it correct).
Not upstream anywhere: checked NXP's own i.MX kernel fork
(nxp-imx/linux-imx), no IW610 references in btusb.c on any branch --
their reference designs wire this chip differently (WiFi over SDIO
per their release notes), so they never hit this.
Signed-off-by: Nicolas Thibert <nithibert@gmail.com>
Cc: stable@vger.kernel.org
Assisted-by: LLM (Claude Sonnet 5, Anthropic)
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
2026-09-08 10:01:08 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-01-28 19:41:43 -08:00
|
|
|
|
2021-08-04 17:32:16 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-01-31 22:02:35 +05:30
|
|
|
|
2023-07-04 13:46:51 +05:30
|
|
|
|
2024-05-02 10:53:56 +05:30
|
|
|
|
2023-09-07 14:45:50 +05:30
|
|
|
|
2024-07-05 15:59:23 +05:30
|
|
|
|
2026-05-12 14:04:44 +05:30
|
|
|
|
2015-02-22 15:41:18 -08:00
|
|
|
|
2021-08-04 17:32:12 -07:00
|
|
|
|
2022-01-20 11:44:18 -08:00
|
|
|
|
2022-01-06 16:34:54 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-01-20 11:44:18 -08:00
|
|
|
|
2022-01-06 16:34:54 -08:00
|
|
|
|
2021-08-04 17:32:16 -07:00
|
|
|
|
2022-01-06 16:34:54 -08:00
|
|
|
|
|
|
|
|
|
2021-08-04 17:32:16 -07:00
|
|
|
|
2013-04-19 09:57:43 -07:00
|
|
|
|
2015-01-28 19:41:43 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-07-18 14:47:06 -07:00
|
|
|
|
2022-12-25 14:07:13 -05:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-11-19 15:33:38 +08:00
|
|
|
|
|
|
|
|
|
2022-12-25 14:07:13 -05:00
|
|
|
|
2020-07-13 15:45:29 +08:00
|
|
|
|
|
|
|
|
|
2021-06-01 14:04:18 -05:00
|
|
|
|
|
|
|
|
|
2020-07-13 15:45:29 +08:00
|
|
|
|
|
|
|
|
|
2022-12-01 17:43:53 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-01-08 11:22:13 -07:00
|
|
|
|
2025-04-15 10:33:50 +08:00
|
|
|
|
2025-01-08 11:22:13 -07:00
|
|
|
|
2025-05-29 18:23:32 +02:00
|
|
|
|
2025-12-24 11:31:29 +08:00
|
|
|
|
|
|
|
|
|
2025-01-08 11:22:13 -07:00
|
|
|
|
2025-05-21 09:30:20 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-07-26 00:14:32 +08:00
|
|
|
|
|
|
|
|
|
2026-01-29 10:28:19 +08:00
|
|
|
|
|
|
|
|
|
2026-05-26 00:19:42 +08:00
|
|
|
|
|
|
|
|
|
2025-05-21 09:30:20 +08:00
|
|
|
|
2020-11-10 11:38:37 +08:00
|
|
|
|
2022-01-19 14:18:37 -06:00
|
|
|
|
|
|
|
|
|
2020-11-10 11:38:37 +08:00
|
|
|
|
|
|
|
|
|
2021-11-21 10:51:48 -06:00
|
|
|
|
|
|
|
|
|
2021-09-28 13:45:20 -05:00
|
|
|
|
|
|
|
|
|
2021-09-01 15:48:45 +08:00
|
|
|
|
|
|
|
|
|
2021-09-28 13:45:20 -05:00
|
|
|
|
|
|
|
|
|
2022-08-16 16:35:22 -05:00
|
|
|
|
|
|
|
|
|
2020-11-10 11:38:37 +08:00
|
|
|
|
2022-07-14 19:25:19 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-07-14 19:25:20 +08:00
|
|
|
|
|
|
|
|
|
2022-07-14 19:25:21 +08:00
|
|
|
|
|
|
|
|
|
2022-07-14 19:25:22 +08:00
|
|
|
|
|
|
|
|
|
2022-07-14 19:25:23 +08:00
|
|
|
|
|
|
|
|
|
2022-08-29 19:45:07 +08:00
|
|
|
|
|
|
|
|
|
2026-01-14 15:03:35 +11:00
|
|
|
|
|
|
|
|
|
2024-08-16 16:58:22 +08:00
|
|
|
|
|
|
|
|
|
2022-07-14 19:25:19 +08:00
|
|
|
|
2022-11-23 11:10:05 +03:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-03-29 10:34:39 +08:00
|
|
|
|
|
|
|
|
|
2023-03-22 19:52:02 -05:00
|
|
|
|
|
|
|
|
|
2023-10-12 19:21:17 +08:00
|
|
|
|
|
|
|
|
|
2023-09-24 16:46:55 +05:30
|
|
|
|
|
|
|
|
|
2023-03-22 19:52:03 -05:00
|
|
|
|
|
|
|
|
|
2023-12-19 23:05:47 +05:30
|
|
|
|
|
|
|
|
|
2024-06-22 12:09:59 +08:00
|
|
|
|
|
|
|
|
|
2024-10-01 16:37:29 +08:00
|
|
|
|
|
|
|
|
|
2024-06-17 17:05:18 +08:00
|
|
|
|
|
|
|
|
|
2022-11-23 11:10:05 +03:00
|
|
|
|
2023-12-26 19:45:17 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-11-05 13:50:39 +08:00
|
|
|
|
|
|
|
|
|
2025-11-05 13:50:40 +08:00
|
|
|
|
|
|
|
|
|
2025-11-05 13:50:41 +08:00
|
|
|
|
|
|
|
|
|
2024-08-20 14:28:29 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-04-24 20:09:28 +08:00
|
|
|
|
|
|
|
|
|
2026-04-24 20:25:22 +08:00
|
|
|
|
|
|
|
|
|
2024-08-20 14:28:29 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-08-24 13:32:27 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-04-16 14:09:55 -06:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2019-06-02 08:02:48 +08:00
|
|
|
|
|
|
|
|
|
2021-03-29 01:18:33 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2019-06-02 08:02:48 +08:00
|
|
|
|
2020-11-10 11:40:10 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-02-11 10:31:03 +01:00
|
|
|
|
|
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2023-02-28 13:55:17 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2022-02-11 10:31:03 +01:00
|
|
|
|
2021-07-12 02:32:20 -05:00
|
|
|
|
|
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2021-07-12 02:32:20 -05:00
|
|
|
|
2024-09-30 18:47:50 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-10-15 11:31:49 +08:00
|
|
|
|
|
|
|
|
|
2024-09-30 18:47:50 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-12-10 23:22:25 +03:00
|
|
|
|
|
|
|
|
|
2024-09-30 18:47:50 +08:00
|
|
|
|
2021-04-12 23:06:27 +08:00
|
|
|
|
2022-04-28 02:38:39 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2024-04-23 14:51:57 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2022-07-24 13:25:02 -05:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2022-12-14 20:18:54 -06:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2021-04-12 23:06:27 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2024-04-23 14:51:57 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2021-07-08 04:00:59 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2021-09-01 19:30:15 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2022-02-23 07:55:59 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2025-01-08 13:01:40 -07:00
|
|
|
|
|
|
|
|
|
2022-08-30 06:55:58 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2022-08-31 12:53:28 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2024-04-23 14:51:56 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2026-02-24 00:13:20 -06:00
|
|
|
|
2026-06-14 17:12:58 +03:00
|
|
|
|
|
|
|
|
|
2026-02-24 00:13:24 -06:00
|
|
|
|
|
|
|
|
|
2026-02-24 00:13:20 -06:00
|
|
|
|
|
|
|
|
|
2026-02-24 00:13:21 -06:00
|
|
|
|
|
|
|
|
|
2026-02-24 00:13:22 -06:00
|
|
|
|
|
|
|
|
|
2026-02-24 00:13:23 -06:00
|
|
|
|
|
|
|
|
|
2024-03-15 18:48:08 +11:00
|
|
|
|
|
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2024-12-24 14:42:11 -06:00
|
|
|
|
|
|
|
|
|
2024-03-15 18:48:08 +11:00
|
|
|
|
2021-12-17 17:51:50 +08:00
|
|
|
|
|
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2021-12-17 17:51:50 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2022-06-25 17:03:57 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2023-03-06 09:44:59 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2023-07-12 22:36:02 +01:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2022-11-28 15:49:57 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2023-07-02 23:01:38 +02:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2023-06-30 21:32:30 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2023-07-07 14:29:58 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2026-04-01 02:53:01 +09:00
|
|
|
|
|
|
|
|
|
2025-02-20 10:01:28 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-10-15 11:31:50 +08:00
|
|
|
|
|
|
|
|
|
2026-01-30 14:13:56 +08:00
|
|
|
|
|
|
|
|
|
2023-07-07 14:29:59 +08:00
|
|
|
|
2026-02-19 20:32:09 +01:00
|
|
|
|
|
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2024-04-23 14:51:57 +08:00
|
|
|
|
2026-04-07 14:50:53 +08:00
|
|
|
|
|
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2024-04-23 14:51:57 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2025-05-13 14:13:54 +08:00
|
|
|
|
|
|
|
|
|
2024-04-23 14:51:57 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2024-04-23 14:51:57 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2024-04-23 14:51:56 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2024-04-23 14:51:56 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2025-09-04 19:46:11 +08:00
|
|
|
|
|
|
|
|
|
2024-04-23 14:51:57 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2024-01-13 15:27:38 +08:00
|
|
|
|
|
|
|
|
|
2024-10-26 11:18:18 +08:00
|
|
|
|
|
|
|
|
|
2024-04-23 14:51:56 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2024-09-01 04:28:47 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-11-02 01:10:14 +00:00
|
|
|
|
|
|
|
|
|
2024-09-30 18:47:50 +08:00
|
|
|
|
|
|
|
|
|
2026-03-30 14:39:25 -06:00
|
|
|
|
|
|
|
|
|
2026-03-30 14:39:26 -06:00
|
|
|
|
|
|
|
|
|
2026-03-30 14:39:27 -06:00
|
|
|
|
|
|
|
|
|
2026-03-30 14:39:28 -06:00
|
|
|
|
|
|
|
|
|
2026-03-30 14:39:29 -06:00
|
|
|
|
|
|
|
|
|
2026-03-30 14:39:30 -06:00
|
|
|
|
|
|
|
|
|
2025-07-09 14:36:06 +08:00
|
|
|
|
|
|
|
|
|
2024-11-04 22:59:31 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-04-07 14:51:10 +08:00
|
|
|
|
|
|
|
|
|
2024-01-13 15:27:38 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2024-04-23 14:51:56 +08:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2024-07-30 15:08:25 -07:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2024-08-21 15:08:56 +04:00
|
|
|
|
|
|
|
|
|
2026-05-12 14:03:18 +08:00
|
|
|
|
|
|
|
|
|
2025-04-01 12:24:35 +00:00
|
|
|
|
|
|
|
|
|
2026-06-25 11:32:30 +03:00
|
|
|
|
|
|
|
|
|
2025-09-04 15:58:00 +08:00
|
|
|
|
|
|
|
|
|
2024-12-24 14:35:22 +08:00
|
|
|
|
|
|
|
|
|
2025-04-29 18:16:05 +08:00
|
|
|
|
|
|
|
|
|
2025-06-06 23:33:03 +08:00
|
|
|
|
|
|
|
|
|
2021-12-17 17:51:50 +08:00
|
|
|
|
2015-04-16 14:09:55 -06:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-03-08 15:57:31 +01:00
|
|
|
|
2015-04-16 14:09:55 -06:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-08-08 14:09:02 +03:00
|
|
|
|
2015-04-16 14:09:55 -06:00
|
|
|
|
2018-03-20 19:41:10 +01:00
|
|
|
|
|
|
|
|
|
2026-01-20 10:13:04 +01:00
|
|
|
|
2018-03-20 19:41:10 +01:00
|
|
|
|
2018-05-21 18:09:20 +08:00
|
|
|
|
2018-05-25 17:54:52 +08:00
|
|
|
|
2018-05-21 18:09:20 +08:00
|
|
|
|
|
|
|
|
|
2022-08-26 00:42:07 +02:00
|
|
|
|
2026-04-22 23:26:47 +02:00
|
|
|
|
|
|
|
|
|
2021-09-30 09:22:39 +01:00
|
|
|
|
|
|
|
|
|
2026-06-03 11:58:18 +08:00
|
|
|
|
|
|
|
|
|
2021-05-28 17:26:45 +02:00
|
|
|
|
2026-03-13 17:39:12 +01:00
|
|
|
|
2022-02-26 16:22:56 +01:00
|
|
|
|
|
|
|
|
|
2022-04-27 14:59:48 +02:00
|
|
|
|
|
|
|
|
|
2023-05-09 12:45:24 -07:00
|
|
|
|
|
|
|
|
|
2022-08-26 00:42:08 +02:00
|
|
|
|
|
|
|
|
|
2022-11-08 20:54:13 +08:00
|
|
|
|
|
|
|
|
|
2025-10-06 16:46:47 +08:00
|
|
|
|
|
|
|
|
|
2026-05-30 14:39:34 +02:00
|
|
|
|
2026-07-05 11:28:56 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-07-05 11:28:57 +02:00
|
|
|
|
|
|
|
|
|
2026-05-30 14:39:34 +02:00
|
|
|
|
2022-04-27 14:59:48 +02:00
|
|
|
|
2015-04-16 14:09:55 -06:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2018-02-11 12:24:32 -06:00
|
|
|
|
2018-05-30 11:23:00 +03:00
|
|
|
|
2018-02-11 12:24:32 -06:00
|
|
|
|
|
|
|
|
|
2019-09-03 17:10:42 +08:00
|
|
|
|
2020-11-05 18:54:48 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2020-11-09 17:47:22 +01:00
|
|
|
|
|
|
|
|
|
2020-11-19 16:16:25 +11:00
|
|
|
|
|
|
|
|
|
2026-07-08 01:15:49 +03:00
|
|
|
|
|
|
|
|
|
2021-02-18 13:11:24 +02:00
|
|
|
|
|
|
|
|
|
2019-09-03 17:10:42 +08:00
|
|
|
|
Bluetooth: btusb: Check for unexpected bytes when defragmenting HCI frames
Some Barrot based USB Bluetooth dongles erroneously send one extra
random byte for the HCI_OP_READ_LOCAL_EXT_FEATURES command. The
consequence of that is that the next HCI transfer is misaligned by one
byte causing undefined behavior. In most cases the response event for
the next command fails with random error code.
Since the HCI_OP_READ_LOCAL_EXT_FEATURES command is used during HCI
controller initialization, the initialization fails rendering the USB
dongle not usable.
> [59.464099] usb 1-1.3: new full-speed USB device number 11 using xhci_hcd
> [59.561617] usb 1-1.3: New USB device found, idVendor=33fa, idProduct=0012, bcdDevice=88.91
> [59.561642] usb 1-1.3: New USB device strings: Mfr=0, Product=2, SerialNumber=0
> [59.561656] usb 1-1.3: Product: UGREEN BT6.0 Adapter
> [61.720116] Bluetooth: hci1: command 0x1005 tx timeout
> [61.720167] Bluetooth: hci1: Opcode 0x1005 failed: -110
This patch was tested with the 33fa:0012 device. The info from the
/sys/kernel/debug/usb/devices is shown below:
T: Bus=01 Lev=02 Prnt=02 Port=02 Cnt=01 Dev#= 12 Spd=12 MxCh= 0
D: Ver= 2.00 Cls=e0(wlcon) Sub=01 Prot=01 MxPS=64 #Cfgs= 1
P: Vendor=33fa ProdID=0012 Rev=88.91
S: Product=UGREEN BT6.0 Adapter
C:* #Ifs= 2 Cfg#= 1 Atr=c0 MxPwr=100mA
I:* If#= 0 Alt= 0 #EPs= 3 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
E: Ad=81(I) Atr=03(Int.) MxPS= 16 Ivl=1ms
E: Ad=02(O) Atr=02(Bulk) MxPS= 64 Ivl=0ms
E: Ad=82(I) Atr=02(Bulk) MxPS= 64 Ivl=0ms
I:* If#= 1 Alt= 0 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
E: Ad=03(O) Atr=01(Isoc) MxPS= 0 Ivl=1ms
E: Ad=83(I) Atr=01(Isoc) MxPS= 0 Ivl=1ms
I: If#= 1 Alt= 1 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
E: Ad=03(O) Atr=01(Isoc) MxPS= 9 Ivl=1ms
E: Ad=83(I) Atr=01(Isoc) MxPS= 9 Ivl=1ms
I: If#= 1 Alt= 2 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
E: Ad=03(O) Atr=01(Isoc) MxPS= 17 Ivl=1ms
E: Ad=83(I) Atr=01(Isoc) MxPS= 17 Ivl=1ms
I: If#= 1 Alt= 3 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
E: Ad=03(O) Atr=01(Isoc) MxPS= 25 Ivl=1ms
E: Ad=83(I) Atr=01(Isoc) MxPS= 25 Ivl=1ms
I: If#= 1 Alt= 4 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
E: Ad=03(O) Atr=01(Isoc) MxPS= 33 Ivl=1ms
E: Ad=83(I) Atr=01(Isoc) MxPS= 33 Ivl=1ms
I: If#= 1 Alt= 5 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
E: Ad=03(O) Atr=01(Isoc) MxPS= 49 Ivl=1ms
E: Ad=83(I) Atr=01(Isoc) MxPS= 49 Ivl=1ms
Now the device is initialized properly:
> [43.329852] usb 1-1.4: new full-speed USB device number 4 using dwc_otg
> [43.446790] usb 1-1.4: New USB device found, idVendor=33fa, idProduct=0012, bcdDevice=88.91
> [43.446813] usb 1-1.4: New USB device strings: Mfr=0, Product=2, SerialNumber=0
> [43.446821] usb 1-1.4: Product: UGREEN BT6.0 Adapter
> [43.582024] Bluetooth: hci1: Unexpected continuation: 1 bytes
> [43.703025] Bluetooth: hci1: Unexpected continuation: 1 bytes
> [43.750141] Bluetooth: MGMT ver 1.23
Link: https://github.com/bluez/bluez/issues/1326
Signed-off-by: Arkadiusz Bokowy <arkadiusz.bokowy@gmail.com>
Tested-by: Arkadiusz Bokowy <arkadiusz.bokowy@gmail.com>
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
2025-08-27 18:40:16 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-12-16 21:12:47 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-08-15 20:47:09 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2018-02-20 09:06:18 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2018-03-01 13:42:52 +08:00
|
|
|
|
2018-02-20 09:06:18 +01:00
|
|
|
|
2018-03-01 13:42:52 +08:00
|
|
|
|
|
|
|
|
|
2018-02-20 09:06:18 +01:00
|
|
|
|
|
|
|
|
|
2018-04-26 20:52:06 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2018-05-22 09:34:10 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2018-02-20 09:06:18 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-06-25 22:19:50 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
2010-07-16 17:20:33 -03:00
|
|
|
|
2015-01-26 21:33:48 -08:00
|
|
|
|
|
|
|
|
|
2015-01-28 01:58:40 -08:00
|
|
|
|
2015-01-26 21:33:48 -08:00
|
|
|
|
2015-01-28 01:58:40 -08:00
|
|
|
|
2018-01-08 10:44:16 +01:00
|
|
|
|
|
|
|
|
|
2019-01-24 15:28:14 -08:00
|
|
|
|
2019-06-02 08:02:48 +08:00
|
|
|
|
2021-08-17 11:03:12 +08:00
|
|
|
|
2021-07-26 21:02:06 +03:00
|
|
|
|
2022-10-05 16:43:31 +08:00
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
Bluetooth: Properly disable remote wakeup for MT7922/MT7925 on Ryzen platform
It is reported that a remote wakeup could cause MT7922/MT7925's btusb
interface completely unresponsive. Resetting the xHCI root hub doesn't
help at all, and recovering from such a state needs a power cycle.
All reports seen to be relevant to Ryzen-based laptops. These NICs are
usually used as OEM components thanks to some sort of reference designs.
Their popularity on other platforms is unclear. While there is still a
chance that the quirk may exist on other platforms, be cautious and only
apply the quirk to direct children of Ryzen platforms's root hubs for
the time being. In most cases the root hub is on the SoC or PCH, which
needs the quirk. Unfortunately, this can't distinguish root hubs on PCIe
add-in cards. Such roughness should be acceptable, as PCIe USB
controller add-in cards are less commonly used nowadays. On the other
hand, applying the quirk doesn't hurt any functionalities either, as the
device can still be used as a wakeup source if desired. Theoretically,
we could retrieve the root hub's PCI vendor ID with some hierarchy
magic, but that's too intrusive...
Meanwhile, though device_set_wakeup_capable(false) is the correct fix
for other NICs with fake remote wakeup capabilities, doing so for
MT7922/MT7925 effectively prevents it from being used as wakeup
sources as per userspace requests. Hence, return -EBUSY on runtime
suspend to prevent the interface from being autosuspended while it's
still opened, which has the same effect as
device_set_wakeup_capable(false), since disabling remote wakeup simply
causes the USB core to gate runtime autosuspend as well due to
needs_remote_wakeup == 1. The interface can be safely autosuspended as
long as remote wakeup is disabled, i.e., after closing the HCI device.
Specifically, the interface may still take the advantage of remote
wakeup in order to wake up the system from sleep if userspace has
enabled it as a wakeup source.
Fixes: e31d761628ad ("Bluetooth: btmtk: Disable remote wakeup for MT7922/MT7925")
Tested-by: Rafael Passos <rafael@rcpassos.me>
Signed-off-by: Rong Zhang <i@rong.moe>
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
2026-09-02 02:19:18 +08:00
|
|
|
|
2026-09-04 16:03:50 +08:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-09-23 00:16:36 +02:00
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
2015-10-08 20:23:08 +02:00
|
|
|
|
2017-10-24 19:42:45 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-12-03 14:38:13 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
2015-10-08 20:23:08 +02:00
|
|
|
|
2019-06-02 08:02:48 +08:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
2015-10-08 20:23:08 +02:00
|
|
|
|
|
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
2019-01-24 15:28:14 -08:00
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:26 +01:00
|
|
|
|
2015-01-28 20:27:34 -08:00
|
|
|
|
2008-11-30 12:17:26 +01:00
|
|
|
|
2009-02-04 17:41:38 +01:00
|
|
|
|
2020-04-03 21:43:59 +02:00
|
|
|
|
|
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
2008-11-30 12:17:14 +01:00
|
|
|
|
2026-06-25 22:19:48 -07:00
|
|
|
|
2014-11-03 05:16:07 +01:00
|
|
|
|
2015-01-12 13:51:10 -08:00
|
|
|
|
2021-08-04 17:03:15 +08:00
|
|
|
|
2014-11-03 05:16:07 +01:00
|
|
|
|
2015-02-15 23:06:14 +00:00
|
|
|
|
|
|
|
|
|
2017-02-01 14:24:09 -08:00
|
|
|
|
2024-07-04 14:01:12 +08:00
|
|
|
|
|
|
|
|
|
2024-09-23 16:47:03 +08:00
|
|
|
|
2024-07-04 14:01:12 +08:00
|
|
|
|
2017-02-01 14:24:09 -08:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
2022-10-06 17:09:31 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-09-04 16:03:51 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-10-06 17:09:31 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-01-08 20:24:43 +08:00
|
|
|
|
2019-01-24 15:28:14 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-06-11 12:13:42 +05:30
|
|
|
|
2019-01-24 15:28:14 -08:00
|
|
|
|
2023-06-11 12:13:42 +05:30
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2019-01-24 15:28:14 -08:00
|
|
|
|
2022-10-06 17:09:31 +08:00
|
|
|
|
2019-01-24 15:28:14 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2019-01-28 15:08:09 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2019-01-24 15:28:14 -08:00
|
|
|
|
|
|
|
|
|
2023-04-27 11:27:55 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-01-08 20:24:43 +08:00
|
|
|
|
2019-09-05 10:36:31 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-04-27 11:27:55 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2019-09-05 10:36:31 +08:00
|
|
|
|
|
|
|
|
|
2022-10-06 17:09:31 +08:00
|
|
|
|
2019-09-05 10:36:31 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2019-11-27 11:01:07 +08:00
|
|
|
|
|
|
|
|
|
2019-09-05 10:36:31 +08:00
|
|
|
|
|
|
|
|
|
2023-04-27 11:27:55 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-01-08 20:24:43 +08:00
|
|
|
|
2020-06-24 11:11:44 -07:00
|
|
|
|
|
|
|
|
|
2021-09-16 16:41:06 +08:00
|
|
|
|
2020-06-24 11:11:44 -07:00
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
2025-01-08 20:24:43 +08:00
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-09-16 16:41:06 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-10-06 17:09:31 +08:00
|
|
|
|
2020-06-24 11:11:44 -07:00
|
|
|
|
|
|
|
|
|
2025-10-07 11:33:15 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-12-06 20:59:10 +08:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
2022-12-06 20:59:10 +08:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
2022-12-06 20:59:10 +08:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-07-25 01:54:42 -07:00
|
|
|
|
2021-12-03 14:38:13 -08:00
|
|
|
|
2026-07-25 01:54:42 -07:00
|
|
|
|
|
|
|
|
|
2021-12-03 14:38:13 -08:00
|
|
|
|
bluetooth: Fix typos in the comments
Correctly spelled comments make it easier for the reader to understand
the code.
Fix typos:
'fragement' ==> 'fragment',
'genration' ==> 'generation',
'funciton' ==> 'function',
'Explitly' ==> 'Explicitly',
'explaination' ==> 'explanation',
'Tranlate' ==> 'Translate',
'immediatelly' ==> 'immediately',
'isntance' ==> 'instance',
'transmittion' ==> 'transmission',
'recevie' ==> 'receive',
'outselves' ==> 'ourselves',
'conrol' ==> 'control'.
Signed-off-by: Yan Zhen <yanzhen@vivo.com>
Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
2024-09-29 16:57:27 +08:00
|
|
|
|
2021-12-03 14:38:13 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-07-25 01:54:42 -07:00
|
|
|
|
2021-12-03 14:38:13 -08:00
|
|
|
|
|
|
|
|
|
2014-09-16 05:33:33 +02:00
|
|
|
|
|
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
2018-06-19 23:56:57 +02:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
2018-06-19 23:56:57 +02:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-11-05 07:33:56 +01:00
|
|
|
|
|
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
2015-11-05 07:33:56 +01:00
|
|
|
|
networking: introduce and use skb_put_data()
A common pattern with skb_put() is to just want to memcpy()
some data into the new space, introduce skb_put_data() for
this.
An spatch similar to the one for skb_put_zero() converts many
of the places using it:
@@
identifier p, p2;
expression len, skb, data;
type t, t2;
@@
(
-p = skb_put(skb, len);
+p = skb_put_data(skb, data, len);
|
-p = (t)skb_put(skb, len);
+p = skb_put_data(skb, data, len);
)
(
p2 = (t2)p;
-memcpy(p2, data, len);
|
-memcpy(p, data, len);
)
@@
type t, t2;
identifier p, p2;
expression skb, data;
@@
t *p;
...
(
-p = skb_put(skb, sizeof(t));
+p = skb_put_data(skb, data, sizeof(t));
|
-p = (t *)skb_put(skb, sizeof(t));
+p = skb_put_data(skb, data, sizeof(t));
)
(
p2 = (t2)p;
-memcpy(p2, data, sizeof(*p));
|
-memcpy(p, data, sizeof(*p));
)
@@
expression skb, len, data;
@@
-memcpy(skb_put(skb, len), data, len);
+skb_put_data(skb, data, len);
(again, manually post-processed to retain some comments)
Reviewed-by: Stephen Hemminger <stephen@networkplumber.org>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2017-06-16 14:29:20 +02:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-11-05 07:33:56 +01:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-11-05 07:33:56 +01:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
2015-11-05 07:33:56 +01:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-11-05 07:33:56 +01:00
|
|
|
|
Bluetooth: btusb: Check for unexpected bytes when defragmenting HCI frames
Some Barrot based USB Bluetooth dongles erroneously send one extra
random byte for the HCI_OP_READ_LOCAL_EXT_FEATURES command. The
consequence of that is that the next HCI transfer is misaligned by one
byte causing undefined behavior. In most cases the response event for
the next command fails with random error code.
Since the HCI_OP_READ_LOCAL_EXT_FEATURES command is used during HCI
controller initialization, the initialization fails rendering the USB
dongle not usable.
> [59.464099] usb 1-1.3: new full-speed USB device number 11 using xhci_hcd
> [59.561617] usb 1-1.3: New USB device found, idVendor=33fa, idProduct=0012, bcdDevice=88.91
> [59.561642] usb 1-1.3: New USB device strings: Mfr=0, Product=2, SerialNumber=0
> [59.561656] usb 1-1.3: Product: UGREEN BT6.0 Adapter
> [61.720116] Bluetooth: hci1: command 0x1005 tx timeout
> [61.720167] Bluetooth: hci1: Opcode 0x1005 failed: -110
This patch was tested with the 33fa:0012 device. The info from the
/sys/kernel/debug/usb/devices is shown below:
T: Bus=01 Lev=02 Prnt=02 Port=02 Cnt=01 Dev#= 12 Spd=12 MxCh= 0
D: Ver= 2.00 Cls=e0(wlcon) Sub=01 Prot=01 MxPS=64 #Cfgs= 1
P: Vendor=33fa ProdID=0012 Rev=88.91
S: Product=UGREEN BT6.0 Adapter
C:* #Ifs= 2 Cfg#= 1 Atr=c0 MxPwr=100mA
I:* If#= 0 Alt= 0 #EPs= 3 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
E: Ad=81(I) Atr=03(Int.) MxPS= 16 Ivl=1ms
E: Ad=02(O) Atr=02(Bulk) MxPS= 64 Ivl=0ms
E: Ad=82(I) Atr=02(Bulk) MxPS= 64 Ivl=0ms
I:* If#= 1 Alt= 0 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
E: Ad=03(O) Atr=01(Isoc) MxPS= 0 Ivl=1ms
E: Ad=83(I) Atr=01(Isoc) MxPS= 0 Ivl=1ms
I: If#= 1 Alt= 1 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
E: Ad=03(O) Atr=01(Isoc) MxPS= 9 Ivl=1ms
E: Ad=83(I) Atr=01(Isoc) MxPS= 9 Ivl=1ms
I: If#= 1 Alt= 2 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
E: Ad=03(O) Atr=01(Isoc) MxPS= 17 Ivl=1ms
E: Ad=83(I) Atr=01(Isoc) MxPS= 17 Ivl=1ms
I: If#= 1 Alt= 3 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
E: Ad=03(O) Atr=01(Isoc) MxPS= 25 Ivl=1ms
E: Ad=83(I) Atr=01(Isoc) MxPS= 25 Ivl=1ms
I: If#= 1 Alt= 4 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
E: Ad=03(O) Atr=01(Isoc) MxPS= 33 Ivl=1ms
E: Ad=83(I) Atr=01(Isoc) MxPS= 33 Ivl=1ms
I: If#= 1 Alt= 5 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
E: Ad=03(O) Atr=01(Isoc) MxPS= 49 Ivl=1ms
E: Ad=83(I) Atr=01(Isoc) MxPS= 49 Ivl=1ms
Now the device is initialized properly:
> [43.329852] usb 1-1.4: new full-speed USB device number 4 using dwc_otg
> [43.446790] usb 1-1.4: New USB device found, idVendor=33fa, idProduct=0012, bcdDevice=88.91
> [43.446813] usb 1-1.4: New USB device strings: Mfr=0, Product=2, SerialNumber=0
> [43.446821] usb 1-1.4: Product: UGREEN BT6.0 Adapter
> [43.582024] Bluetooth: hci1: Unexpected continuation: 1 bytes
> [43.703025] Bluetooth: hci1: Unexpected continuation: 1 bytes
> [43.750141] Bluetooth: MGMT ver 1.23
Link: https://github.com/bluez/bluez/issues/1326
Signed-off-by: Arkadiusz Bokowy <arkadiusz.bokowy@gmail.com>
Tested-by: Arkadiusz Bokowy <arkadiusz.bokowy@gmail.com>
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
2025-08-27 18:40:16 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
2026-07-25 01:54:42 -07:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2018-06-19 23:56:57 +02:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
2014-09-16 05:33:33 +02:00
|
|
|
|
|
|
|
|
|
2026-07-25 01:54:42 -07:00
|
|
|
|
2021-12-03 14:38:13 -08:00
|
|
|
|
2026-07-25 01:54:42 -07:00
|
|
|
|
|
|
|
|
|
2021-12-03 14:38:13 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-07-25 01:54:42 -07:00
|
|
|
|
2021-12-03 14:38:13 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-09-16 05:33:33 +02:00
|
|
|
|
|
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
2018-06-19 23:56:57 +02:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
2018-06-19 23:56:57 +02:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-11-05 07:33:56 +01:00
|
|
|
|
|
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
2015-11-05 07:33:56 +01:00
|
|
|
|
networking: introduce and use skb_put_data()
A common pattern with skb_put() is to just want to memcpy()
some data into the new space, introduce skb_put_data() for
this.
An spatch similar to the one for skb_put_zero() converts many
of the places using it:
@@
identifier p, p2;
expression len, skb, data;
type t, t2;
@@
(
-p = skb_put(skb, len);
+p = skb_put_data(skb, data, len);
|
-p = (t)skb_put(skb, len);
+p = skb_put_data(skb, data, len);
)
(
p2 = (t2)p;
-memcpy(p2, data, len);
|
-memcpy(p, data, len);
)
@@
type t, t2;
identifier p, p2;
expression skb, data;
@@
t *p;
...
(
-p = skb_put(skb, sizeof(t));
+p = skb_put_data(skb, data, sizeof(t));
|
-p = (t *)skb_put(skb, sizeof(t));
+p = skb_put_data(skb, data, sizeof(t));
)
(
p2 = (t2)p;
-memcpy(p2, data, sizeof(*p));
|
-memcpy(p, data, sizeof(*p));
)
@@
expression skb, len, data;
@@
-memcpy(skb_put(skb, len), data, len);
+skb_put_data(skb, data, len);
(again, manually post-processed to retain some comments)
Reviewed-by: Stephen Hemminger <stephen@networkplumber.org>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2017-06-16 14:29:20 +02:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-11-05 07:33:56 +01:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-07-25 01:54:46 -07:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
2015-11-05 07:33:56 +01:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-11-05 07:33:56 +01:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
2026-07-25 01:54:42 -07:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2018-06-19 23:56:57 +02:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
2014-09-16 05:33:33 +02:00
|
|
|
|
|
|
|
|
|
2022-10-05 17:06:21 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-09-16 05:33:33 +02:00
|
|
|
|
|
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
2018-06-19 23:56:57 +02:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
2018-06-19 23:56:57 +02:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-11-05 07:33:56 +01:00
|
|
|
|
|
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
2015-11-05 07:33:56 +01:00
|
|
|
|
networking: introduce and use skb_put_data()
A common pattern with skb_put() is to just want to memcpy()
some data into the new space, introduce skb_put_data() for
this.
An spatch similar to the one for skb_put_zero() converts many
of the places using it:
@@
identifier p, p2;
expression len, skb, data;
type t, t2;
@@
(
-p = skb_put(skb, len);
+p = skb_put_data(skb, data, len);
|
-p = (t)skb_put(skb, len);
+p = skb_put_data(skb, data, len);
)
(
p2 = (t2)p;
-memcpy(p2, data, len);
|
-memcpy(p, data, len);
)
@@
type t, t2;
identifier p, p2;
expression skb, data;
@@
t *p;
...
(
-p = skb_put(skb, sizeof(t));
+p = skb_put_data(skb, data, sizeof(t));
|
-p = (t *)skb_put(skb, sizeof(t));
+p = skb_put_data(skb, data, sizeof(t));
)
(
p2 = (t2)p;
-memcpy(p2, data, sizeof(*p));
|
-memcpy(p, data, sizeof(*p));
)
@@
expression skb, len, data;
@@
-memcpy(skb_put(skb, len), data, len);
+skb_put_data(skb, data, len);
(again, manually post-processed to retain some comments)
Reviewed-by: Stephen Hemminger <stephen@networkplumber.org>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2017-06-16 14:29:20 +02:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-11-05 07:33:56 +01:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-10-05 17:06:21 +02:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
2022-10-05 17:06:21 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-11-05 07:33:56 +01:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2018-06-19 23:56:57 +02:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
2014-09-16 05:33:33 +02:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2012-02-09 21:58:32 +01:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
2014-09-16 04:44:50 +02:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
2014-09-16 05:33:33 +02:00
|
|
|
|
|
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
2014-09-06 14:06:08 -05:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2011-08-09 17:16:28 +02:00
|
|
|
|
2017-07-22 13:47:07 +12:00
|
|
|
|
|
|
|
|
|
2011-08-09 17:16:28 +02:00
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
|
|
|
|
|
2021-12-03 15:59:02 +01:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:10 +01:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2012-02-09 21:58:32 +01:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:10 +01:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-10-16 11:47:00 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2008-11-30 12:17:10 +01:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-09-16 04:44:50 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:10 +01:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2011-10-09 12:12:22 +02:00
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
|
|
|
|
|
2021-12-03 15:59:02 +01:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-12-03 14:38:13 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2012-02-09 21:58:32 +01:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
2014-09-16 04:44:50 +02:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
2014-11-03 05:16:07 +01:00
|
|
|
|
2014-09-16 05:33:33 +02:00
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
2014-09-06 14:06:08 -05:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2009-12-16 19:23:43 +01:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2011-08-09 17:16:28 +02:00
|
|
|
|
2017-07-22 13:47:07 +12:00
|
|
|
|
|
|
|
|
|
2011-08-09 17:16:28 +02:00
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:10 +01:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2012-02-09 21:58:32 +01:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2009-07-02 14:31:59 +05:30
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:10 +01:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:10 +01:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-09-16 04:44:50 +02:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:10 +01:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2011-10-09 12:12:22 +02:00
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2012-02-09 21:58:32 +01:00
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
2014-09-16 04:44:50 +02:00
|
|
|
|
|
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-09-16 05:33:33 +02:00
|
|
|
|
|
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-09-06 14:06:08 -05:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2011-08-09 17:16:28 +02:00
|
|
|
|
2017-07-22 13:47:07 +12:00
|
|
|
|
|
|
|
|
|
2011-08-09 17:16:28 +02:00
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
|
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2020-04-03 21:43:59 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-10-05 16:43:31 +08:00
|
|
|
|
2020-04-03 21:43:59 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-10-05 16:43:31 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2020-04-03 21:43:59 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-10-05 16:43:31 +08:00
|
|
|
|
2020-04-03 21:43:59 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2011-01-17 00:09:38 +01:00
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:10 +01:00
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
2012-02-09 21:58:32 +01:00
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:10 +01:00
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:10 +01:00
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2011-12-20 18:19:00 -08:00
|
|
|
|
2014-09-16 04:44:50 +02:00
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
2014-09-16 04:44:50 +02:00
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
2014-09-16 04:44:50 +02:00
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:10 +01:00
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
2011-10-09 12:12:22 +02:00
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
|
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-10-08 20:23:08 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
networking: introduce and use skb_put_data()
A common pattern with skb_put() is to just want to memcpy()
some data into the new space, introduce skb_put_data() for
this.
An spatch similar to the one for skb_put_zero() converts many
of the places using it:
@@
identifier p, p2;
expression len, skb, data;
type t, t2;
@@
(
-p = skb_put(skb, len);
+p = skb_put_data(skb, data, len);
|
-p = (t)skb_put(skb, len);
+p = skb_put_data(skb, data, len);
)
(
p2 = (t2)p;
-memcpy(p2, data, len);
|
-memcpy(p, data, len);
)
@@
type t, t2;
identifier p, p2;
expression skb, data;
@@
t *p;
...
(
-p = skb_put(skb, sizeof(t));
+p = skb_put_data(skb, data, sizeof(t));
|
-p = (t *)skb_put(skb, sizeof(t));
+p = skb_put_data(skb, data, sizeof(t));
)
(
p2 = (t2)p;
-memcpy(p2, data, sizeof(*p));
|
-memcpy(p, data, sizeof(*p));
)
@@
expression skb, len, data;
@@
-memcpy(skb_put(skb, len), data, len);
+skb_put_data(skb, data, len);
(again, manually post-processed to retain some comments)
Reviewed-by: Stephen Hemminger <stephen@networkplumber.org>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2017-06-16 14:29:20 +02:00
|
|
|
|
|
|
|
|
|
2015-10-08 20:23:08 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-07-22 13:47:07 +12:00
|
|
|
|
|
|
|
|
|
2015-10-08 20:23:08 +02:00
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
|
|
|
|
|
2015-10-08 20:23:08 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
|
|
|
|
|
2015-10-08 20:23:08 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
|
|
|
|
|
2014-09-16 04:44:50 +02:00
|
|
|
|
2012-02-09 21:58:32 +01:00
|
|
|
|
2018-06-19 23:56:57 +02:00
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
2014-09-16 04:44:50 +02:00
|
|
|
|
|
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-12-03 15:59:02 +01:00
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
2021-12-03 15:59:02 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
2021-12-03 15:59:02 +01:00
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
|
|
|
|
|
2018-06-19 23:56:57 +02:00
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
2018-06-19 23:56:57 +02:00
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
2014-09-16 04:44:50 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2014-09-16 04:44:50 +02:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2012-02-09 21:58:32 +01:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2016-10-07 12:06:42 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-02-15 23:06:14 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-04-16 23:15:50 +02:00
|
|
|
|
2019-11-14 16:01:18 +01:00
|
|
|
|
2015-02-15 23:06:14 +00:00
|
|
|
|
|
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2008-11-30 12:17:10 +01:00
|
|
|
|
2009-02-04 17:41:38 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2009-02-04 17:41:38 +01:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
2009-02-04 17:41:38 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-10-08 20:23:08 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
|
|
|
|
|
2009-02-04 17:41:38 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2019-11-14 16:01:18 +01:00
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-10-08 20:23:08 +02:00
|
|
|
|
2019-06-02 08:02:48 +08:00
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
|
|
|
|
|
2026-07-25 01:54:43 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
2012-02-09 21:58:32 +01:00
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-09-23 00:16:36 +02:00
|
|
|
|
2009-11-11 13:32:29 -08:00
|
|
|
|
2008-09-23 00:16:36 +02:00
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
2015-10-08 20:23:08 +02:00
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
|
|
|
|
|
2026-08-31 12:13:10 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
|
|
|
|
|
2009-11-13 14:26:23 +01:00
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
|
|
|
|
|
2019-08-14 20:02:52 +08:00
|
|
|
|
|
|
|
|
|
2021-08-17 11:03:12 +08:00
|
|
|
|
2019-08-14 20:02:52 +08:00
|
|
|
|
|
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2009-11-13 14:26:23 +01:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2012-02-09 21:58:32 +01:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-08-31 12:13:10 -04:00
|
|
|
|
2021-12-03 14:38:13 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-09-14 09:11:06 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2012-02-09 21:58:32 +01:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-09-14 09:11:06 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2026-02-21 16:37:42 -08:00
|
|
|
|
2014-09-14 09:11:06 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-01-28 20:27:34 -08:00
|
|
|
|
2014-09-14 09:11:06 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-09-16 04:44:50 +02:00
|
|
|
|
2014-09-14 09:11:06 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2014-09-16 04:44:50 +02:00
|
|
|
|
2013-10-11 06:19:18 -07:00
|
|
|
|
2014-09-14 09:11:06 +02:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2014-09-14 09:11:06 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2014-09-14 09:11:06 +02:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2014-09-14 09:11:06 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2014-09-14 09:11:06 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2014-09-14 09:11:06 +02:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2014-09-16 04:44:50 +02:00
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
2014-09-14 09:11:06 +02:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2014-09-14 09:11:06 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2014-09-14 09:11:06 +02:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2014-09-14 09:11:06 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2014-09-14 09:11:06 +02:00
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
2014-09-14 09:11:06 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
2014-09-14 09:11:06 +02:00
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
2020-04-03 21:43:59 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-09-16 04:44:50 +02:00
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
2014-09-14 09:11:06 +02:00
|
|
|
|
|
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
2014-09-14 09:11:06 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-09-14 08:49:34 +03:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2011-10-09 12:12:16 +02:00
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
2011-11-22 09:32:57 +08:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-09-14 09:11:06 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-11-05 07:33:56 +01:00
|
|
|
|
2014-09-14 09:11:06 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-02-14 19:17:09 +08:00
|
|
|
|
|
|
|
|
|
2014-09-14 09:11:06 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2019-10-28 17:09:09 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-09-14 09:11:06 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
2012-02-09 21:58:32 +01:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2013-10-10 09:47:55 -07:00
|
|
|
|
|
|
|
|
|
2020-04-03 21:43:59 +02:00
|
|
|
|
2009-02-04 17:41:38 +01:00
|
|
|
|
2008-11-30 12:17:12 +01:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
2011-01-17 00:09:38 +01:00
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
2012-02-09 21:58:32 +01:00
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-10-24 19:42:45 +02:00
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2020-04-03 21:43:59 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-08-23 11:46:37 +08:00
|
|
|
|
2020-04-03 21:43:59 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2020-04-08 10:57:03 +05:30
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2020-04-03 21:43:59 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2020-04-03 21:43:59 +02:00
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2013-10-10 09:47:55 -07:00
|
|
|
|
2010-07-16 17:20:33 -03:00
|
|
|
|
2011-02-11 13:00:06 +01:00
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2010-07-16 17:20:33 -03:00
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
2012-04-11 08:48:51 +02:00
|
|
|
|
2020-04-03 21:43:59 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-03-25 08:42:45 +08:00
|
|
|
|
2014-09-16 04:44:50 +02:00
|
|
|
|
2026-03-25 08:42:45 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2020-04-03 21:43:59 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Bluetooth: btusb: Always fallback to alt 1 for WBS
When alt mode 6 is not available, fallback to the kernel <= 5.7 behavior
of always using alt mode 1.
Prior to kernel 5.8, btusb would always use alt mode 1 for WBS (Wide
Band Speech aka mSBC aka transparent SCO). In commit baac6276c0a9
("Bluetooth: btusb: handle mSBC audio over USB Endpoints") this
was changed to use alt mode 6, which is the recommended mode in the
Bluetooth spec (Specifications of the Bluetooth System, v5.0, Vol 4.B
§2.2.1). However, many if not most BT USB adapters do not support alt
mode 6. In fact, I have been unable to find any which do.
In kernel 5.8, this was changed to use alt mode 6, and if not available,
use alt mode 0. But mode 0 has a zero byte max packet length and can
not possibly work. It is just there as a zero-bandwidth dummy mode to
work around a USB flaw that would prevent device enumeration if
insufficient bandwidth were available for the lowest isoc mode
supported.
In effect, WBS was broken for all USB-BT adapters that do not support
alt 6, which appears to nearly all of them.
Then in commit 461f95f04f19 ("Bluetooth: btusb: USB alternate setting 1 for
WBS") the 5.7 behavior was restored, but only for Realtek adapters.
I've tested a Broadcom BRCM20702A and CSR 8510 adapter, both work with
the 5.7 behavior and do not with the 5.8.
So get rid of the Realtek specific flag and use the 5.7 behavior for all
adapters as a fallback when alt 6 is not available. This was the
kernel's behavior prior to 5.8 and I can find no adapters for which it
is not correct. And even if there is an adapter for which this does not
work, the current behavior would be to fall back to alt 0, which can not
possibly work either, and so is no better.
Signed-off-by: Trent Piepho <tpiepho@gmail.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2020-12-09 17:20:03 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-07-26 21:02:06 +03:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Bluetooth: btusb: Always fallback to alt 1 for WBS
When alt mode 6 is not available, fallback to the kernel <= 5.7 behavior
of always using alt mode 1.
Prior to kernel 5.8, btusb would always use alt mode 1 for WBS (Wide
Band Speech aka mSBC aka transparent SCO). In commit baac6276c0a9
("Bluetooth: btusb: handle mSBC audio over USB Endpoints") this
was changed to use alt mode 6, which is the recommended mode in the
Bluetooth spec (Specifications of the Bluetooth System, v5.0, Vol 4.B
§2.2.1). However, many if not most BT USB adapters do not support alt
mode 6. In fact, I have been unable to find any which do.
In kernel 5.8, this was changed to use alt mode 6, and if not available,
use alt mode 0. But mode 0 has a zero byte max packet length and can
not possibly work. It is just there as a zero-bandwidth dummy mode to
work around a USB flaw that would prevent device enumeration if
insufficient bandwidth were available for the lowest isoc mode
supported.
In effect, WBS was broken for all USB-BT adapters that do not support
alt 6, which appears to nearly all of them.
Then in commit 461f95f04f19 ("Bluetooth: btusb: USB alternate setting 1 for
WBS") the 5.7 behavior was restored, but only for Realtek adapters.
I've tested a Broadcom BRCM20702A and CSR 8510 adapter, both work with
the 5.7 behavior and do not with the 5.8.
So get rid of the Realtek specific flag and use the 5.7 behavior for all
adapters as a fallback when alt 6 is not available. This was the
kernel's behavior prior to 5.8 and I can find no adapters for which it
is not correct. And even if there is an adapter for which this does not
work, the current behavior would be to fall back to alt 0, which can not
possibly work either, and so is no better.
Signed-off-by: Trent Piepho <tpiepho@gmail.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2020-12-09 17:20:03 -08:00
|
|
|
|
2021-07-26 21:02:06 +03:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-05-14 11:19:01 +08:00
|
|
|
|
2021-07-26 21:02:06 +03:00
|
|
|
|
|
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
2020-04-03 21:43:59 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-10-03 12:18:36 +05:30
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2010-07-16 17:20:33 -03:00
|
|
|
|
2011-02-11 13:00:06 +01:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-12-03 14:38:13 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2013-04-10 08:11:35 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
2013-04-10 08:11:35 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-01-03 03:02:36 -08:00
|
|
|
|
|
|
|
|
|
2020-12-05 16:02:00 +01:00
|
|
|
|
|
|
|
|
|
2014-01-03 03:02:36 -08:00
|
|
|
|
|
|
|
|
|
Bluetooth: btusb: Fix and detect most of the Chinese Bluetooth controllers
For some reason they tend to squat on the very first CSR/
Cambridge Silicon Radio VID/PID instead of paying fees.
This is an extremely common problem; the issue goes as back as 2013
and these devices are only getting more popular, even rebranded by
reputable vendors and sold by retailers everywhere.
So, at this point in time there are hundreds of modern dongles reusing
the ID of what originally was an early Bluetooth 1.1 controller.
Linux is the only place where they don't work due to spotty checks
in our detection code. It only covered a minimum subset.
So what's the big idea? Take advantage of the fact that all CSR
chips report the same internal version as both the LMP sub-version and
HCI revision number. It always matches, couple that with the manufacturer
code, that rarely lies, and we now have a good idea of who is who.
Additionally, by compiling a list of user-reported HCI/lsusb dumps, and
searching around for legit CSR dongles in similar product ranges we can
find what CSR BlueCore firmware supported which Bluetooth versions.
That way we can narrow down ranges of fakes for each of them.
e.g. Real CSR dongles with LMP subversion 0x73 are old enough that
support BT 1.1 only; so it's a dead giveaway when some
third-party BT 4.0 dongle reuses it.
So, to sum things up; there are multiple classes of fake controllers
reusing the same 0A12:0001 VID/PID. This has been broken for a while.
Known 'fake' bcdDevices: 0x0100, 0x0134, 0x1915, 0x2520, 0x7558, 0x8891
IC markings on 0x7558: FR3191AHAL 749H15143 (???)
https://bugzilla.kernel.org/show_bug.cgi?id=60824
Fixes: 81cac64ba258ae (Deal with USB devices that are faking CSR vendor)
Reported-by: Michał Wiśniewski <brylozketrzyn@gmail.com>
Tested-by: Mike Johnson <yuyuyak@gmail.com>
Tested-by: Ricardo Rodrigues <ekatonb@gmail.com>
Tested-by: M.Hanny Sabbagh <mhsabbagh@outlook.com>
Tested-by: Oussama BEN BRAHIM <b.brahim.oussama@gmail.com>
Tested-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2020-07-26 23:12:28 +02:00
|
|
|
|
Bluetooth: btusb: Add workaround for remote-wakeup issues with Barrot 8041a02 fake CSR controllers
With the recent btusb change to detect and deal with more fake CSR
controllers, I decided to see if fake CSR controllers with Barrot
8041a02 chips would now work.
After much experimentation I came to the conclusion that it works, if I
have autosuspend enabled initially and then disable it after the device
has suspended at least once. Yes this is very weird, but I've tried many
things, like manually clearing the remote-wakeup feature. Doing a
runtime-resume + runtime suspend is the only way to get the receiver
to actually report received data (and/or pairing info) through its
bulk rx endpoint.
But the funkyness of the bulk-endpoint does not stop there, I mainly
found out about this problem, because with autosuspend enabled
(which usually ensures the suspend at least once condition is met),
the receiver stops reporting received data through its bulk rx endpoint
as soon as autosuspend kicks in. So I initially just disabled
autosuspend, but then the receiver does not work at all.
This was with a fake CSR receiver with a Barrot 8041a02 chip with a
bcdDevice value of 0x8891, a lmp_subver of 0x1012, a hci_rev of 0x0810
and a hci_ver of BLUETOOTH_VER_4_0.
Summarizing this specific fake CSR receiver has the following 2 issues:
1. The bulk rx endpoint will never report any data unless
the device was suspended at least once.
2. They will not wakeup when autosuspended and receiving data on their
bulk rx endpoint from e.g. a keyboard or mouse (IOW remote-wakeup support
is broken for the bulk endpoint).
Add a workaround for 1. which enables runtime-suspend, force-suspends
the hci and then wakes-it up by disabling runtime-suspend again.
Add a workaround for 2. which clears the hci's can_wake flag, this way
the hci will still be autosuspended when it is not open.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2020-12-05 16:02:01 +01:00
|
|
|
|
2014-01-03 03:02:36 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-06-07 10:01:02 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-03-13 17:39:12 +01:00
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
2015-06-07 10:01:02 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-12-05 09:49:15 -08:00
|
|
|
|
|
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
2015-06-07 10:01:02 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-01-03 03:02:36 -08:00
|
|
|
|
2022-12-05 09:49:15 -08:00
|
|
|
|
|
|
|
|
|
2014-01-03 03:02:36 -08:00
|
|
|
|
2022-12-05 09:49:15 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-10-29 22:24:53 +02:00
|
|
|
|
Bluetooth: btusb: Fix and detect most of the Chinese Bluetooth controllers
For some reason they tend to squat on the very first CSR/
Cambridge Silicon Radio VID/PID instead of paying fees.
This is an extremely common problem; the issue goes as back as 2013
and these devices are only getting more popular, even rebranded by
reputable vendors and sold by retailers everywhere.
So, at this point in time there are hundreds of modern dongles reusing
the ID of what originally was an early Bluetooth 1.1 controller.
Linux is the only place where they don't work due to spotty checks
in our detection code. It only covered a minimum subset.
So what's the big idea? Take advantage of the fact that all CSR
chips report the same internal version as both the LMP sub-version and
HCI revision number. It always matches, couple that with the manufacturer
code, that rarely lies, and we now have a good idea of who is who.
Additionally, by compiling a list of user-reported HCI/lsusb dumps, and
searching around for legit CSR dongles in similar product ranges we can
find what CSR BlueCore firmware supported which Bluetooth versions.
That way we can narrow down ranges of fakes for each of them.
e.g. Real CSR dongles with LMP subversion 0x73 are old enough that
support BT 1.1 only; so it's a dead giveaway when some
third-party BT 4.0 dongle reuses it.
So, to sum things up; there are multiple classes of fake controllers
reusing the same 0A12:0001 VID/PID. This has been broken for a while.
Known 'fake' bcdDevices: 0x0100, 0x0134, 0x1915, 0x2520, 0x7558, 0x8891
IC markings on 0x7558: FR3191AHAL 749H15143 (???)
https://bugzilla.kernel.org/show_bug.cgi?id=60824
Fixes: 81cac64ba258ae (Deal with USB devices that are faking CSR vendor)
Reported-by: Michał Wiśniewski <brylozketrzyn@gmail.com>
Tested-by: Mike Johnson <yuyuyak@gmail.com>
Tested-by: Ricardo Rodrigues <ekatonb@gmail.com>
Tested-by: M.Hanny Sabbagh <mhsabbagh@outlook.com>
Tested-by: Oussama BEN BRAHIM <b.brahim.oussama@gmail.com>
Tested-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2020-07-26 23:12:28 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-08-30 21:47:21 +03:00
|
|
|
|
Bluetooth: btusb: Fix and detect most of the Chinese Bluetooth controllers
For some reason they tend to squat on the very first CSR/
Cambridge Silicon Radio VID/PID instead of paying fees.
This is an extremely common problem; the issue goes as back as 2013
and these devices are only getting more popular, even rebranded by
reputable vendors and sold by retailers everywhere.
So, at this point in time there are hundreds of modern dongles reusing
the ID of what originally was an early Bluetooth 1.1 controller.
Linux is the only place where they don't work due to spotty checks
in our detection code. It only covered a minimum subset.
So what's the big idea? Take advantage of the fact that all CSR
chips report the same internal version as both the LMP sub-version and
HCI revision number. It always matches, couple that with the manufacturer
code, that rarely lies, and we now have a good idea of who is who.
Additionally, by compiling a list of user-reported HCI/lsusb dumps, and
searching around for legit CSR dongles in similar product ranges we can
find what CSR BlueCore firmware supported which Bluetooth versions.
That way we can narrow down ranges of fakes for each of them.
e.g. Real CSR dongles with LMP subversion 0x73 are old enough that
support BT 1.1 only; so it's a dead giveaway when some
third-party BT 4.0 dongle reuses it.
So, to sum things up; there are multiple classes of fake controllers
reusing the same 0A12:0001 VID/PID. This has been broken for a while.
Known 'fake' bcdDevices: 0x0100, 0x0134, 0x1915, 0x2520, 0x7558, 0x8891
IC markings on 0x7558: FR3191AHAL 749H15143 (???)
https://bugzilla.kernel.org/show_bug.cgi?id=60824
Fixes: 81cac64ba258ae (Deal with USB devices that are faking CSR vendor)
Reported-by: Michał Wiśniewski <brylozketrzyn@gmail.com>
Tested-by: Mike Johnson <yuyuyak@gmail.com>
Tested-by: Ricardo Rodrigues <ekatonb@gmail.com>
Tested-by: M.Hanny Sabbagh <mhsabbagh@outlook.com>
Tested-by: Oussama BEN BRAHIM <b.brahim.oussama@gmail.com>
Tested-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2020-07-26 23:12:28 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-12-05 09:49:15 -08:00
|
|
|
|
Bluetooth: btusb: Fix and detect most of the Chinese Bluetooth controllers
For some reason they tend to squat on the very first CSR/
Cambridge Silicon Radio VID/PID instead of paying fees.
This is an extremely common problem; the issue goes as back as 2013
and these devices are only getting more popular, even rebranded by
reputable vendors and sold by retailers everywhere.
So, at this point in time there are hundreds of modern dongles reusing
the ID of what originally was an early Bluetooth 1.1 controller.
Linux is the only place where they don't work due to spotty checks
in our detection code. It only covered a minimum subset.
So what's the big idea? Take advantage of the fact that all CSR
chips report the same internal version as both the LMP sub-version and
HCI revision number. It always matches, couple that with the manufacturer
code, that rarely lies, and we now have a good idea of who is who.
Additionally, by compiling a list of user-reported HCI/lsusb dumps, and
searching around for legit CSR dongles in similar product ranges we can
find what CSR BlueCore firmware supported which Bluetooth versions.
That way we can narrow down ranges of fakes for each of them.
e.g. Real CSR dongles with LMP subversion 0x73 are old enough that
support BT 1.1 only; so it's a dead giveaway when some
third-party BT 4.0 dongle reuses it.
So, to sum things up; there are multiple classes of fake controllers
reusing the same 0A12:0001 VID/PID. This has been broken for a while.
Known 'fake' bcdDevices: 0x0100, 0x0134, 0x1915, 0x2520, 0x7558, 0x8891
IC markings on 0x7558: FR3191AHAL 749H15143 (???)
https://bugzilla.kernel.org/show_bug.cgi?id=60824
Fixes: 81cac64ba258ae (Deal with USB devices that are faking CSR vendor)
Reported-by: Michał Wiśniewski <brylozketrzyn@gmail.com>
Tested-by: Mike Johnson <yuyuyak@gmail.com>
Tested-by: Ricardo Rodrigues <ekatonb@gmail.com>
Tested-by: M.Hanny Sabbagh <mhsabbagh@outlook.com>
Tested-by: Oussama BEN BRAHIM <b.brahim.oussama@gmail.com>
Tested-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2020-07-26 23:12:28 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-12-05 09:49:15 -08:00
|
|
|
|
Bluetooth: btusb: Fix and detect most of the Chinese Bluetooth controllers
For some reason they tend to squat on the very first CSR/
Cambridge Silicon Radio VID/PID instead of paying fees.
This is an extremely common problem; the issue goes as back as 2013
and these devices are only getting more popular, even rebranded by
reputable vendors and sold by retailers everywhere.
So, at this point in time there are hundreds of modern dongles reusing
the ID of what originally was an early Bluetooth 1.1 controller.
Linux is the only place where they don't work due to spotty checks
in our detection code. It only covered a minimum subset.
So what's the big idea? Take advantage of the fact that all CSR
chips report the same internal version as both the LMP sub-version and
HCI revision number. It always matches, couple that with the manufacturer
code, that rarely lies, and we now have a good idea of who is who.
Additionally, by compiling a list of user-reported HCI/lsusb dumps, and
searching around for legit CSR dongles in similar product ranges we can
find what CSR BlueCore firmware supported which Bluetooth versions.
That way we can narrow down ranges of fakes for each of them.
e.g. Real CSR dongles with LMP subversion 0x73 are old enough that
support BT 1.1 only; so it's a dead giveaway when some
third-party BT 4.0 dongle reuses it.
So, to sum things up; there are multiple classes of fake controllers
reusing the same 0A12:0001 VID/PID. This has been broken for a while.
Known 'fake' bcdDevices: 0x0100, 0x0134, 0x1915, 0x2520, 0x7558, 0x8891
IC markings on 0x7558: FR3191AHAL 749H15143 (???)
https://bugzilla.kernel.org/show_bug.cgi?id=60824
Fixes: 81cac64ba258ae (Deal with USB devices that are faking CSR vendor)
Reported-by: Michał Wiśniewski <brylozketrzyn@gmail.com>
Tested-by: Mike Johnson <yuyuyak@gmail.com>
Tested-by: Ricardo Rodrigues <ekatonb@gmail.com>
Tested-by: M.Hanny Sabbagh <mhsabbagh@outlook.com>
Tested-by: Oussama BEN BRAHIM <b.brahim.oussama@gmail.com>
Tested-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2020-07-26 23:12:28 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-12-05 09:49:15 -08:00
|
|
|
|
Bluetooth: btusb: Fix and detect most of the Chinese Bluetooth controllers
For some reason they tend to squat on the very first CSR/
Cambridge Silicon Radio VID/PID instead of paying fees.
This is an extremely common problem; the issue goes as back as 2013
and these devices are only getting more popular, even rebranded by
reputable vendors and sold by retailers everywhere.
So, at this point in time there are hundreds of modern dongles reusing
the ID of what originally was an early Bluetooth 1.1 controller.
Linux is the only place where they don't work due to spotty checks
in our detection code. It only covered a minimum subset.
So what's the big idea? Take advantage of the fact that all CSR
chips report the same internal version as both the LMP sub-version and
HCI revision number. It always matches, couple that with the manufacturer
code, that rarely lies, and we now have a good idea of who is who.
Additionally, by compiling a list of user-reported HCI/lsusb dumps, and
searching around for legit CSR dongles in similar product ranges we can
find what CSR BlueCore firmware supported which Bluetooth versions.
That way we can narrow down ranges of fakes for each of them.
e.g. Real CSR dongles with LMP subversion 0x73 are old enough that
support BT 1.1 only; so it's a dead giveaway when some
third-party BT 4.0 dongle reuses it.
So, to sum things up; there are multiple classes of fake controllers
reusing the same 0A12:0001 VID/PID. This has been broken for a while.
Known 'fake' bcdDevices: 0x0100, 0x0134, 0x1915, 0x2520, 0x7558, 0x8891
IC markings on 0x7558: FR3191AHAL 749H15143 (???)
https://bugzilla.kernel.org/show_bug.cgi?id=60824
Fixes: 81cac64ba258ae (Deal with USB devices that are faking CSR vendor)
Reported-by: Michał Wiśniewski <brylozketrzyn@gmail.com>
Tested-by: Mike Johnson <yuyuyak@gmail.com>
Tested-by: Ricardo Rodrigues <ekatonb@gmail.com>
Tested-by: M.Hanny Sabbagh <mhsabbagh@outlook.com>
Tested-by: Oussama BEN BRAHIM <b.brahim.oussama@gmail.com>
Tested-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2020-07-26 23:12:28 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-12-05 09:49:15 -08:00
|
|
|
|
Bluetooth: btusb: Fix and detect most of the Chinese Bluetooth controllers
For some reason they tend to squat on the very first CSR/
Cambridge Silicon Radio VID/PID instead of paying fees.
This is an extremely common problem; the issue goes as back as 2013
and these devices are only getting more popular, even rebranded by
reputable vendors and sold by retailers everywhere.
So, at this point in time there are hundreds of modern dongles reusing
the ID of what originally was an early Bluetooth 1.1 controller.
Linux is the only place where they don't work due to spotty checks
in our detection code. It only covered a minimum subset.
So what's the big idea? Take advantage of the fact that all CSR
chips report the same internal version as both the LMP sub-version and
HCI revision number. It always matches, couple that with the manufacturer
code, that rarely lies, and we now have a good idea of who is who.
Additionally, by compiling a list of user-reported HCI/lsusb dumps, and
searching around for legit CSR dongles in similar product ranges we can
find what CSR BlueCore firmware supported which Bluetooth versions.
That way we can narrow down ranges of fakes for each of them.
e.g. Real CSR dongles with LMP subversion 0x73 are old enough that
support BT 1.1 only; so it's a dead giveaway when some
third-party BT 4.0 dongle reuses it.
So, to sum things up; there are multiple classes of fake controllers
reusing the same 0A12:0001 VID/PID. This has been broken for a while.
Known 'fake' bcdDevices: 0x0100, 0x0134, 0x1915, 0x2520, 0x7558, 0x8891
IC markings on 0x7558: FR3191AHAL 749H15143 (???)
https://bugzilla.kernel.org/show_bug.cgi?id=60824
Fixes: 81cac64ba258ae (Deal with USB devices that are faking CSR vendor)
Reported-by: Michał Wiśniewski <brylozketrzyn@gmail.com>
Tested-by: Mike Johnson <yuyuyak@gmail.com>
Tested-by: Ricardo Rodrigues <ekatonb@gmail.com>
Tested-by: M.Hanny Sabbagh <mhsabbagh@outlook.com>
Tested-by: Oussama BEN BRAHIM <b.brahim.oussama@gmail.com>
Tested-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2020-07-26 23:12:28 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-12-05 09:49:15 -08:00
|
|
|
|
Bluetooth: btusb: Fix and detect most of the Chinese Bluetooth controllers
For some reason they tend to squat on the very first CSR/
Cambridge Silicon Radio VID/PID instead of paying fees.
This is an extremely common problem; the issue goes as back as 2013
and these devices are only getting more popular, even rebranded by
reputable vendors and sold by retailers everywhere.
So, at this point in time there are hundreds of modern dongles reusing
the ID of what originally was an early Bluetooth 1.1 controller.
Linux is the only place where they don't work due to spotty checks
in our detection code. It only covered a minimum subset.
So what's the big idea? Take advantage of the fact that all CSR
chips report the same internal version as both the LMP sub-version and
HCI revision number. It always matches, couple that with the manufacturer
code, that rarely lies, and we now have a good idea of who is who.
Additionally, by compiling a list of user-reported HCI/lsusb dumps, and
searching around for legit CSR dongles in similar product ranges we can
find what CSR BlueCore firmware supported which Bluetooth versions.
That way we can narrow down ranges of fakes for each of them.
e.g. Real CSR dongles with LMP subversion 0x73 are old enough that
support BT 1.1 only; so it's a dead giveaway when some
third-party BT 4.0 dongle reuses it.
So, to sum things up; there are multiple classes of fake controllers
reusing the same 0A12:0001 VID/PID. This has been broken for a while.
Known 'fake' bcdDevices: 0x0100, 0x0134, 0x1915, 0x2520, 0x7558, 0x8891
IC markings on 0x7558: FR3191AHAL 749H15143 (???)
https://bugzilla.kernel.org/show_bug.cgi?id=60824
Fixes: 81cac64ba258ae (Deal with USB devices that are faking CSR vendor)
Reported-by: Michał Wiśniewski <brylozketrzyn@gmail.com>
Tested-by: Mike Johnson <yuyuyak@gmail.com>
Tested-by: Ricardo Rodrigues <ekatonb@gmail.com>
Tested-by: M.Hanny Sabbagh <mhsabbagh@outlook.com>
Tested-by: Oussama BEN BRAHIM <b.brahim.oussama@gmail.com>
Tested-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2020-07-26 23:12:28 +02:00
|
|
|
|
|
|
|
|
|
2020-12-05 16:02:00 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-12-05 09:49:15 -08:00
|
|
|
|
2020-12-05 16:02:00 +01:00
|
|
|
|
|
|
|
|
|
Bluetooth: btusb: Fix and detect most of the Chinese Bluetooth controllers
For some reason they tend to squat on the very first CSR/
Cambridge Silicon Radio VID/PID instead of paying fees.
This is an extremely common problem; the issue goes as back as 2013
and these devices are only getting more popular, even rebranded by
reputable vendors and sold by retailers everywhere.
So, at this point in time there are hundreds of modern dongles reusing
the ID of what originally was an early Bluetooth 1.1 controller.
Linux is the only place where they don't work due to spotty checks
in our detection code. It only covered a minimum subset.
So what's the big idea? Take advantage of the fact that all CSR
chips report the same internal version as both the LMP sub-version and
HCI revision number. It always matches, couple that with the manufacturer
code, that rarely lies, and we now have a good idea of who is who.
Additionally, by compiling a list of user-reported HCI/lsusb dumps, and
searching around for legit CSR dongles in similar product ranges we can
find what CSR BlueCore firmware supported which Bluetooth versions.
That way we can narrow down ranges of fakes for each of them.
e.g. Real CSR dongles with LMP subversion 0x73 are old enough that
support BT 1.1 only; so it's a dead giveaway when some
third-party BT 4.0 dongle reuses it.
So, to sum things up; there are multiple classes of fake controllers
reusing the same 0A12:0001 VID/PID. This has been broken for a while.
Known 'fake' bcdDevices: 0x0100, 0x0134, 0x1915, 0x2520, 0x7558, 0x8891
IC markings on 0x7558: FR3191AHAL 749H15143 (???)
https://bugzilla.kernel.org/show_bug.cgi?id=60824
Fixes: 81cac64ba258ae (Deal with USB devices that are faking CSR vendor)
Reported-by: Michał Wiśniewski <brylozketrzyn@gmail.com>
Tested-by: Mike Johnson <yuyuyak@gmail.com>
Tested-by: Ricardo Rodrigues <ekatonb@gmail.com>
Tested-by: M.Hanny Sabbagh <mhsabbagh@outlook.com>
Tested-by: Oussama BEN BRAHIM <b.brahim.oussama@gmail.com>
Tested-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2020-07-26 23:12:28 +02:00
|
|
|
|
2021-07-17 01:21:43 +02:00
|
|
|
|
Bluetooth: btusb: Fix and detect most of the Chinese Bluetooth controllers
For some reason they tend to squat on the very first CSR/
Cambridge Silicon Radio VID/PID instead of paying fees.
This is an extremely common problem; the issue goes as back as 2013
and these devices are only getting more popular, even rebranded by
reputable vendors and sold by retailers everywhere.
So, at this point in time there are hundreds of modern dongles reusing
the ID of what originally was an early Bluetooth 1.1 controller.
Linux is the only place where they don't work due to spotty checks
in our detection code. It only covered a minimum subset.
So what's the big idea? Take advantage of the fact that all CSR
chips report the same internal version as both the LMP sub-version and
HCI revision number. It always matches, couple that with the manufacturer
code, that rarely lies, and we now have a good idea of who is who.
Additionally, by compiling a list of user-reported HCI/lsusb dumps, and
searching around for legit CSR dongles in similar product ranges we can
find what CSR BlueCore firmware supported which Bluetooth versions.
That way we can narrow down ranges of fakes for each of them.
e.g. Real CSR dongles with LMP subversion 0x73 are old enough that
support BT 1.1 only; so it's a dead giveaway when some
third-party BT 4.0 dongle reuses it.
So, to sum things up; there are multiple classes of fake controllers
reusing the same 0A12:0001 VID/PID. This has been broken for a while.
Known 'fake' bcdDevices: 0x0100, 0x0134, 0x1915, 0x2520, 0x7558, 0x8891
IC markings on 0x7558: FR3191AHAL 749H15143 (???)
https://bugzilla.kernel.org/show_bug.cgi?id=60824
Fixes: 81cac64ba258ae (Deal with USB devices that are faking CSR vendor)
Reported-by: Michał Wiśniewski <brylozketrzyn@gmail.com>
Tested-by: Mike Johnson <yuyuyak@gmail.com>
Tested-by: Ricardo Rodrigues <ekatonb@gmail.com>
Tested-by: M.Hanny Sabbagh <mhsabbagh@outlook.com>
Tested-by: Oussama BEN BRAHIM <b.brahim.oussama@gmail.com>
Tested-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2020-07-26 23:12:28 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-07-14 22:27:45 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Bluetooth: btusb: Fix and detect most of the Chinese Bluetooth controllers
For some reason they tend to squat on the very first CSR/
Cambridge Silicon Radio VID/PID instead of paying fees.
This is an extremely common problem; the issue goes as back as 2013
and these devices are only getting more popular, even rebranded by
reputable vendors and sold by retailers everywhere.
So, at this point in time there are hundreds of modern dongles reusing
the ID of what originally was an early Bluetooth 1.1 controller.
Linux is the only place where they don't work due to spotty checks
in our detection code. It only covered a minimum subset.
So what's the big idea? Take advantage of the fact that all CSR
chips report the same internal version as both the LMP sub-version and
HCI revision number. It always matches, couple that with the manufacturer
code, that rarely lies, and we now have a good idea of who is who.
Additionally, by compiling a list of user-reported HCI/lsusb dumps, and
searching around for legit CSR dongles in similar product ranges we can
find what CSR BlueCore firmware supported which Bluetooth versions.
That way we can narrow down ranges of fakes for each of them.
e.g. Real CSR dongles with LMP subversion 0x73 are old enough that
support BT 1.1 only; so it's a dead giveaway when some
third-party BT 4.0 dongle reuses it.
So, to sum things up; there are multiple classes of fake controllers
reusing the same 0A12:0001 VID/PID. This has been broken for a while.
Known 'fake' bcdDevices: 0x0100, 0x0134, 0x1915, 0x2520, 0x7558, 0x8891
IC markings on 0x7558: FR3191AHAL 749H15143 (???)
https://bugzilla.kernel.org/show_bug.cgi?id=60824
Fixes: 81cac64ba258ae (Deal with USB devices that are faking CSR vendor)
Reported-by: Michał Wiśniewski <brylozketrzyn@gmail.com>
Tested-by: Mike Johnson <yuyuyak@gmail.com>
Tested-by: Ricardo Rodrigues <ekatonb@gmail.com>
Tested-by: M.Hanny Sabbagh <mhsabbagh@outlook.com>
Tested-by: Oussama BEN BRAHIM <b.brahim.oussama@gmail.com>
Tested-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2020-07-26 23:12:28 +02:00
|
|
|
|
2015-06-07 10:01:01 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-07-14 22:27:45 +02:00
|
|
|
|
|
|
|
|
|
Bluetooth: btusb: Add workaround for remote-wakeup issues with Barrot 8041a02 fake CSR controllers
With the recent btusb change to detect and deal with more fake CSR
controllers, I decided to see if fake CSR controllers with Barrot
8041a02 chips would now work.
After much experimentation I came to the conclusion that it works, if I
have autosuspend enabled initially and then disable it after the device
has suspended at least once. Yes this is very weird, but I've tried many
things, like manually clearing the remote-wakeup feature. Doing a
runtime-resume + runtime suspend is the only way to get the receiver
to actually report received data (and/or pairing info) through its
bulk rx endpoint.
But the funkyness of the bulk-endpoint does not stop there, I mainly
found out about this problem, because with autosuspend enabled
(which usually ensures the suspend at least once condition is met),
the receiver stops reporting received data through its bulk rx endpoint
as soon as autosuspend kicks in. So I initially just disabled
autosuspend, but then the receiver does not work at all.
This was with a fake CSR receiver with a Barrot 8041a02 chip with a
bcdDevice value of 0x8891, a lmp_subver of 0x1012, a hci_rev of 0x0810
and a hci_ver of BLUETOOTH_VER_4_0.
Summarizing this specific fake CSR receiver has the following 2 issues:
1. The bulk rx endpoint will never report any data unless
the device was suspended at least once.
2. They will not wakeup when autosuspended and receiving data on their
bulk rx endpoint from e.g. a keyboard or mouse (IOW remote-wakeup support
is broken for the bulk endpoint).
Add a workaround for 1. which enables runtime-suspend, force-suspends
the hci and then wakes-it up by disabling runtime-suspend again.
Add a workaround for 2. which clears the hci's can_wake flag, this way
the hci will still be autosuspended when it is not open.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2020-12-05 16:02:01 +01:00
|
|
|
|
|
|
|
|
|
2021-07-17 01:21:43 +02:00
|
|
|
|
|
|
|
|
|
Bluetooth: btusb: Use quirk to skip HCI_FLT_CLEAR_ALL on fake CSR controllers
Another subset of the more recent batch of Chinese clones aren't
specs-compliant and seem to lock up whenever they receive a
HCI_OP_SET_EVENT_FLT with flt_type set to zero/HCI_FLT_CLEAR_ALL,
which on Linux (until the recent HCI state-machine refactor) happened
right at BR/EDR setup. As there are other less-straightforward ways
of reaching those operations, this patch is still relevant.
So, while all the previous efforts to wrangle the herd of fake CSRs
seem to be paying off (and these also get detected as such) we
still need to take care of this quirk; testers seem to agree
that these dongles tend to work well enough afterwards.
From some cursory USB packet capture on Windows it seems like
that driver doesn't appear to use this clear-all functionality at all.
This patch was tested on some really popular AliExpress-style
dongles, in my case marked as "V5.0". Chip markings: UG8413,
the backside of the PCB says "USB Dangel" (sic).
Here is the `hciconfig -a` output; for completeness:
hci0: Type: Primary Bus: USB
BD Address: 00:1A:7D:DA:7X:XX ACL MTU: 679:8 SCO MTU: 48:16
UP RUNNING PSCAN ISCAN
Features: 0xbf 0x3e 0x4d 0xfa 0xdb 0x3d 0x7b 0xc7
Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3
Link policy: RSWITCH SNIFF
Link mode: PERIPHERAL ACCEPT
Name: 'CSR8510 A10.'
Class: 0x7c0104
Service Classes: Rendering, Capturing, Object Transfer, Audio, Telephony
Device Class: Computer, Desktop workstation
HCI Version: 4.0 (0x6) Revision: 0x3120
LMP Version: 4.0 (0x6) Subversion: 0x22bb
Manufacturer: Cambridge Silicon Radio (10)
As well as the `lsusb -vv -d 0a12:0001`:
ID 0a12:0001 Cambridge Silicon Radio, Ltd Bluetooth Dongle (HCI mode)
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 2.00
bDeviceClass 224 Wireless
bDeviceSubClass 1 Radio Frequency
bDeviceProtocol 1 Bluetooth
bMaxPacketSize0 64
idVendor 0x0a12 Cambridge Silicon Radio, Ltd
idProduct 0x0001 Bluetooth Dongle (HCI mode)
bcdDevice 88.91
iManufacturer 0
iProduct 2 BT DONGLE10
iSerial 0
bNumConfigurations 1
Also, changed the benign dmesg print that shows up whenever the
generic force-suspend fails from bt_dev_err to bt_dev_warn;
it's okay and done on a best-effort basis, not a problem
if that does not work.
Also, swapped the HCI subver and LMP subver numbers for the Barrot
in the comment, which I copied wrong the last time around.
Fixes: 81cac64ba258a ("Bluetooth: Deal with USB devices that are faking CSR vendor")
Fixes: cde1a8a992875 ("Bluetooth: btusb: Fix and detect most of the Chinese Bluetooth controllers")
Fixes: d74e0ae7e0303 ("Bluetooth: btusb: Fix detection of some fake CSR controllers with a bcdDevice val of 0x0134")
Fixes: 0671c0662383e ("Bluetooth: btusb: Add workaround for remote-wakeup issues with Barrot 8041a02 fake CSR controllers")
Fixes: f4292e2faf522 ("Bluetooth: btusb: Make the CSR clone chip force-suspend workaround more generic")
Link: https://bugzilla.kernel.org/show_bug.cgi?id=60824
Link: https://gist.github.com/nevack/6b36b82d715dc025163d9e9124840a07
Cc: stable@vger.kernel.org
Cc: Hans de Goede <hdegoede@redhat.com>
Tested-by: Gonzalo Tornaría <tornaria@cmat.edu.uy>
Tested-by: Mateus Lemos <lemonsmateus@gmail.com>
Tested-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2022-03-07 21:04:45 +01:00
|
|
|
|
2021-07-17 01:21:43 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-01-18 09:04:19 +01:00
|
|
|
|
Bluetooth: btusb: Add workaround for remote-wakeup issues with Barrot 8041a02 fake CSR controllers
With the recent btusb change to detect and deal with more fake CSR
controllers, I decided to see if fake CSR controllers with Barrot
8041a02 chips would now work.
After much experimentation I came to the conclusion that it works, if I
have autosuspend enabled initially and then disable it after the device
has suspended at least once. Yes this is very weird, but I've tried many
things, like manually clearing the remote-wakeup feature. Doing a
runtime-resume + runtime suspend is the only way to get the receiver
to actually report received data (and/or pairing info) through its
bulk rx endpoint.
But the funkyness of the bulk-endpoint does not stop there, I mainly
found out about this problem, because with autosuspend enabled
(which usually ensures the suspend at least once condition is met),
the receiver stops reporting received data through its bulk rx endpoint
as soon as autosuspend kicks in. So I initially just disabled
autosuspend, but then the receiver does not work at all.
This was with a fake CSR receiver with a Barrot 8041a02 chip with a
bcdDevice value of 0x8891, a lmp_subver of 0x1012, a hci_rev of 0x0810
and a hci_ver of BLUETOOTH_VER_4_0.
Summarizing this specific fake CSR receiver has the following 2 issues:
1. The bulk rx endpoint will never report any data unless
the device was suspended at least once.
2. They will not wakeup when autosuspended and receiving data on their
bulk rx endpoint from e.g. a keyboard or mouse (IOW remote-wakeup support
is broken for the bulk endpoint).
Add a workaround for 1. which enables runtime-suspend, force-suspends
the hci and then wakes-it up by disabling runtime-suspend again.
Add a workaround for 2. which clears the hci's can_wake flag, this way
the hci will still be autosuspended when it is not open.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2020-12-05 16:02:01 +01:00
|
|
|
|
2022-01-18 09:04:19 +01:00
|
|
|
|
|
|
|
|
|
Bluetooth: btusb: Add workaround for remote-wakeup issues with Barrot 8041a02 fake CSR controllers
With the recent btusb change to detect and deal with more fake CSR
controllers, I decided to see if fake CSR controllers with Barrot
8041a02 chips would now work.
After much experimentation I came to the conclusion that it works, if I
have autosuspend enabled initially and then disable it after the device
has suspended at least once. Yes this is very weird, but I've tried many
things, like manually clearing the remote-wakeup feature. Doing a
runtime-resume + runtime suspend is the only way to get the receiver
to actually report received data (and/or pairing info) through its
bulk rx endpoint.
But the funkyness of the bulk-endpoint does not stop there, I mainly
found out about this problem, because with autosuspend enabled
(which usually ensures the suspend at least once condition is met),
the receiver stops reporting received data through its bulk rx endpoint
as soon as autosuspend kicks in. So I initially just disabled
autosuspend, but then the receiver does not work at all.
This was with a fake CSR receiver with a Barrot 8041a02 chip with a
bcdDevice value of 0x8891, a lmp_subver of 0x1012, a hci_rev of 0x0810
and a hci_ver of BLUETOOTH_VER_4_0.
Summarizing this specific fake CSR receiver has the following 2 issues:
1. The bulk rx endpoint will never report any data unless
the device was suspended at least once.
2. They will not wakeup when autosuspended and receiving data on their
bulk rx endpoint from e.g. a keyboard or mouse (IOW remote-wakeup support
is broken for the bulk endpoint).
Add a workaround for 1. which enables runtime-suspend, force-suspends
the hci and then wakes-it up by disabling runtime-suspend again.
Add a workaround for 2. which clears the hci's can_wake flag, this way
the hci will still be autosuspended when it is not open.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2020-12-05 16:02:01 +01:00
|
|
|
|
|
|
|
|
|
2021-07-17 01:21:43 +02:00
|
|
|
|
Bluetooth: btusb: Add workaround for remote-wakeup issues with Barrot 8041a02 fake CSR controllers
With the recent btusb change to detect and deal with more fake CSR
controllers, I decided to see if fake CSR controllers with Barrot
8041a02 chips would now work.
After much experimentation I came to the conclusion that it works, if I
have autosuspend enabled initially and then disable it after the device
has suspended at least once. Yes this is very weird, but I've tried many
things, like manually clearing the remote-wakeup feature. Doing a
runtime-resume + runtime suspend is the only way to get the receiver
to actually report received data (and/or pairing info) through its
bulk rx endpoint.
But the funkyness of the bulk-endpoint does not stop there, I mainly
found out about this problem, because with autosuspend enabled
(which usually ensures the suspend at least once condition is met),
the receiver stops reporting received data through its bulk rx endpoint
as soon as autosuspend kicks in. So I initially just disabled
autosuspend, but then the receiver does not work at all.
This was with a fake CSR receiver with a Barrot 8041a02 chip with a
bcdDevice value of 0x8891, a lmp_subver of 0x1012, a hci_rev of 0x0810
and a hci_ver of BLUETOOTH_VER_4_0.
Summarizing this specific fake CSR receiver has the following 2 issues:
1. The bulk rx endpoint will never report any data unless
the device was suspended at least once.
2. They will not wakeup when autosuspended and receiving data on their
bulk rx endpoint from e.g. a keyboard or mouse (IOW remote-wakeup support
is broken for the bulk endpoint).
Add a workaround for 1. which enables runtime-suspend, force-suspends
the hci and then wakes-it up by disabling runtime-suspend again.
Add a workaround for 2. which clears the hci's can_wake flag, this way
the hci will still be autosuspended when it is not open.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2020-12-05 16:02:01 +01:00
|
|
|
|
2021-07-17 01:21:43 +02:00
|
|
|
|
Bluetooth: btusb: Add workaround for remote-wakeup issues with Barrot 8041a02 fake CSR controllers
With the recent btusb change to detect and deal with more fake CSR
controllers, I decided to see if fake CSR controllers with Barrot
8041a02 chips would now work.
After much experimentation I came to the conclusion that it works, if I
have autosuspend enabled initially and then disable it after the device
has suspended at least once. Yes this is very weird, but I've tried many
things, like manually clearing the remote-wakeup feature. Doing a
runtime-resume + runtime suspend is the only way to get the receiver
to actually report received data (and/or pairing info) through its
bulk rx endpoint.
But the funkyness of the bulk-endpoint does not stop there, I mainly
found out about this problem, because with autosuspend enabled
(which usually ensures the suspend at least once condition is met),
the receiver stops reporting received data through its bulk rx endpoint
as soon as autosuspend kicks in. So I initially just disabled
autosuspend, but then the receiver does not work at all.
This was with a fake CSR receiver with a Barrot 8041a02 chip with a
bcdDevice value of 0x8891, a lmp_subver of 0x1012, a hci_rev of 0x0810
and a hci_ver of BLUETOOTH_VER_4_0.
Summarizing this specific fake CSR receiver has the following 2 issues:
1. The bulk rx endpoint will never report any data unless
the device was suspended at least once.
2. They will not wakeup when autosuspended and receiving data on their
bulk rx endpoint from e.g. a keyboard or mouse (IOW remote-wakeup support
is broken for the bulk endpoint).
Add a workaround for 1. which enables runtime-suspend, force-suspends
the hci and then wakes-it up by disabling runtime-suspend again.
Add a workaround for 2. which clears the hci's can_wake flag, this way
the hci will still be autosuspended when it is not open.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2020-12-05 16:02:01 +01:00
|
|
|
|
2021-07-17 01:21:43 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Bluetooth: btusb: Add workaround for remote-wakeup issues with Barrot 8041a02 fake CSR controllers
With the recent btusb change to detect and deal with more fake CSR
controllers, I decided to see if fake CSR controllers with Barrot
8041a02 chips would now work.
After much experimentation I came to the conclusion that it works, if I
have autosuspend enabled initially and then disable it after the device
has suspended at least once. Yes this is very weird, but I've tried many
things, like manually clearing the remote-wakeup feature. Doing a
runtime-resume + runtime suspend is the only way to get the receiver
to actually report received data (and/or pairing info) through its
bulk rx endpoint.
But the funkyness of the bulk-endpoint does not stop there, I mainly
found out about this problem, because with autosuspend enabled
(which usually ensures the suspend at least once condition is met),
the receiver stops reporting received data through its bulk rx endpoint
as soon as autosuspend kicks in. So I initially just disabled
autosuspend, but then the receiver does not work at all.
This was with a fake CSR receiver with a Barrot 8041a02 chip with a
bcdDevice value of 0x8891, a lmp_subver of 0x1012, a hci_rev of 0x0810
and a hci_ver of BLUETOOTH_VER_4_0.
Summarizing this specific fake CSR receiver has the following 2 issues:
1. The bulk rx endpoint will never report any data unless
the device was suspended at least once.
2. They will not wakeup when autosuspended and receiving data on their
bulk rx endpoint from e.g. a keyboard or mouse (IOW remote-wakeup support
is broken for the bulk endpoint).
Add a workaround for 1. which enables runtime-suspend, force-suspends
the hci and then wakes-it up by disabling runtime-suspend again.
Add a workaround for 2. which clears the hci's can_wake flag, this way
the hci will still be autosuspended when it is not open.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2020-12-05 16:02:01 +01:00
|
|
|
|
2021-07-17 01:21:43 +02:00
|
|
|
|
Bluetooth: btusb: Add workaround for remote-wakeup issues with Barrot 8041a02 fake CSR controllers
With the recent btusb change to detect and deal with more fake CSR
controllers, I decided to see if fake CSR controllers with Barrot
8041a02 chips would now work.
After much experimentation I came to the conclusion that it works, if I
have autosuspend enabled initially and then disable it after the device
has suspended at least once. Yes this is very weird, but I've tried many
things, like manually clearing the remote-wakeup feature. Doing a
runtime-resume + runtime suspend is the only way to get the receiver
to actually report received data (and/or pairing info) through its
bulk rx endpoint.
But the funkyness of the bulk-endpoint does not stop there, I mainly
found out about this problem, because with autosuspend enabled
(which usually ensures the suspend at least once condition is met),
the receiver stops reporting received data through its bulk rx endpoint
as soon as autosuspend kicks in. So I initially just disabled
autosuspend, but then the receiver does not work at all.
This was with a fake CSR receiver with a Barrot 8041a02 chip with a
bcdDevice value of 0x8891, a lmp_subver of 0x1012, a hci_rev of 0x0810
and a hci_ver of BLUETOOTH_VER_4_0.
Summarizing this specific fake CSR receiver has the following 2 issues:
1. The bulk rx endpoint will never report any data unless
the device was suspended at least once.
2. They will not wakeup when autosuspended and receiving data on their
bulk rx endpoint from e.g. a keyboard or mouse (IOW remote-wakeup support
is broken for the bulk endpoint).
Add a workaround for 1. which enables runtime-suspend, force-suspends
the hci and then wakes-it up by disabling runtime-suspend again.
Add a workaround for 2. which clears the hci's can_wake flag, this way
the hci will still be autosuspended when it is not open.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2020-12-05 16:02:01 +01:00
|
|
|
|
2021-07-17 01:21:43 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Bluetooth: btusb: Use quirk to skip HCI_FLT_CLEAR_ALL on fake CSR controllers
Another subset of the more recent batch of Chinese clones aren't
specs-compliant and seem to lock up whenever they receive a
HCI_OP_SET_EVENT_FLT with flt_type set to zero/HCI_FLT_CLEAR_ALL,
which on Linux (until the recent HCI state-machine refactor) happened
right at BR/EDR setup. As there are other less-straightforward ways
of reaching those operations, this patch is still relevant.
So, while all the previous efforts to wrangle the herd of fake CSRs
seem to be paying off (and these also get detected as such) we
still need to take care of this quirk; testers seem to agree
that these dongles tend to work well enough afterwards.
From some cursory USB packet capture on Windows it seems like
that driver doesn't appear to use this clear-all functionality at all.
This patch was tested on some really popular AliExpress-style
dongles, in my case marked as "V5.0". Chip markings: UG8413,
the backside of the PCB says "USB Dangel" (sic).
Here is the `hciconfig -a` output; for completeness:
hci0: Type: Primary Bus: USB
BD Address: 00:1A:7D:DA:7X:XX ACL MTU: 679:8 SCO MTU: 48:16
UP RUNNING PSCAN ISCAN
Features: 0xbf 0x3e 0x4d 0xfa 0xdb 0x3d 0x7b 0xc7
Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3
Link policy: RSWITCH SNIFF
Link mode: PERIPHERAL ACCEPT
Name: 'CSR8510 A10.'
Class: 0x7c0104
Service Classes: Rendering, Capturing, Object Transfer, Audio, Telephony
Device Class: Computer, Desktop workstation
HCI Version: 4.0 (0x6) Revision: 0x3120
LMP Version: 4.0 (0x6) Subversion: 0x22bb
Manufacturer: Cambridge Silicon Radio (10)
As well as the `lsusb -vv -d 0a12:0001`:
ID 0a12:0001 Cambridge Silicon Radio, Ltd Bluetooth Dongle (HCI mode)
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 2.00
bDeviceClass 224 Wireless
bDeviceSubClass 1 Radio Frequency
bDeviceProtocol 1 Bluetooth
bMaxPacketSize0 64
idVendor 0x0a12 Cambridge Silicon Radio, Ltd
idProduct 0x0001 Bluetooth Dongle (HCI mode)
bcdDevice 88.91
iManufacturer 0
iProduct 2 BT DONGLE10
iSerial 0
bNumConfigurations 1
Also, changed the benign dmesg print that shows up whenever the
generic force-suspend fails from bt_dev_err to bt_dev_warn;
it's okay and done on a best-effort basis, not a problem
if that does not work.
Also, swapped the HCI subver and LMP subver numbers for the Barrot
in the comment, which I copied wrong the last time around.
Fixes: 81cac64ba258a ("Bluetooth: Deal with USB devices that are faking CSR vendor")
Fixes: cde1a8a992875 ("Bluetooth: btusb: Fix and detect most of the Chinese Bluetooth controllers")
Fixes: d74e0ae7e0303 ("Bluetooth: btusb: Fix detection of some fake CSR controllers with a bcdDevice val of 0x0134")
Fixes: 0671c0662383e ("Bluetooth: btusb: Add workaround for remote-wakeup issues with Barrot 8041a02 fake CSR controllers")
Fixes: f4292e2faf522 ("Bluetooth: btusb: Make the CSR clone chip force-suspend workaround more generic")
Link: https://bugzilla.kernel.org/show_bug.cgi?id=60824
Link: https://gist.github.com/nevack/6b36b82d715dc025163d9e9124840a07
Cc: stable@vger.kernel.org
Cc: Hans de Goede <hdegoede@redhat.com>
Tested-by: Gonzalo Tornaría <tornaria@cmat.edu.uy>
Tested-by: Mateus Lemos <lemonsmateus@gmail.com>
Tested-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2022-03-07 21:04:45 +01:00
|
|
|
|
Bluetooth: btusb: Add workaround for remote-wakeup issues with Barrot 8041a02 fake CSR controllers
With the recent btusb change to detect and deal with more fake CSR
controllers, I decided to see if fake CSR controllers with Barrot
8041a02 chips would now work.
After much experimentation I came to the conclusion that it works, if I
have autosuspend enabled initially and then disable it after the device
has suspended at least once. Yes this is very weird, but I've tried many
things, like manually clearing the remote-wakeup feature. Doing a
runtime-resume + runtime suspend is the only way to get the receiver
to actually report received data (and/or pairing info) through its
bulk rx endpoint.
But the funkyness of the bulk-endpoint does not stop there, I mainly
found out about this problem, because with autosuspend enabled
(which usually ensures the suspend at least once condition is met),
the receiver stops reporting received data through its bulk rx endpoint
as soon as autosuspend kicks in. So I initially just disabled
autosuspend, but then the receiver does not work at all.
This was with a fake CSR receiver with a Barrot 8041a02 chip with a
bcdDevice value of 0x8891, a lmp_subver of 0x1012, a hci_rev of 0x0810
and a hci_ver of BLUETOOTH_VER_4_0.
Summarizing this specific fake CSR receiver has the following 2 issues:
1. The bulk rx endpoint will never report any data unless
the device was suspended at least once.
2. They will not wakeup when autosuspended and receiving data on their
bulk rx endpoint from e.g. a keyboard or mouse (IOW remote-wakeup support
is broken for the bulk endpoint).
Add a workaround for 1. which enables runtime-suspend, force-suspends
the hci and then wakes-it up by disabling runtime-suspend again.
Add a workaround for 2. which clears the hci's can_wake flag, this way
the hci will still be autosuspended when it is not open.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2020-12-05 16:02:01 +01:00
|
|
|
|
2021-07-17 01:21:43 +02:00
|
|
|
|
Bluetooth: btusb: Add workaround for remote-wakeup issues with Barrot 8041a02 fake CSR controllers
With the recent btusb change to detect and deal with more fake CSR
controllers, I decided to see if fake CSR controllers with Barrot
8041a02 chips would now work.
After much experimentation I came to the conclusion that it works, if I
have autosuspend enabled initially and then disable it after the device
has suspended at least once. Yes this is very weird, but I've tried many
things, like manually clearing the remote-wakeup feature. Doing a
runtime-resume + runtime suspend is the only way to get the receiver
to actually report received data (and/or pairing info) through its
bulk rx endpoint.
But the funkyness of the bulk-endpoint does not stop there, I mainly
found out about this problem, because with autosuspend enabled
(which usually ensures the suspend at least once condition is met),
the receiver stops reporting received data through its bulk rx endpoint
as soon as autosuspend kicks in. So I initially just disabled
autosuspend, but then the receiver does not work at all.
This was with a fake CSR receiver with a Barrot 8041a02 chip with a
bcdDevice value of 0x8891, a lmp_subver of 0x1012, a hci_rev of 0x0810
and a hci_ver of BLUETOOTH_VER_4_0.
Summarizing this specific fake CSR receiver has the following 2 issues:
1. The bulk rx endpoint will never report any data unless
the device was suspended at least once.
2. They will not wakeup when autosuspended and receiving data on their
bulk rx endpoint from e.g. a keyboard or mouse (IOW remote-wakeup support
is broken for the bulk endpoint).
Add a workaround for 1. which enables runtime-suspend, force-suspends
the hci and then wakes-it up by disabling runtime-suspend again.
Add a workaround for 2. which clears the hci's can_wake flag, this way
the hci will still be autosuspended when it is not open.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2020-12-05 16:02:01 +01:00
|
|
|
|
2021-07-17 01:21:43 +02:00
|
|
|
|
Bluetooth: btusb: Add workaround for remote-wakeup issues with Barrot 8041a02 fake CSR controllers
With the recent btusb change to detect and deal with more fake CSR
controllers, I decided to see if fake CSR controllers with Barrot
8041a02 chips would now work.
After much experimentation I came to the conclusion that it works, if I
have autosuspend enabled initially and then disable it after the device
has suspended at least once. Yes this is very weird, but I've tried many
things, like manually clearing the remote-wakeup feature. Doing a
runtime-resume + runtime suspend is the only way to get the receiver
to actually report received data (and/or pairing info) through its
bulk rx endpoint.
But the funkyness of the bulk-endpoint does not stop there, I mainly
found out about this problem, because with autosuspend enabled
(which usually ensures the suspend at least once condition is met),
the receiver stops reporting received data through its bulk rx endpoint
as soon as autosuspend kicks in. So I initially just disabled
autosuspend, but then the receiver does not work at all.
This was with a fake CSR receiver with a Barrot 8041a02 chip with a
bcdDevice value of 0x8891, a lmp_subver of 0x1012, a hci_rev of 0x0810
and a hci_ver of BLUETOOTH_VER_4_0.
Summarizing this specific fake CSR receiver has the following 2 issues:
1. The bulk rx endpoint will never report any data unless
the device was suspended at least once.
2. They will not wakeup when autosuspended and receiving data on their
bulk rx endpoint from e.g. a keyboard or mouse (IOW remote-wakeup support
is broken for the bulk endpoint).
Add a workaround for 1. which enables runtime-suspend, force-suspends
the hci and then wakes-it up by disabling runtime-suspend again.
Add a workaround for 2. which clears the hci's can_wake flag, this way
the hci will still be autosuspended when it is not open.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2020-12-05 16:02:01 +01:00
|
|
|
|
2021-07-17 01:21:43 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-01-03 03:02:36 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-06-07 10:01:01 +02:00
|
|
|
|
2014-01-03 03:02:36 -08:00
|
|
|
|
|
|
|
|
|
2015-01-26 21:33:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2018-07-23 11:38:51 +08:00
|
|
|
|
2015-01-26 21:33:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
networking: make skb_put & friends return void pointers
It seems like a historic accident that these return unsigned char *,
and in many places that means casts are required, more often than not.
Make these functions (skb_put, __skb_put and pskb_put) return void *
and remove all the casts across the tree, adding a (u8 *) cast only
where the unsigned char pointer was used directly, all done with the
following spatch:
@@
expression SKB, LEN;
typedef u8;
identifier fn = { skb_put, __skb_put };
@@
- *(fn(SKB, LEN))
+ *(u8 *)fn(SKB, LEN)
@@
expression E, SKB, LEN;
identifier fn = { skb_put, __skb_put };
type T;
@@
- E = ((T *)(fn(SKB, LEN)))
+ E = fn(SKB, LEN)
which actually doesn't cover pskb_put since there are only three
users overall.
A handful of stragglers were converted manually, notably a macro in
drivers/isdn/i4l/isdn_bsdcomp.c and, oddly enough, one of the many
instances in net/bluetooth/hci_sock.c. In the former file, I also
had to fix one whitespace problem spatch introduced.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2017-06-16 14:29:21 +02:00
|
|
|
|
2015-01-26 21:33:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
networking: make skb_put & friends return void pointers
It seems like a historic accident that these return unsigned char *,
and in many places that means casts are required, more often than not.
Make these functions (skb_put, __skb_put and pskb_put) return void *
and remove all the casts across the tree, adding a (u8 *) cast only
where the unsigned char pointer was used directly, all done with the
following spatch:
@@
expression SKB, LEN;
typedef u8;
identifier fn = { skb_put, __skb_put };
@@
- *(fn(SKB, LEN))
+ *(u8 *)fn(SKB, LEN)
@@
expression E, SKB, LEN;
identifier fn = { skb_put, __skb_put };
type T;
@@
- E = ((T *)(fn(SKB, LEN)))
+ E = fn(SKB, LEN)
which actually doesn't cover pskb_put since there are only three
users overall.
A handful of stragglers were converted manually, notably a macro in
drivers/isdn/i4l/isdn_bsdcomp.c and, oddly enough, one of the many
instances in net/bluetooth/hci_sock.c. In the former file, I also
had to fix one whitespace problem spatch introduced.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2017-06-16 14:29:21 +02:00
|
|
|
|
2015-01-26 21:33:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
networking: add and use skb_put_u8()
Joe and Bjørn suggested that it'd be nicer to not have the
cast in the fairly common case of doing
*(u8 *)skb_put(skb, 1) = c;
Add skb_put_u8() for this case, and use it across the code,
using the following spatch:
@@
expression SKB, C, S;
typedef u8;
identifier fn = {skb_put};
fresh identifier fn2 = fn ## "_u8";
@@
- *(u8 *)fn(SKB, S) = C;
+ fn2(SKB, C);
Note that due to the "S", the spatch isn't perfect, it should
have checked that S is 1, but there's also places that use a
sizeof expression like sizeof(var) or sizeof(u8) etc. Turns
out that nobody ever did something like
*(u8 *)skb_put(skb, 2) = c;
which would be wrong anyway since the second byte wouldn't be
initialized.
Suggested-by: Joe Perches <joe@perches.com>
Suggested-by: Bjørn Mork <bjorn@mork.no>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2017-06-16 14:29:24 +02:00
|
|
|
|
2015-01-26 21:33:48 -08:00
|
|
|
|
2015-11-05 07:33:56 +01:00
|
|
|
|
2015-01-26 21:33:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-08-04 17:32:15 -07:00
|
|
|
|
|
|
|
|
|
2015-01-26 21:33:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-08-04 17:32:15 -07:00
|
|
|
|
2015-01-26 21:33:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-11-05 07:33:56 +01:00
|
|
|
|
2015-01-26 21:33:48 -08:00
|
|
|
|
2021-08-04 17:32:15 -07:00
|
|
|
|
2015-01-26 21:33:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-07-11 15:37:25 +05:30
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-01-26 21:33:48 -08:00
|
|
|
|
|
|
|
|
|
2025-07-11 15:37:25 +05:30
|
|
|
|
2015-01-26 21:33:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-02-14 19:17:09 +08:00
|
|
|
|
|
|
|
|
|
2015-01-26 21:33:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2019-10-28 17:09:09 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-01-26 21:33:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-10-05 16:43:31 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-04-27 11:27:55 +08:00
|
|
|
|
|
|
|
|
|
2026-07-20 19:47:17 +08:00
|
|
|
|
2026-07-21 03:14:42 -07:00
|
|
|
|
2026-07-20 19:47:17 +08:00
|
|
|
|
2023-04-27 11:27:55 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-07-04 14:01:16 +08:00
|
|
|
|
|
|
|
|
|
2025-11-12 15:53:34 +08:00
|
|
|
|
2024-07-04 14:01:16 +08:00
|
|
|
|
|
|
|
|
|
2025-11-12 15:53:34 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-11-20 08:12:28 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-01-15 19:36:36 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-07-04 14:01:16 +08:00
|
|
|
|
|
|
|
|
|
2025-01-15 19:36:36 -08:00
|
|
|
|
2024-07-04 14:01:16 +08:00
|
|
|
|
|
|
|
|
|
2025-01-15 19:36:37 -08:00
|
|
|
|
2024-07-04 14:01:16 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-10-25 14:07:17 +08:00
|
|
|
|
2024-07-04 14:01:16 +08:00
|
|
|
|
|
|
|
|
|
2024-09-23 16:47:04 +08:00
|
|
|
|
2024-07-04 14:01:16 +08:00
|
|
|
|
2025-11-12 15:53:34 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-07-04 14:01:16 +08:00
|
|
|
|
2024-09-23 16:47:05 +08:00
|
|
|
|
2024-07-04 14:01:16 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-11-12 15:53:34 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-07-04 14:01:16 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-09-23 16:47:04 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-05-15 16:15:19 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-07-04 14:01:11 +08:00
|
|
|
|
2024-05-15 16:15:19 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-07-04 14:01:14 +08:00
|
|
|
|
2024-05-15 16:15:19 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-09-04 16:03:50 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-05-15 16:15:19 -07:00
|
|
|
|
2026-09-04 16:03:50 +08:00
|
|
|
|
2024-05-15 16:15:19 -07:00
|
|
|
|
2024-09-23 16:47:05 +08:00
|
|
|
|
|
|
|
|
|
2024-07-04 14:01:16 +08:00
|
|
|
|
2026-07-25 01:54:43 -07:00
|
|
|
|
2024-05-15 16:15:19 -07:00
|
|
|
|
2025-09-26 18:10:46 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-07-04 14:01:14 +08:00
|
|
|
|
2024-05-15 16:15:19 -07:00
|
|
|
|
2026-09-04 16:03:50 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-05-15 16:15:19 -07:00
|
|
|
|
2024-07-04 14:01:14 +08:00
|
|
|
|
2023-06-29 06:54:56 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-07-04 14:01:16 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Bluetooth: Properly disable remote wakeup for MT7922/MT7925 on Ryzen platform
It is reported that a remote wakeup could cause MT7922/MT7925's btusb
interface completely unresponsive. Resetting the xHCI root hub doesn't
help at all, and recovering from such a state needs a power cycle.
All reports seen to be relevant to Ryzen-based laptops. These NICs are
usually used as OEM components thanks to some sort of reference designs.
Their popularity on other platforms is unclear. While there is still a
chance that the quirk may exist on other platforms, be cautious and only
apply the quirk to direct children of Ryzen platforms's root hubs for
the time being. In most cases the root hub is on the SoC or PCH, which
needs the quirk. Unfortunately, this can't distinguish root hubs on PCIe
add-in cards. Such roughness should be acceptable, as PCIe USB
controller add-in cards are less commonly used nowadays. On the other
hand, applying the quirk doesn't hurt any functionalities either, as the
device can still be used as a wakeup source if desired. Theoretically,
we could retrieve the root hub's PCI vendor ID with some hierarchy
magic, but that's too intrusive...
Meanwhile, though device_set_wakeup_capable(false) is the correct fix
for other NICs with fake remote wakeup capabilities, doing so for
MT7922/MT7925 effectively prevents it from being used as wakeup
sources as per userspace requests. Hence, return -EBUSY on runtime
suspend to prevent the interface from being autosuspended while it's
still opened, which has the same effect as
device_set_wakeup_capable(false), since disabling remote wakeup simply
causes the USB core to gate runtime autosuspend as well due to
needs_remote_wakeup == 1. The interface can be safely autosuspended as
long as remote wakeup is disabled, i.e., after closing the HCI device.
Specifically, the interface may still take the advantage of remote
wakeup in order to wake up the system from sleep if userspace has
enabled it as a wakeup source.
Fixes: e31d761628ad ("Bluetooth: btmtk: Disable remote wakeup for MT7922/MT7925")
Tested-by: Rafael Passos <rafael@rcpassos.me>
Signed-off-by: Rong Zhang <i@rong.moe>
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
2026-09-02 02:19:18 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2019-06-02 08:02:48 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-07-04 14:01:14 +08:00
|
|
|
|
Bluetooth: Properly disable remote wakeup for MT7922/MT7925 on Ryzen platform
It is reported that a remote wakeup could cause MT7922/MT7925's btusb
interface completely unresponsive. Resetting the xHCI root hub doesn't
help at all, and recovering from such a state needs a power cycle.
All reports seen to be relevant to Ryzen-based laptops. These NICs are
usually used as OEM components thanks to some sort of reference designs.
Their popularity on other platforms is unclear. While there is still a
chance that the quirk may exist on other platforms, be cautious and only
apply the quirk to direct children of Ryzen platforms's root hubs for
the time being. In most cases the root hub is on the SoC or PCH, which
needs the quirk. Unfortunately, this can't distinguish root hubs on PCIe
add-in cards. Such roughness should be acceptable, as PCIe USB
controller add-in cards are less commonly used nowadays. On the other
hand, applying the quirk doesn't hurt any functionalities either, as the
device can still be used as a wakeup source if desired. Theoretically,
we could retrieve the root hub's PCI vendor ID with some hierarchy
magic, but that's too intrusive...
Meanwhile, though device_set_wakeup_capable(false) is the correct fix
for other NICs with fake remote wakeup capabilities, doing so for
MT7922/MT7925 effectively prevents it from being used as wakeup
sources as per userspace requests. Hence, return -EBUSY on runtime
suspend to prevent the interface from being autosuspended while it's
still opened, which has the same effect as
device_set_wakeup_capable(false), since disabling remote wakeup simply
causes the USB core to gate runtime autosuspend as well due to
needs_remote_wakeup == 1. The interface can be safely autosuspended as
long as remote wakeup is disabled, i.e., after closing the HCI device.
Specifically, the interface may still take the advantage of remote
wakeup in order to wake up the system from sleep if userspace has
enabled it as a wakeup source.
Fixes: e31d761628ad ("Bluetooth: btmtk: Disable remote wakeup for MT7922/MT7925")
Tested-by: Rafael Passos <rafael@rcpassos.me>
Signed-off-by: Rong Zhang <i@rong.moe>
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
2026-09-02 02:19:18 +08:00
|
|
|
|
2019-06-02 08:02:48 +08:00
|
|
|
|
2024-07-04 14:01:14 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2019-06-02 08:02:48 +08:00
|
|
|
|
2024-07-04 14:01:16 +08:00
|
|
|
|
2024-09-23 16:47:05 +08:00
|
|
|
|
|
|
|
|
|
2024-07-04 14:01:16 +08:00
|
|
|
|
2024-09-23 16:47:05 +08:00
|
|
|
|
2024-07-04 14:01:16 +08:00
|
|
|
|
Bluetooth: Properly disable remote wakeup for MT7922/MT7925 on Ryzen platform
It is reported that a remote wakeup could cause MT7922/MT7925's btusb
interface completely unresponsive. Resetting the xHCI root hub doesn't
help at all, and recovering from such a state needs a power cycle.
All reports seen to be relevant to Ryzen-based laptops. These NICs are
usually used as OEM components thanks to some sort of reference designs.
Their popularity on other platforms is unclear. While there is still a
chance that the quirk may exist on other platforms, be cautious and only
apply the quirk to direct children of Ryzen platforms's root hubs for
the time being. In most cases the root hub is on the SoC or PCH, which
needs the quirk. Unfortunately, this can't distinguish root hubs on PCIe
add-in cards. Such roughness should be acceptable, as PCIe USB
controller add-in cards are less commonly used nowadays. On the other
hand, applying the quirk doesn't hurt any functionalities either, as the
device can still be used as a wakeup source if desired. Theoretically,
we could retrieve the root hub's PCI vendor ID with some hierarchy
magic, but that's too intrusive...
Meanwhile, though device_set_wakeup_capable(false) is the correct fix
for other NICs with fake remote wakeup capabilities, doing so for
MT7922/MT7925 effectively prevents it from being used as wakeup
sources as per userspace requests. Hence, return -EBUSY on runtime
suspend to prevent the interface from being autosuspended while it's
still opened, which has the same effect as
device_set_wakeup_capable(false), since disabling remote wakeup simply
causes the USB core to gate runtime autosuspend as well due to
needs_remote_wakeup == 1. The interface can be safely autosuspended as
long as remote wakeup is disabled, i.e., after closing the HCI device.
Specifically, the interface may still take the advantage of remote
wakeup in order to wake up the system from sleep if userspace has
enabled it as a wakeup source.
Fixes: e31d761628ad ("Bluetooth: btmtk: Disable remote wakeup for MT7922/MT7925")
Tested-by: Rafael Passos <rafael@rcpassos.me>
Signed-off-by: Rong Zhang <i@rong.moe>
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
2026-09-02 02:19:18 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2019-06-02 08:02:48 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-09-23 16:47:02 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-07-04 14:01:16 +08:00
|
|
|
|
2024-09-23 16:47:05 +08:00
|
|
|
|
|
|
|
|
|
2024-07-04 14:01:16 +08:00
|
|
|
|
2024-09-23 16:47:02 +08:00
|
|
|
|
2019-06-02 08:02:48 +08:00
|
|
|
|
|
|
|
|
|
2017-02-01 14:24:10 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2020-12-22 02:31:49 -08:00
|
|
|
|
2017-02-01 14:24:10 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
networking: introduce and use skb_put_data()
A common pattern with skb_put() is to just want to memcpy()
some data into the new space, introduce skb_put_data() for
this.
An spatch similar to the one for skb_put_zero() converts many
of the places using it:
@@
identifier p, p2;
expression len, skb, data;
type t, t2;
@@
(
-p = skb_put(skb, len);
+p = skb_put_data(skb, data, len);
|
-p = (t)skb_put(skb, len);
+p = skb_put_data(skb, data, len);
)
(
p2 = (t2)p;
-memcpy(p2, data, len);
|
-memcpy(p, data, len);
)
@@
type t, t2;
identifier p, p2;
expression skb, data;
@@
t *p;
...
(
-p = skb_put(skb, sizeof(t));
+p = skb_put_data(skb, data, sizeof(t));
|
-p = (t *)skb_put(skb, sizeof(t));
+p = skb_put_data(skb, data, sizeof(t));
)
(
p2 = (t2)p;
-memcpy(p2, data, sizeof(*p));
|
-memcpy(p, data, sizeof(*p));
)
@@
expression skb, len, data;
@@
-memcpy(skb_put(skb, len), data, len);
+skb_put_data(skb, data, len);
(again, manually post-processed to retain some comments)
Reviewed-by: Stephen Hemminger <stephen@networkplumber.org>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2017-06-16 14:29:20 +02:00
|
|
|
|
2017-02-01 14:24:10 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2020-12-22 02:31:49 -08:00
|
|
|
|
2017-02-01 14:24:10 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-06-04 08:37:38 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-02-01 14:24:10 -08:00
|
|
|
|
|
|
|
|
|
2014-07-18 14:47:06 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
|
|
|
|
|
2014-07-18 14:47:06 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-12-12 10:58:05 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
2014-12-12 10:58:05 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2020-09-29 12:23:51 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-06-25 22:19:47 -07:00
|
|
|
|
2020-09-29 12:23:51 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-06-25 22:19:47 -07:00
|
|
|
|
2020-09-29 12:23:51 +08:00
|
|
|
|
2026-06-25 22:19:47 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2020-09-29 12:23:51 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-06-25 22:19:50 -07:00
|
|
|
|
|
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
|
|
|
|
|
2026-06-25 22:19:50 -07:00
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-06-25 22:19:50 -07:00
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-06-25 22:19:50 -07:00
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-03-25 16:11:49 +08:00
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
|
|
|
|
|
2024-03-25 16:11:49 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
|
|
|
|
|
2025-04-21 21:00:37 +08:00
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
|
|
|
|
|
2025-04-21 21:00:37 +08:00
|
|
|
|
2025-05-08 22:15:20 +08:00
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-06-25 22:19:50 -07:00
|
|
|
|
|
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-05-08 22:15:20 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
2025-05-08 22:15:20 +08:00
|
|
|
|
|
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-06-25 22:19:50 -07:00
|
|
|
|
|
|
|
|
|
2025-05-08 22:15:20 +08:00
|
|
|
|
|
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-05-08 22:15:20 +08:00
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
|
|
|
|
|
2026-06-25 22:19:50 -07:00
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-06-25 22:19:50 -07:00
|
|
|
|
|
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-06-25 22:19:50 -07:00
|
|
|
|
|
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-06-25 22:19:50 -07:00
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-06-25 22:19:50 -07:00
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-06-25 22:19:50 -07:00
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
2026-06-25 22:19:50 -07:00
|
|
|
|
|
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-04-21 21:00:37 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-05-08 22:15:20 +08:00
|
|
|
|
|
|
|
|
|
2025-04-21 21:00:37 +08:00
|
|
|
|
2025-05-08 22:15:20 +08:00
|
|
|
|
2025-04-21 21:00:37 +08:00
|
|
|
|
|
|
|
|
|
2025-05-08 22:15:20 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-04-21 21:00:37 +08:00
|
|
|
|
2025-05-08 22:15:20 +08:00
|
|
|
|
2026-07-21 03:14:41 -07:00
|
|
|
|
2025-05-08 22:15:20 +08:00
|
|
|
|
2025-04-21 21:00:37 +08:00
|
|
|
|
2025-05-08 22:15:20 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-04-21 21:00:37 +08:00
|
|
|
|
2025-05-08 22:15:20 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-04-21 21:00:37 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-05-08 22:15:20 +08:00
|
|
|
|
|
|
|
|
|
2025-04-21 21:00:37 +08:00
|
|
|
|
2025-05-08 22:15:20 +08:00
|
|
|
|
2025-04-21 21:00:37 +08:00
|
|
|
|
|
|
|
|
|
2025-05-08 22:15:20 +08:00
|
|
|
|
2026-07-21 03:14:41 -07:00
|
|
|
|
2025-05-08 22:15:20 +08:00
|
|
|
|
2025-04-21 21:00:37 +08:00
|
|
|
|
2025-05-08 22:15:20 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-04-21 21:00:37 +08:00
|
|
|
|
2025-05-08 22:15:20 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-04-21 21:00:37 +08:00
|
|
|
|
|
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
|
|
|
|
|
2025-04-21 21:00:37 +08:00
|
|
|
|
|
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-04-21 21:00:37 +08:00
|
|
|
|
|
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2020-12-03 12:57:14 +08:00
|
|
|
|
2022-02-14 18:43:39 +08:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
2021-10-29 11:21:21 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-11-16 12:48:49 +08:00
|
|
|
|
|
|
|
|
|
2020-12-03 12:57:14 +08:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2020-09-29 12:23:51 +08:00
|
|
|
|
|
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-03-10 23:34:58 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
2025-07-15 20:40:14 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
2020-09-29 12:23:51 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-10-29 11:21:21 +08:00
|
|
|
|
2022-04-25 23:01:29 +08:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
2025-07-15 20:40:14 +08:00
|
|
|
|
|
|
|
|
|
2025-11-09 17:24:37 +08:00
|
|
|
|
2025-07-15 20:40:14 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-07-15 20:40:13 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-07-15 20:40:14 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Bluetooth: btusb: Apply QCA Rome patches for some ATH3012 models
In commit f44cb4b19ed4 ("Bluetooth: btusb: Fix quirk for Atheros
1525/QCA6174") we tried to address the non-working Atheros BT devices
by changing the quirk from BTUSB_ATH3012 to BTUSB_QCA_ROME. This made
such devices working while it turned out to break other existing chips
with the very same USB ID, hence it was reverted afterwards.
This is another attempt to tackle the issue. The essential point to
use BTUSB_QCA_ROME is to apply the btusb_setup_qca() and do RAM-
patching. And the previous attempt failed because btusb_setup_qca()
returns -ENODEV if the ROM version doesn't match with the expected
ones. For some devices that have already the "correct" ROM versions,
we may just skip the setup procedure and continue the rest.
So, the first fix we'll need is to add a check of the ROM version in
the function to skip the setup if the ROM version looks already sane,
so that it can be applied for all ath devices.
However, the world is a bit more complex than that simple solution.
Since BTUSB_ATH3012 quirk checks the bcdDevice and bails out when it's
0x0001 at the beginning of probing, so the device probe always aborts
here.
In this patch, we add another check of ROM version again, and if the
device needs patching, the probe continues. For that, a slight
refactoring of btusb_qca_send_vendor_req() was required so that the
probe function can pass usb_device pointer directly before allocating
hci_dev stuff.
Fixes: commit f44cb4b19ed4 ("Bluetooth: btusb: Fix quirk for Atheros 1525/QCA6174")
Bugzilla: http://bugzilla.opensuse.org/show_bug.cgi?id=1082504
Tested-by: Ivan Levshin <ivan.levshin@microfocus.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2018-05-21 22:34:52 +02:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
2026-07-27 17:57:34 +02:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-07-27 17:57:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Bluetooth: btusb: Apply QCA Rome patches for some ATH3012 models
In commit f44cb4b19ed4 ("Bluetooth: btusb: Fix quirk for Atheros
1525/QCA6174") we tried to address the non-working Atheros BT devices
by changing the quirk from BTUSB_ATH3012 to BTUSB_QCA_ROME. This made
such devices working while it turned out to break other existing chips
with the very same USB ID, hence it was reverted afterwards.
This is another attempt to tackle the issue. The essential point to
use BTUSB_QCA_ROME is to apply the btusb_setup_qca() and do RAM-
patching. And the previous attempt failed because btusb_setup_qca()
returns -ENODEV if the ROM version doesn't match with the expected
ones. For some devices that have already the "correct" ROM versions,
we may just skip the setup procedure and continue the rest.
So, the first fix we'll need is to add a check of the ROM version in
the function to skip the setup if the ROM version looks already sane,
so that it can be applied for all ath devices.
However, the world is a bit more complex than that simple solution.
Since BTUSB_ATH3012 quirk checks the bcdDevice and bails out when it's
0x0001 at the beginning of probing, so the device probe always aborts
here.
In this patch, we add another check of ROM version again, and if the
device needs patching, the probe continues. For that, a slight
refactoring of btusb_qca_send_vendor_req() was required so that the
probe function can pass usb_device pointer directly before allocating
hci_dev stuff.
Fixes: commit f44cb4b19ed4 ("Bluetooth: btusb: Fix quirk for Atheros 1525/QCA6174")
Bugzilla: http://bugzilla.opensuse.org/show_bug.cgi?id=1082504
Tested-by: Ivan Levshin <ivan.levshin@microfocus.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2018-05-21 22:34:52 +02:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-06-01 17:57:10 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
|
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-07-15 20:40:14 +08:00
|
|
|
|
2020-09-29 12:23:51 +08:00
|
|
|
|
|
|
|
|
|
2025-07-15 20:40:14 +08:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
2015-03-10 23:34:58 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-07-15 20:40:14 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
|
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
2015-03-10 23:34:58 +00:00
|
|
|
|
2020-09-29 12:23:51 +08:00
|
|
|
|
2015-03-10 23:34:58 +00:00
|
|
|
|
|
|
|
|
|
2020-09-29 12:23:51 +08:00
|
|
|
|
|
|
|
|
|
2022-12-05 09:58:43 -08:00
|
|
|
|
2020-09-29 12:23:51 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-03-10 23:34:58 +00:00
|
|
|
|
2026-05-21 13:25:47 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-10-29 11:21:21 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-07-15 20:40:14 +08:00
|
|
|
|
2025-07-15 20:40:13 +08:00
|
|
|
|
|
|
|
|
|
2021-10-29 11:21:21 +08:00
|
|
|
|
2025-07-15 20:40:14 +08:00
|
|
|
|
2025-07-15 20:40:13 +08:00
|
|
|
|
2021-10-29 11:21:21 +08:00
|
|
|
|
2025-07-15 20:40:13 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-10-29 11:21:21 +08:00
|
|
|
|
|
|
|
|
|
2025-07-15 20:40:14 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-07-15 20:40:13 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-10-29 11:21:21 +08:00
|
|
|
|
|
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-07-15 20:40:14 +08:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
2021-10-29 11:21:21 +08:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
|
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Bluetooth: btusb: Apply QCA Rome patches for some ATH3012 models
In commit f44cb4b19ed4 ("Bluetooth: btusb: Fix quirk for Atheros
1525/QCA6174") we tried to address the non-working Atheros BT devices
by changing the quirk from BTUSB_ATH3012 to BTUSB_QCA_ROME. This made
such devices working while it turned out to break other existing chips
with the very same USB ID, hence it was reverted afterwards.
This is another attempt to tackle the issue. The essential point to
use BTUSB_QCA_ROME is to apply the btusb_setup_qca() and do RAM-
patching. And the previous attempt failed because btusb_setup_qca()
returns -ENODEV if the ROM version doesn't match with the expected
ones. For some devices that have already the "correct" ROM versions,
we may just skip the setup procedure and continue the rest.
So, the first fix we'll need is to add a check of the ROM version in
the function to skip the setup if the ROM version looks already sane,
so that it can be applied for all ath devices.
However, the world is a bit more complex than that simple solution.
Since BTUSB_ATH3012 quirk checks the bcdDevice and bails out when it's
0x0001 at the beginning of probing, so the device probe always aborts
here.
In this patch, we add another check of ROM version again, and if the
device needs patching, the probe continues. For that, a slight
refactoring of btusb_qca_send_vendor_req() was required so that the
probe function can pass usb_device pointer directly before allocating
hci_dev stuff.
Fixes: commit f44cb4b19ed4 ("Bluetooth: btusb: Fix quirk for Atheros 1525/QCA6174")
Bugzilla: http://bugzilla.opensuse.org/show_bug.cgi?id=1082504
Tested-by: Ivan Levshin <ivan.levshin@microfocus.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2018-05-21 22:34:52 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-07-27 17:57:34 +02:00
|
|
|
|
Bluetooth: btusb: Apply QCA Rome patches for some ATH3012 models
In commit f44cb4b19ed4 ("Bluetooth: btusb: Fix quirk for Atheros
1525/QCA6174") we tried to address the non-working Atheros BT devices
by changing the quirk from BTUSB_ATH3012 to BTUSB_QCA_ROME. This made
such devices working while it turned out to break other existing chips
with the very same USB ID, hence it was reverted afterwards.
This is another attempt to tackle the issue. The essential point to
use BTUSB_QCA_ROME is to apply the btusb_setup_qca() and do RAM-
patching. And the previous attempt failed because btusb_setup_qca()
returns -ENODEV if the ROM version doesn't match with the expected
ones. For some devices that have already the "correct" ROM versions,
we may just skip the setup procedure and continue the rest.
So, the first fix we'll need is to add a check of the ROM version in
the function to skip the setup if the ROM version looks already sane,
so that it can be applied for all ath devices.
However, the world is a bit more complex than that simple solution.
Since BTUSB_ATH3012 quirk checks the bcdDevice and bails out when it's
0x0001 at the beginning of probing, so the device probe always aborts
here.
In this patch, we add another check of ROM version again, and if the
device needs patching, the probe continues. For that, a slight
refactoring of btusb_qca_send_vendor_req() was required so that the
probe function can pass usb_device pointer directly before allocating
hci_dev stuff.
Fixes: commit f44cb4b19ed4 ("Bluetooth: btusb: Fix quirk for Atheros 1525/QCA6174")
Bugzilla: http://bugzilla.opensuse.org/show_bug.cgi?id=1082504
Tested-by: Ivan Levshin <ivan.levshin@microfocus.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2018-05-21 22:34:52 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
Bluetooth: btusb: Apply QCA Rome patches for some ATH3012 models
In commit f44cb4b19ed4 ("Bluetooth: btusb: Fix quirk for Atheros
1525/QCA6174") we tried to address the non-working Atheros BT devices
by changing the quirk from BTUSB_ATH3012 to BTUSB_QCA_ROME. This made
such devices working while it turned out to break other existing chips
with the very same USB ID, hence it was reverted afterwards.
This is another attempt to tackle the issue. The essential point to
use BTUSB_QCA_ROME is to apply the btusb_setup_qca() and do RAM-
patching. And the previous attempt failed because btusb_setup_qca()
returns -ENODEV if the ROM version doesn't match with the expected
ones. For some devices that have already the "correct" ROM versions,
we may just skip the setup procedure and continue the rest.
So, the first fix we'll need is to add a check of the ROM version in
the function to skip the setup if the ROM version looks already sane,
so that it can be applied for all ath devices.
However, the world is a bit more complex than that simple solution.
Since BTUSB_ATH3012 quirk checks the bcdDevice and bails out when it's
0x0001 at the beginning of probing, so the device probe always aborts
here.
In this patch, we add another check of ROM version again, and if the
device needs patching, the probe continues. For that, a slight
refactoring of btusb_qca_send_vendor_req() was required so that the
probe function can pass usb_device pointer directly before allocating
hci_dev stuff.
Fixes: commit f44cb4b19ed4 ("Bluetooth: btusb: Fix quirk for Atheros 1525/QCA6174")
Bugzilla: http://bugzilla.opensuse.org/show_bug.cgi?id=1082504
Tested-by: Ivan Levshin <ivan.levshin@microfocus.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2018-05-21 22:34:52 +02:00
|
|
|
|
|
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
2015-03-10 23:34:58 +00:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Bluetooth: btusb: Apply QCA Rome patches for some ATH3012 models
In commit f44cb4b19ed4 ("Bluetooth: btusb: Fix quirk for Atheros
1525/QCA6174") we tried to address the non-working Atheros BT devices
by changing the quirk from BTUSB_ATH3012 to BTUSB_QCA_ROME. This made
such devices working while it turned out to break other existing chips
with the very same USB ID, hence it was reverted afterwards.
This is another attempt to tackle the issue. The essential point to
use BTUSB_QCA_ROME is to apply the btusb_setup_qca() and do RAM-
patching. And the previous attempt failed because btusb_setup_qca()
returns -ENODEV if the ROM version doesn't match with the expected
ones. For some devices that have already the "correct" ROM versions,
we may just skip the setup procedure and continue the rest.
So, the first fix we'll need is to add a check of the ROM version in
the function to skip the setup if the ROM version looks already sane,
so that it can be applied for all ath devices.
However, the world is a bit more complex than that simple solution.
Since BTUSB_ATH3012 quirk checks the bcdDevice and bails out when it's
0x0001 at the beginning of probing, so the device probe always aborts
here.
In this patch, we add another check of ROM version again, and if the
device needs patching, the probe continues. For that, a slight
refactoring of btusb_qca_send_vendor_req() was required so that the
probe function can pass usb_device pointer directly before allocating
hci_dev stuff.
Fixes: commit f44cb4b19ed4 ("Bluetooth: btusb: Fix quirk for Atheros 1525/QCA6174")
Bugzilla: http://bugzilla.opensuse.org/show_bug.cgi?id=1082504
Tested-by: Ivan Levshin <ivan.levshin@microfocus.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2018-05-21 22:34:52 +02:00
|
|
|
|
2015-04-16 23:15:50 +02:00
|
|
|
|
2026-07-27 17:57:34 +02:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
2015-03-10 23:34:58 +00:00
|
|
|
|
Bluetooth: btusb: Apply QCA Rome patches for some ATH3012 models
In commit f44cb4b19ed4 ("Bluetooth: btusb: Fix quirk for Atheros
1525/QCA6174") we tried to address the non-working Atheros BT devices
by changing the quirk from BTUSB_ATH3012 to BTUSB_QCA_ROME. This made
such devices working while it turned out to break other existing chips
with the very same USB ID, hence it was reverted afterwards.
This is another attempt to tackle the issue. The essential point to
use BTUSB_QCA_ROME is to apply the btusb_setup_qca() and do RAM-
patching. And the previous attempt failed because btusb_setup_qca()
returns -ENODEV if the ROM version doesn't match with the expected
ones. For some devices that have already the "correct" ROM versions,
we may just skip the setup procedure and continue the rest.
So, the first fix we'll need is to add a check of the ROM version in
the function to skip the setup if the ROM version looks already sane,
so that it can be applied for all ath devices.
However, the world is a bit more complex than that simple solution.
Since BTUSB_ATH3012 quirk checks the bcdDevice and bails out when it's
0x0001 at the beginning of probing, so the device probe always aborts
here.
In this patch, we add another check of ROM version again, and if the
device needs patching, the probe continues. For that, a slight
refactoring of btusb_qca_send_vendor_req() was required so that the
probe function can pass usb_device pointer directly before allocating
hci_dev stuff.
Fixes: commit f44cb4b19ed4 ("Bluetooth: btusb: Fix quirk for Atheros 1525/QCA6174")
Bugzilla: http://bugzilla.opensuse.org/show_bug.cgi?id=1082504
Tested-by: Ivan Levshin <ivan.levshin@microfocus.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2018-05-21 22:34:52 +02:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
2015-03-10 23:34:58 +00:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Bluetooth: btusb: Some Qualcomm Bluetooth adapters stop working
This issue starts from linux-5.10-rc1, I reproduced this issue on my
Dell Inspiron 7447 with BT adapter 0cf3:e005, the kernel will print
out: "Bluetooth: hci0: don't support firmware rome 0x31010000", and
someone else also reported the similar issue to bugzilla #211571.
I found this is a regression introduced by 'commit b40f58b97386
("Bluetooth: btusb: Add Qualcomm Bluetooth SoC WCN6855 support"), the
patch assumed that if high ROM version is not zero, it is an adapter
on WCN6855, but many old adapters don't need to load rampatch or nvm,
and they have non-zero high ROM version.
To fix it, let the driver match the rom_version in the
qca_devices_table first, if there is no entry matched, check the
high ROM version, if it is not zero, we assume this adapter is ready
to work and no need to load rampatch and nvm like previously.
BugLink: https://bugzilla.kernel.org/show_bug.cgi?id=211571
Fixes: b40f58b97386 ("Bluetooth: btusb: Add Qualcomm Bluetooth SoC WCN6855 support")
Signed-off-by: Hui Wang <hui.wang@canonical.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2021-02-08 13:02:37 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Bluetooth: btusb: Apply QCA Rome patches for some ATH3012 models
In commit f44cb4b19ed4 ("Bluetooth: btusb: Fix quirk for Atheros
1525/QCA6174") we tried to address the non-working Atheros BT devices
by changing the quirk from BTUSB_ATH3012 to BTUSB_QCA_ROME. This made
such devices working while it turned out to break other existing chips
with the very same USB ID, hence it was reverted afterwards.
This is another attempt to tackle the issue. The essential point to
use BTUSB_QCA_ROME is to apply the btusb_setup_qca() and do RAM-
patching. And the previous attempt failed because btusb_setup_qca()
returns -ENODEV if the ROM version doesn't match with the expected
ones. For some devices that have already the "correct" ROM versions,
we may just skip the setup procedure and continue the rest.
So, the first fix we'll need is to add a check of the ROM version in
the function to skip the setup if the ROM version looks already sane,
so that it can be applied for all ath devices.
However, the world is a bit more complex than that simple solution.
Since BTUSB_ATH3012 quirk checks the bcdDevice and bails out when it's
0x0001 at the beginning of probing, so the device probe always aborts
here.
In this patch, we add another check of ROM version again, and if the
device needs patching, the probe continues. For that, a slight
refactoring of btusb_qca_send_vendor_req() was required so that the
probe function can pass usb_device pointer directly before allocating
hci_dev stuff.
Fixes: commit f44cb4b19ed4 ("Bluetooth: btusb: Fix quirk for Atheros 1525/QCA6174")
Bugzilla: http://bugzilla.opensuse.org/show_bug.cgi?id=1082504
Tested-by: Ivan Levshin <ivan.levshin@microfocus.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2018-05-21 22:34:52 +02:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
2026-07-27 17:57:34 +02:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2020-12-03 12:57:14 +08:00
|
|
|
|
|
|
|
|
|
2026-07-27 17:57:34 +02:00
|
|
|
|
2020-12-03 12:57:14 +08:00
|
|
|
|
|
|
|
|
|
2026-06-25 22:19:49 -07:00
|
|
|
|
2026-06-25 22:19:50 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-06-25 22:19:49 -07:00
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-02-14 18:43:39 +08:00
|
|
|
|
2022-04-25 23:01:29 +08:00
|
|
|
|
2022-02-14 18:43:39 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-04-25 23:01:29 +08:00
|
|
|
|
2022-02-14 18:43:39 +08:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
2022-04-01 16:38:25 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-07-14 22:27:45 +02:00
|
|
|
|
2022-04-01 16:38:25 -07:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-10-08 20:23:08 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-03-30 11:41:33 +02:00
|
|
|
|
2015-10-08 20:23:08 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-03-30 11:41:33 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-10-30 10:42:59 +01:00
|
|
|
|
2015-10-08 20:23:08 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
networking: add and use skb_put_u8()
Joe and Bjørn suggested that it'd be nicer to not have the
cast in the fairly common case of doing
*(u8 *)skb_put(skb, 1) = c;
Add skb_put_u8() for this case, and use it across the code,
using the following spatch:
@@
expression SKB, C, S;
typedef u8;
identifier fn = {skb_put};
fresh identifier fn2 = fn ## "_u8";
@@
- *(u8 *)fn(SKB, S) = C;
+ fn2(SKB, C);
Note that due to the "S", the spatch isn't perfect, it should
have checked that S is 1, but there's also places that use a
sizeof expression like sizeof(var) or sizeof(u8) etc. Turns
out that nobody ever did something like
*(u8 *)skb_put(skb, 2) = c;
which would be wrong anyway since the second byte wouldn't be
initialized.
Suggested-by: Joe Perches <joe@perches.com>
Suggested-by: Bjørn Mork <bjorn@mork.no>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2017-06-16 14:29:24 +02:00
|
|
|
|
|
|
|
|
|
2015-10-08 20:23:08 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-02-01 14:24:09 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-02-24 14:24:29 +08:00
|
|
|
|
2017-02-01 14:24:09 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2019-02-22 14:53:43 -08:00
|
|
|
|
|
|
|
|
|
2017-02-01 14:24:09 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2019-04-09 11:49:17 -07:00
|
|
|
|
2026-06-04 08:37:39 +02:00
|
|
|
|
2017-02-01 14:24:09 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-06-04 08:37:39 +02:00
|
|
|
|
2017-02-01 14:24:09 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-06-04 08:37:39 +02:00
|
|
|
|
2017-02-01 14:24:09 -08:00
|
|
|
|
2026-06-04 08:37:39 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-02-01 14:24:09 -08:00
|
|
|
|
2026-06-04 08:37:38 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-02-01 14:24:09 -08:00
|
|
|
|
|
|
|
|
|
2018-04-27 11:26:43 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-10-01 13:22:31 -07:00
|
|
|
|
2020-05-12 19:19:27 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-10-01 13:22:31 -07:00
|
|
|
|
2020-05-12 19:19:27 -07:00
|
|
|
|
|
|
|
|
|
2020-12-18 18:12:11 +08:00
|
|
|
|
|
|
|
|
|
2026-06-25 22:19:53 -07:00
|
|
|
|
2020-12-18 18:12:11 +08:00
|
|
|
|
2026-06-25 22:19:53 -07:00
|
|
|
|
|
|
|
|
|
2020-12-18 18:12:11 +08:00
|
|
|
|
|
|
|
|
|
2026-06-25 22:19:53 -07:00
|
|
|
|
2020-12-18 18:12:11 +08:00
|
|
|
|
|
|
|
|
|
2021-12-03 14:38:13 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-02-21 22:32:59 +01:00
|
|
|
|
2021-12-03 14:38:13 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-04-16 09:53:36 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-04-16 09:53:35 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-04-16 09:53:36 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-04-16 09:53:35 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-04-16 09:53:36 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-07-05 18:52:46 +08:00
|
|
|
|
|
|
|
|
|
2025-04-16 09:53:36 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-04-16 09:53:35 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-04-16 09:53:36 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-04-16 09:53:35 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2014-09-16 04:44:50 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2019-01-24 15:28:14 -08:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
2015-10-20 00:53:33 +02:00
|
|
|
|
2026-06-25 22:19:56 -07:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-02-07 12:57:41 +01:00
|
|
|
|
2023-07-13 12:25:14 +02:00
|
|
|
|
2023-02-07 12:57:41 +01:00
|
|
|
|
|
|
|
|
|
2015-10-20 00:53:33 +02:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-09-16 04:44:50 +02:00
|
|
|
|
2023-08-22 12:20:24 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-06-25 22:19:57 -07:00
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
|
|
|
|
|
2011-07-01 14:02:36 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-07-22 13:47:07 +12:00
|
|
|
|
|
|
|
|
|
Bluetooth: btusb: Apply QCA Rome patches for some ATH3012 models
In commit f44cb4b19ed4 ("Bluetooth: btusb: Fix quirk for Atheros
1525/QCA6174") we tried to address the non-working Atheros BT devices
by changing the quirk from BTUSB_ATH3012 to BTUSB_QCA_ROME. This made
such devices working while it turned out to break other existing chips
with the very same USB ID, hence it was reverted afterwards.
This is another attempt to tackle the issue. The essential point to
use BTUSB_QCA_ROME is to apply the btusb_setup_qca() and do RAM-
patching. And the previous attempt failed because btusb_setup_qca()
returns -ENODEV if the ROM version doesn't match with the expected
ones. For some devices that have already the "correct" ROM versions,
we may just skip the setup procedure and continue the rest.
So, the first fix we'll need is to add a check of the ROM version in
the function to skip the setup if the ROM version looks already sane,
so that it can be applied for all ath devices.
However, the world is a bit more complex than that simple solution.
Since BTUSB_ATH3012 quirk checks the bcdDevice and bails out when it's
0x0001 at the beginning of probing, so the device probe always aborts
here.
In this patch, we add another check of ROM version again, and if the
device needs patching, the probe continues. For that, a slight
refactoring of btusb_qca_send_vendor_req() was required so that the
probe function can pass usb_device pointer directly before allocating
hci_dev stuff.
Fixes: commit f44cb4b19ed4 ("Bluetooth: btusb: Fix quirk for Atheros 1525/QCA6174")
Bugzilla: http://bugzilla.opensuse.org/show_bug.cgi?id=1082504
Tested-by: Ivan Levshin <ivan.levshin@microfocus.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2018-05-21 22:34:52 +02:00
|
|
|
|
|
|
|
|
|
2011-07-01 14:02:36 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-02-21 16:37:42 -08:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-06-25 22:19:48 -07:00
|
|
|
|
2026-03-30 11:41:33 +02:00
|
|
|
|
|
|
|
|
|
2026-06-04 08:37:40 +02:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2015-01-28 20:27:34 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:26 +01:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2008-09-23 00:16:36 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
2021-12-03 14:38:13 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
|
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
2015-10-08 20:23:08 +02:00
|
|
|
|
2019-06-02 08:02:48 +08:00
|
|
|
|
2014-09-16 08:00:29 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2021-08-04 17:32:15 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-08-04 17:32:11 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-08-04 17:32:15 -07:00
|
|
|
|
2023-07-20 15:16:32 -07:00
|
|
|
|
2015-01-26 21:33:48 -08:00
|
|
|
|
2022-10-05 16:43:30 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-04-27 11:27:55 +08:00
|
|
|
|
|
|
|
|
|
2023-06-20 16:27:50 +08:00
|
|
|
|
|
|
|
|
|
2024-07-04 14:01:11 +08:00
|
|
|
|
2026-06-25 22:19:50 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-01-26 21:33:48 -08:00
|
|
|
|
2014-11-03 05:16:07 +01:00
|
|
|
|
2021-08-04 17:03:15 +08:00
|
|
|
|
|
|
|
|
|
2021-08-04 17:32:11 -07:00
|
|
|
|
2025-12-10 11:02:28 -05:00
|
|
|
|
2026-06-04 08:37:40 +02:00
|
|
|
|
|
|
|
|
|
2025-12-10 11:02:28 -05:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2010-02-08 15:27:07 +01:00
|
|
|
|
2012-02-09 21:58:32 +01:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2019-01-24 15:28:14 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-06-04 08:37:40 +02:00
|
|
|
|
2019-01-24 15:28:14 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-04-16 09:53:35 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2013-04-10 08:11:35 -07:00
|
|
|
|
2017-02-01 14:24:09 -08:00
|
|
|
|
|
|
|
|
|
2026-06-04 08:37:40 +02:00
|
|
|
|
2017-02-01 14:24:10 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-06-04 08:37:38 +02:00
|
|
|
|
2017-02-01 14:24:10 -08:00
|
|
|
|
2026-06-04 08:37:38 +02:00
|
|
|
|
2016-09-01 17:22:37 +02:00
|
|
|
|
2025-07-14 22:27:45 +02:00
|
|
|
|
2016-09-01 17:22:37 +02:00
|
|
|
|
2015-10-17 14:39:27 +02:00
|
|
|
|
2025-07-14 22:27:45 +02:00
|
|
|
|
2015-10-17 14:39:27 +02:00
|
|
|
|
2013-04-10 08:11:35 -07:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2019-09-27 08:48:58 +02:00
|
|
|
|
|
|
|
|
|
2015-10-20 02:30:48 +02:00
|
|
|
|
2015-04-05 22:52:14 -07:00
|
|
|
|
2015-10-08 20:23:08 +02:00
|
|
|
|
2015-04-05 22:52:11 -07:00
|
|
|
|
2015-10-08 20:23:08 +02:00
|
|
|
|
|
|
|
|
|
2015-10-20 00:53:33 +02:00
|
|
|
|
2014-07-02 00:53:48 +02:00
|
|
|
|
2014-05-08 15:50:01 -07:00
|
|
|
|
2019-09-27 08:48:58 +02:00
|
|
|
|
|
|
|
|
|
2015-10-20 02:30:48 +02:00
|
|
|
|
2015-04-05 22:52:14 -07:00
|
|
|
|
2015-10-08 20:23:08 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-10-20 00:53:33 +02:00
|
|
|
|
2015-10-08 20:23:08 +02:00
|
|
|
|
2015-03-22 15:52:38 +01:00
|
|
|
|
2021-08-04 17:32:10 -07:00
|
|
|
|
|
|
|
|
|
2023-03-30 09:58:26 -07:00
|
|
|
|
2021-08-04 17:32:10 -07:00
|
|
|
|
2026-06-04 08:37:37 +02:00
|
|
|
|
2021-08-04 17:32:10 -07:00
|
|
|
|
|
|
|
|
|
2021-08-04 17:32:15 -07:00
|
|
|
|
2025-01-08 20:24:43 +08:00
|
|
|
|
2021-08-04 17:32:10 -07:00
|
|
|
|
2022-01-20 11:44:18 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-08-04 17:32:12 -07:00
|
|
|
|
|
|
|
|
|
2022-01-06 16:34:54 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-07-02 11:25:25 +02:00
|
|
|
|
2013-04-19 09:57:43 -07:00
|
|
|
|
2014-07-18 14:47:06 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2019-09-27 08:48:58 +02:00
|
|
|
|
|
|
|
|
|
2019-06-02 08:02:48 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-01-08 20:24:43 +08:00
|
|
|
|
2021-10-19 05:30:12 +08:00
|
|
|
|
2024-07-04 14:01:16 +08:00
|
|
|
|
2025-07-14 22:27:45 +02:00
|
|
|
|
|
|
|
|
|
2024-07-04 14:01:15 +08:00
|
|
|
|
2026-04-16 19:16:07 +08:00
|
|
|
|
2024-07-04 14:01:16 +08:00
|
|
|
|
|
|
|
|
|
2024-09-23 16:47:04 +08:00
|
|
|
|
2019-06-02 08:02:48 +08:00
|
|
|
|
|
|
|
|
|
2015-01-02 23:35:20 -08:00
|
|
|
|
2025-07-14 22:27:45 +02:00
|
|
|
|
|
|
|
|
|
2015-01-02 23:35:20 -08:00
|
|
|
|
2014-12-26 04:42:33 +01:00
|
|
|
|
2015-10-21 01:31:45 +02:00
|
|
|
|
|
|
|
|
|
2025-07-14 22:27:45 +02:00
|
|
|
|
2015-10-21 01:31:45 +02:00
|
|
|
|
2014-07-06 13:29:58 +02:00
|
|
|
|
2015-01-29 10:38:34 -08:00
|
|
|
|
Bluetooth: btusb: Apply QCA Rome patches for some ATH3012 models
In commit f44cb4b19ed4 ("Bluetooth: btusb: Fix quirk for Atheros
1525/QCA6174") we tried to address the non-working Atheros BT devices
by changing the quirk from BTUSB_ATH3012 to BTUSB_QCA_ROME. This made
such devices working while it turned out to break other existing chips
with the very same USB ID, hence it was reverted afterwards.
This is another attempt to tackle the issue. The essential point to
use BTUSB_QCA_ROME is to apply the btusb_setup_qca() and do RAM-
patching. And the previous attempt failed because btusb_setup_qca()
returns -ENODEV if the ROM version doesn't match with the expected
ones. For some devices that have already the "correct" ROM versions,
we may just skip the setup procedure and continue the rest.
So, the first fix we'll need is to add a check of the ROM version in
the function to skip the setup if the ROM version looks already sane,
so that it can be applied for all ath devices.
However, the world is a bit more complex than that simple solution.
Since BTUSB_ATH3012 quirk checks the bcdDevice and bails out when it's
0x0001 at the beginning of probing, so the device probe always aborts
here.
In this patch, we add another check of ROM version again, and if the
device needs patching, the probe continues. For that, a slight
refactoring of btusb_qca_send_vendor_req() was required so that the
probe function can pass usb_device pointer directly before allocating
hci_dev stuff.
Fixes: commit f44cb4b19ed4 ("Bluetooth: btusb: Fix quirk for Atheros 1525/QCA6174")
Bugzilla: http://bugzilla.opensuse.org/show_bug.cgi?id=1082504
Tested-by: Ivan Levshin <ivan.levshin@microfocus.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2018-05-21 22:34:52 +02:00
|
|
|
|
2014-12-12 10:58:05 -08:00
|
|
|
|
2025-07-14 22:27:45 +02:00
|
|
|
|
|
|
|
|
|
2015-01-29 10:38:34 -08:00
|
|
|
|
2014-12-12 10:58:05 -08:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
2023-08-07 14:46:26 +08:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
2025-01-08 20:24:43 +08:00
|
|
|
|
2025-07-14 22:27:45 +02:00
|
|
|
|
2018-04-27 11:26:43 +02:00
|
|
|
|
2015-02-15 23:07:33 +00:00
|
|
|
|
|
|
|
|
|
2020-09-29 12:23:51 +08:00
|
|
|
|
2026-06-25 22:19:50 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-04-19 11:38:05 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2020-09-29 12:23:51 +08:00
|
|
|
|
2025-10-07 11:33:15 -04:00
|
|
|
|
2020-12-18 18:12:11 +08:00
|
|
|
|
2020-09-29 12:23:51 +08:00
|
|
|
|
2025-01-08 20:24:43 +08:00
|
|
|
|
2025-07-14 22:27:45 +02:00
|
|
|
|
2021-07-29 10:10:59 -07:00
|
|
|
|
2020-09-29 12:23:51 +08:00
|
|
|
|
|
|
|
|
|
2020-06-30 21:09:40 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2019-09-18 21:59:02 +02:00
|
|
|
|
|
|
|
|
|
2023-04-27 11:27:55 +08:00
|
|
|
|
2022-10-05 16:43:31 +08:00
|
|
|
|
2019-06-25 16:30:51 +08:00
|
|
|
|
2025-01-08 20:24:43 +08:00
|
|
|
|
2023-04-27 11:27:55 +08:00
|
|
|
|
2015-05-21 08:23:50 -06:00
|
|
|
|
2021-08-17 11:03:12 +08:00
|
|
|
|
|
|
|
|
|
2021-07-26 21:02:06 +03:00
|
|
|
|
2015-05-21 08:23:50 -06:00
|
|
|
|
2015-04-16 14:09:55 -06:00
|
|
|
|
2022-12-16 21:12:47 +01:00
|
|
|
|
|
|
|
|
|
2025-07-14 22:27:45 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-12-16 21:12:47 +01:00
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:26 +01:00
|
|
|
|
2025-07-14 22:27:45 +02:00
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-07-14 22:27:45 +02:00
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
|
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2020-02-27 18:29:39 +00:00
|
|
|
|
2025-07-14 22:27:45 +02:00
|
|
|
|
2020-02-27 18:29:39 +00:00
|
|
|
|
2024-08-12 11:01:15 -04:00
|
|
|
|
2025-07-14 22:27:45 +02:00
|
|
|
|
2020-04-23 14:43:31 +00:00
|
|
|
|
2026-08-24 13:32:27 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:26 +01:00
|
|
|
|
|
|
|
|
|
2025-07-14 22:27:45 +02:00
|
|
|
|
2008-11-30 12:17:26 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-01-03 03:02:36 -08:00
|
|
|
|
2008-11-30 12:17:26 +01:00
|
|
|
|
|
|
|
|
|
2014-01-03 03:02:36 -08:00
|
|
|
|
2025-07-14 22:27:45 +02:00
|
|
|
|
2014-01-03 03:02:36 -08:00
|
|
|
|
Bluetooth: btusb: Fix and detect most of the Chinese Bluetooth controllers
For some reason they tend to squat on the very first CSR/
Cambridge Silicon Radio VID/PID instead of paying fees.
This is an extremely common problem; the issue goes as back as 2013
and these devices are only getting more popular, even rebranded by
reputable vendors and sold by retailers everywhere.
So, at this point in time there are hundreds of modern dongles reusing
the ID of what originally was an early Bluetooth 1.1 controller.
Linux is the only place where they don't work due to spotty checks
in our detection code. It only covered a minimum subset.
So what's the big idea? Take advantage of the fact that all CSR
chips report the same internal version as both the LMP sub-version and
HCI revision number. It always matches, couple that with the manufacturer
code, that rarely lies, and we now have a good idea of who is who.
Additionally, by compiling a list of user-reported HCI/lsusb dumps, and
searching around for legit CSR dongles in similar product ranges we can
find what CSR BlueCore firmware supported which Bluetooth versions.
That way we can narrow down ranges of fakes for each of them.
e.g. Real CSR dongles with LMP subversion 0x73 are old enough that
support BT 1.1 only; so it's a dead giveaway when some
third-party BT 4.0 dongle reuses it.
So, to sum things up; there are multiple classes of fake controllers
reusing the same 0A12:0001 VID/PID. This has been broken for a while.
Known 'fake' bcdDevices: 0x0100, 0x0134, 0x1915, 0x2520, 0x7558, 0x8891
IC markings on 0x7558: FR3191AHAL 749H15143 (???)
https://bugzilla.kernel.org/show_bug.cgi?id=60824
Fixes: 81cac64ba258ae (Deal with USB devices that are faking CSR vendor)
Reported-by: Michał Wiśniewski <brylozketrzyn@gmail.com>
Tested-by: Mike Johnson <yuyuyak@gmail.com>
Tested-by: Ricardo Rodrigues <ekatonb@gmail.com>
Tested-by: M.Hanny Sabbagh <mhsabbagh@outlook.com>
Tested-by: Oussama BEN BRAHIM <b.brahim.oussama@gmail.com>
Tested-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2020-07-26 23:12:28 +02:00
|
|
|
|
2025-07-14 22:27:45 +02:00
|
|
|
|
Bluetooth: btusb: Fix and detect most of the Chinese Bluetooth controllers
For some reason they tend to squat on the very first CSR/
Cambridge Silicon Radio VID/PID instead of paying fees.
This is an extremely common problem; the issue goes as back as 2013
and these devices are only getting more popular, even rebranded by
reputable vendors and sold by retailers everywhere.
So, at this point in time there are hundreds of modern dongles reusing
the ID of what originally was an early Bluetooth 1.1 controller.
Linux is the only place where they don't work due to spotty checks
in our detection code. It only covered a minimum subset.
So what's the big idea? Take advantage of the fact that all CSR
chips report the same internal version as both the LMP sub-version and
HCI revision number. It always matches, couple that with the manufacturer
code, that rarely lies, and we now have a good idea of who is who.
Additionally, by compiling a list of user-reported HCI/lsusb dumps, and
searching around for legit CSR dongles in similar product ranges we can
find what CSR BlueCore firmware supported which Bluetooth versions.
That way we can narrow down ranges of fakes for each of them.
e.g. Real CSR dongles with LMP subversion 0x73 are old enough that
support BT 1.1 only; so it's a dead giveaway when some
third-party BT 4.0 dongle reuses it.
So, to sum things up; there are multiple classes of fake controllers
reusing the same 0A12:0001 VID/PID. This has been broken for a while.
Known 'fake' bcdDevices: 0x0100, 0x0134, 0x1915, 0x2520, 0x7558, 0x8891
IC markings on 0x7558: FR3191AHAL 749H15143 (???)
https://bugzilla.kernel.org/show_bug.cgi?id=60824
Fixes: 81cac64ba258ae (Deal with USB devices that are faking CSR vendor)
Reported-by: Michał Wiśniewski <brylozketrzyn@gmail.com>
Tested-by: Mike Johnson <yuyuyak@gmail.com>
Tested-by: Ricardo Rodrigues <ekatonb@gmail.com>
Tested-by: M.Hanny Sabbagh <mhsabbagh@outlook.com>
Tested-by: Oussama BEN BRAHIM <b.brahim.oussama@gmail.com>
Tested-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Ismael Ferreras Morezuelas <swyterzone@gmail.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2020-07-26 23:12:28 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:26 +01:00
|
|
|
|
|
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
2008-11-30 12:17:26 +01:00
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
2025-07-14 22:27:45 +02:00
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
|
|
|
|
|
2014-07-06 14:53:54 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-06-04 08:37:37 +02:00
|
|
|
|
2014-07-06 14:53:54 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
2014-09-16 04:44:50 +02:00
|
|
|
|
2017-02-01 14:24:08 -08:00
|
|
|
|
2026-06-04 08:37:37 +02:00
|
|
|
|
2008-08-18 13:23:52 +02:00
|
|
|
|
|
|
|
|
|
2019-09-27 08:48:58 +02:00
|
|
|
|
2015-10-08 20:23:08 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-04-09 15:58:50 +02:00
|
|
|
|
|
|
|
|
|
2017-11-13 14:44:16 +01:00
|
|
|
|
2022-10-25 14:12:57 -07:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2017-02-01 14:24:08 -08:00
|
|
|
|
2026-06-04 08:37:36 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-12-03 14:38:13 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2017-02-01 14:24:08 -08:00
|
|
|
|
2026-06-04 08:37:36 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-06-04 08:37:37 +02:00
|
|
|
|
|
|
|
|
|
2026-06-04 08:37:38 +02:00
|
|
|
|
2026-06-04 08:37:39 +02:00
|
|
|
|
2026-06-04 08:37:38 +02:00
|
|
|
|
2026-06-04 08:37:39 +02:00
|
|
|
|
|
|
|
|
|
2026-06-04 08:37:40 +02:00
|
|
|
|
2019-01-24 15:28:14 -08:00
|
|
|
|
|
|
|
|
|
2026-06-04 08:37:40 +02:00
|
|
|
|
2017-02-01 14:24:08 -08:00
|
|
|
|
2026-06-04 08:37:40 +02:00
|
|
|
|
2025-12-10 11:02:28 -05:00
|
|
|
|
2026-06-04 08:37:40 +02:00
|
|
|
|
2017-02-01 14:24:08 -08:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-09-23 00:16:36 +02:00
|
|
|
|
|
|
|
|
|
2025-04-16 09:53:38 +00:00
|
|
|
|
2008-09-23 00:16:36 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2015-10-08 20:23:08 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-09-23 16:47:03 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
2026-06-04 08:37:39 +02:00
|
|
|
|
2025-11-05 14:28:41 -05:00
|
|
|
|
2026-06-04 08:37:39 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-11-05 14:28:41 -05:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-09-04 16:03:50 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-10-08 20:23:08 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-09-23 00:16:36 +02:00
|
|
|
|
2015-10-08 20:23:08 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2025-11-05 14:28:41 -05:00
|
|
|
|
2015-10-08 20:23:08 +02:00
|
|
|
|
2008-09-23 00:16:36 +02:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2025-12-10 11:02:28 -05:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:14 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Bluetooth: Properly disable remote wakeup for MT7922/MT7925 on Ryzen platform
It is reported that a remote wakeup could cause MT7922/MT7925's btusb
interface completely unresponsive. Resetting the xHCI root hub doesn't
help at all, and recovering from such a state needs a power cycle.
All reports seen to be relevant to Ryzen-based laptops. These NICs are
usually used as OEM components thanks to some sort of reference designs.
Their popularity on other platforms is unclear. While there is still a
chance that the quirk may exist on other platforms, be cautious and only
apply the quirk to direct children of Ryzen platforms's root hubs for
the time being. In most cases the root hub is on the SoC or PCH, which
needs the quirk. Unfortunately, this can't distinguish root hubs on PCIe
add-in cards. Such roughness should be acceptable, as PCIe USB
controller add-in cards are less commonly used nowadays. On the other
hand, applying the quirk doesn't hurt any functionalities either, as the
device can still be used as a wakeup source if desired. Theoretically,
we could retrieve the root hub's PCI vendor ID with some hierarchy
magic, but that's too intrusive...
Meanwhile, though device_set_wakeup_capable(false) is the correct fix
for other NICs with fake remote wakeup capabilities, doing so for
MT7922/MT7925 effectively prevents it from being used as wakeup
sources as per userspace requests. Hence, return -EBUSY on runtime
suspend to prevent the interface from being autosuspended while it's
still opened, which has the same effect as
device_set_wakeup_capable(false), since disabling remote wakeup simply
causes the USB core to gate runtime autosuspend as well due to
needs_remote_wakeup == 1. The interface can be safely autosuspended as
long as remote wakeup is disabled, i.e., after closing the HCI device.
Specifically, the interface may still take the advantage of remote
wakeup in order to wake up the system from sleep if userspace has
enabled it as a wakeup source.
Fixes: e31d761628ad ("Bluetooth: btmtk: Disable remote wakeup for MT7922/MT7925")
Tested-by: Rafael Passos <rafael@rcpassos.me>
Signed-off-by: Rong Zhang <i@rong.moe>
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
2026-09-02 02:19:18 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-10-01 11:21:37 -04:00
|
|
|
|
2026-01-09 10:05:38 +08:00
|
|
|
|
Bluetooth: Properly disable remote wakeup for MT7922/MT7925 on Ryzen platform
It is reported that a remote wakeup could cause MT7922/MT7925's btusb
interface completely unresponsive. Resetting the xHCI root hub doesn't
help at all, and recovering from such a state needs a power cycle.
All reports seen to be relevant to Ryzen-based laptops. These NICs are
usually used as OEM components thanks to some sort of reference designs.
Their popularity on other platforms is unclear. While there is still a
chance that the quirk may exist on other platforms, be cautious and only
apply the quirk to direct children of Ryzen platforms's root hubs for
the time being. In most cases the root hub is on the SoC or PCH, which
needs the quirk. Unfortunately, this can't distinguish root hubs on PCIe
add-in cards. Such roughness should be acceptable, as PCIe USB
controller add-in cards are less commonly used nowadays. On the other
hand, applying the quirk doesn't hurt any functionalities either, as the
device can still be used as a wakeup source if desired. Theoretically,
we could retrieve the root hub's PCI vendor ID with some hierarchy
magic, but that's too intrusive...
Meanwhile, though device_set_wakeup_capable(false) is the correct fix
for other NICs with fake remote wakeup capabilities, doing so for
MT7922/MT7925 effectively prevents it from being used as wakeup
sources as per userspace requests. Hence, return -EBUSY on runtime
suspend to prevent the interface from being autosuspended while it's
still opened, which has the same effect as
device_set_wakeup_capable(false), since disabling remote wakeup simply
causes the USB core to gate runtime autosuspend as well due to
needs_remote_wakeup == 1. The interface can be safely autosuspended as
long as remote wakeup is disabled, i.e., after closing the HCI device.
Specifically, the interface may still take the advantage of remote
wakeup in order to wake up the system from sleep if userspace has
enabled it as a wakeup source.
Fixes: e31d761628ad ("Bluetooth: btmtk: Disable remote wakeup for MT7922/MT7925")
Tested-by: Rafael Passos <rafael@rcpassos.me>
Signed-off-by: Rong Zhang <i@rong.moe>
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
2026-09-02 02:19:18 +08:00
|
|
|
|
|
|
|
|
|
2023-05-02 15:11:59 -07:00
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:14 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
2011-08-19 23:49:48 +02:00
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:14 +01:00
|
|
|
|
|
|
|
|
|
2024-07-04 14:01:12 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
2008-11-30 12:17:14 +01:00
|
|
|
|
|
|
|
|
|
2017-02-01 14:24:09 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2019-08-14 20:02:52 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-08-17 11:03:12 +08:00
|
|
|
|
2019-08-14 20:02:52 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-08-17 11:03:12 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2019-08-14 20:02:52 +08:00
|
|
|
|
2021-08-17 11:03:12 +08:00
|
|
|
|
2019-08-14 20:02:52 +08:00
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:14 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-07-20 18:53:50 +08:00
|
|
|
|
|
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
2017-07-20 18:53:50 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
2017-07-20 18:53:50 +08:00
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
|
|
|
|
|
2017-07-20 18:53:50 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:14 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
2008-11-30 12:17:14 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-02-01 14:24:09 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:14 +01:00
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
2008-11-30 12:17:14 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
2008-11-30 12:17:14 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2009-02-04 17:41:38 +01:00
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:14 +01:00
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:14 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2024-07-04 14:01:12 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:14 +01:00
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-11-30 12:17:14 +01:00
|
|
|
|
|
|
|
|
|
2023-03-30 09:58:25 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2026-01-12 11:51:13 +01:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2009-08-24 23:44:59 +02:00
|
|
|
|
2012-04-23 10:08:51 -07:00
|
|
|
|
2023-03-30 09:58:25 -07:00
|
|
|
|
|
|
|
|
|
2024-01-04 11:28:22 +08:00
|
|
|
|
|
|
|
|
|
2023-03-30 09:58:25 -07:00
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
2011-11-18 09:47:34 -08:00
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-11-13 14:44:16 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-08-07 22:26:56 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-10-20 14:12:34 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|