Bluetooth: btusb: request wake pin with NOAUTOEN
authorBrian Norris <briannorris@chromium.org>
Tue, 9 Apr 2019 18:49:17 +0000 (11:49 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 8 May 2019 05:21:52 +0000 (07:21 +0200)
commitf5ad05e680aa40a14a43073f9ccf7b43a0237aea
treeca168a7fd85fe8446a1b147ffb76b9e643ca04f8
parent3f8497cfff3bcfe87d0ba08f691a96e0e3caf6cf
Bluetooth: btusb: request wake pin with NOAUTOEN

commit 771acc7e4a6e5dba779cb1a7fd851a164bc81033 upstream.

Badly-designed systems might have (for example) active-high wake pins
that default to high (e.g., because of external pull ups) until they
have an active firmware which starts driving it low.  This can cause an
interrupt storm in the time between request_irq() and disable_irq().

We don't support shared interrupts here, so let's just pre-configure the
interrupt to avoid auto-enabling it.

Fixes: fd913ef7ce61 ("Bluetooth: btusb: Add out-of-band wakeup support")
Fixes: 5364a0b4f4be ("arm64: dts: rockchip: move QCA6174A wakeup pin into its USB node")
Signed-off-by: Brian Norris <briannorris@chromium.org>
Reviewed-by: Matthias Kaehlcke <mka@chromium.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/bluetooth/btusb.c