1
0
Fork 0
remarkable-linux/drivers/bluetooth
Hans de Goede 5795b076bd Bluetooth: btusb: Restore QCA Rome suspend/resume fix with a "rewritten" version
commit 61f5acea87 upstream.

Commit 7d06d5895c ("Revert "Bluetooth: btusb: fix QCA...suspend/resume"")
removed the setting of the BTUSB_RESET_RESUME quirk for QCA Rome devices,
instead favoring adding USB_QUIRK_RESET_RESUME quirks in usb/core/quirks.c.

This was done because the DIY BTUSB_RESET_RESUME reset-resume handling
has several issues (see the original commit message). An added advantage
of moving over to the USB-core reset-resume handling is that it also
disables autosuspend for these devices, which is similarly broken on these.

But there are 2 issues with this approach:
1) It leaves the broken DIY BTUSB_RESET_RESUME code in place for Realtek
   devices.
2) Sofar only 2 of the 10 QCA devices known to the btusb code have been
   added to usb/core/quirks.c and if we fix the Realtek case the same way
   we need to add an additional 14 entries. So in essence we need to
   duplicate a large part of the usb_device_id table in btusb.c in
   usb/core/quirks.c and manually keep them in sync.

This commit instead restores setting a reset-resume quirk for QCA devices
in the btusb.c code, avoiding the duplicate usb_device_id table problem.

This commit avoids the problems with the original DIY BTUSB_RESET_RESUME
code by simply setting the USB_QUIRK_RESET_RESUME quirk directly on the
usb_device.

This commit also moves the BTUSB_REALTEK case over to directly setting the
USB_QUIRK_RESET_RESUME on the usb_device and removes the now unused
BTUSB_RESET_RESUME code.

BugLink: https://bugzilla.redhat.com/show_bug.cgi?id=1514836
Fixes: 7d06d5895c ("Revert "Bluetooth: btusb: fix QCA...suspend/resume"")
Cc: Leif Liddy <leif.linux@gmail.com>
Cc: Matthias Kaehlcke <mka@chromium.org>
Cc: Brian Norris <briannorris@chromium.org>
Cc: Daniel Drake <drake@endlessm.com>
Cc: Kai-Heng Feng <kai.heng.feng@canonical.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-02-17 13:21:19 +01:00
..
Kconfig Bluetooth: hci_uart: Add Marvell support 2016-09-19 20:32:03 +02:00
Makefile Bluetooth: hci_uart: Add Marvell support 2016-09-19 20:32:03 +02:00
ath3k.c Bluetooth: Add another AR3012 04ca:3018 device 2017-03-15 10:02:40 +08:00
bcm203x.c bluetooth: bcm203x: don't print error when allocating urb fails 2016-09-27 12:20:17 +02:00
bfusb.c Bluetooth: bfusb: Fix the return error code 2015-12-22 15:25:33 +01:00
bluecard_cs.c Bluetooth: Use new hci_skb_pkt_* wrappers for drivers 2015-11-19 17:50:27 +01:00
bpa10x.c Bluetooth: bpa10x: Add support for hci_set_fw_info 2016-07-18 09:33:56 +03:00
bt3c_cs.c Bluetooth: Use new hci_skb_pkt_* wrappers for drivers 2015-11-19 17:50:27 +01:00
btbcm.c Bluetooth: btbcm: Fix handling of firmware not found 2016-02-23 20:29:37 +01:00
btbcm.h Bluetooth: btbcm: Support the BCM4354 Bluetooth UART device 2015-06-17 18:56:53 +02:00
btintel.c Bluetooth: btintel: Create common Intel Version Read function 2015-12-10 00:51:51 +01:00
btintel.h Bluetooth: btintel: Create common Intel Version Read function 2015-12-10 00:51:51 +01:00
btmrvl_debugfs.c Bluetooth: btmrvl add firmware dump support 2014-12-03 17:35:51 +01:00
btmrvl_drv.h btmrvl: add platform specific wakeup interrupt support 2016-05-02 19:26:15 +02:00
btmrvl_main.c Bluetooth: Rename HCI_BREDR into HCI_PRIMARY 2016-07-09 21:37:13 +03:00
btmrvl_sdio.c btmrvl: avoid double-disable_irq() race 2017-10-21 17:21:38 +02:00
btmrvl_sdio.h btmrvl: add platform specific wakeup interrupt support 2016-05-02 19:26:15 +02:00
btqca.c Bluetooth: btqca: remove null checks on edl->data as it is an array 2016-09-19 20:19:34 +02:00
btqca.h Bluetooth: btqca: Introduce generic QCA ROME support 2015-08-10 23:52:20 +02:00
btqcomsmd.c Bluetooth: Introduce Qualcomm WCNSS SMD based HCI driver 2016-09-19 20:19:34 +02:00
btrtl.c Bluetooth: btrtl: Add RTL8822BE Bluetooth device 2016-09-19 20:19:34 +02:00
btrtl.h Bluetooth: btrtl: Create separate module for Realtek BT driver 2015-05-14 12:04:12 +02:00
btsdio.c Bluetooth: btsdio: Do not bind to non-removable BCM43341 2018-02-17 13:21:18 +01:00
btuart_cs.c Bluetooth: Use new hci_skb_pkt_* wrappers for drivers 2015-11-19 17:50:27 +01:00
btusb.c Bluetooth: btusb: Restore QCA Rome suspend/resume fix with a "rewritten" version 2018-02-17 13:21:19 +01:00
btwilink.c Bluetooth: btwilink: Fix probe return value 2016-10-20 10:14:49 +02:00
dtl1_cs.c Bluetooth: Use new hci_skb_pkt_* wrappers for drivers 2015-11-19 17:50:27 +01:00
hci_ag6xx.c Bluetooth: hci_uart: Add diag and address support for Intel/AG6xx 2016-02-29 19:25:22 +02:00
hci_ath.c Bluetooth: Use new hci_skb_pkt_* wrappers for drivers 2015-11-19 17:50:27 +01:00
hci_bcm.c Bluetooth: hci_bcm: add missing tty-device sanity check 2017-05-20 14:28:41 +02:00
hci_bcsp.c Bluetooth: BCSP fails to ACK re-transmitted frames from the peer 2016-09-24 06:40:24 +02:00
hci_h4.c Bluetooth: Use new hci_skb_pkt_* wrappers for drivers 2015-11-19 17:50:27 +01:00
hci_h5.c Bluetooth: h5: Do not initialize Configuration field 2015-12-10 19:19:17 +01:00
hci_intel.c Bluetooth: hci_intel: add missing tty-device sanity check 2017-05-20 14:28:41 +02:00
hci_ldisc.c Bluetooth: Use single return in hci_uart_tty_ioctl() call 2016-09-24 06:40:24 +02:00
hci_ll.c Bluetooth: Use new hci_skb_pkt_* wrappers for drivers 2015-11-19 17:50:27 +01:00
hci_mrvl.c Bluetooth: hci_uart: Add Marvell support 2016-09-19 20:32:03 +02:00
hci_qca.c Bluetooth: Remove deprecated create_singlethread_workqueue 2016-09-19 20:19:34 +02:00
hci_uart.h Bluetooth: hci_uart: Add Marvell support 2016-09-19 20:32:03 +02:00
hci_vhci.c miscdevice: Use module_misc_device() macro 2016-08-31 14:12:35 +02:00