OSDN Git Service

Bluetooth: bluecard: fix LED behavior
authorOndrej Zary <linux@rainbow-software.org>
Sat, 5 Aug 2017 19:34:45 +0000 (21:34 +0200)
committerMarcel Holtmann <marcel@holtmann.org>
Mon, 7 Aug 2017 06:36:21 +0000 (08:36 +0200)
commit859d2351172482c5bf5b727b1fe10d98ba334fd6
tree138cef880a2a40b14a4647b64a3dd92bd645f605
parentdf44f531ee572a20128b2b610370ef3861b369ae
Bluetooth: bluecard: fix LED behavior

Keep power LED on during activity.

LED timer races with power LED disabling in hci_close(), resulting in
power LED left on after closing.
Stop LED timer before disabling power LED.

BTW. On cards without an activity LED, the behavior is a bit weird:
The LED is on after hci_open() but only until the first data transfer.
Then it's off in idle and on during activity.
It could be improved by keeping the LED on in idle and flashing during
activity.

Signed-off-by: Ondrej Zary <linux@rainbow-software.org>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
drivers/bluetooth/bluecard_cs.c