]> git.baikalelectronics.ru Git - kernel.git/commit
Bluetooth: Make hidp_get_raw_report abort if the session is terminating
authorKarl Relton <karllinuxtest.relton@ntlworld.com>
Wed, 20 Feb 2013 18:16:19 +0000 (18:16 +0000)
committerGustavo Padovan <gustavo.padovan@collabora.co.uk>
Fri, 8 Mar 2013 13:38:44 +0000 (10:38 -0300)
commitac710f2c288cb34b561af0220bdbe1bb05c0a3ab
tree0747aab373c6c355dedd849d692b5499f59c65e9
parentcd5742998193c89707cdfe354b864a0a55ed7f90
Bluetooth: Make hidp_get_raw_report abort if the session is terminating

After linux 3.2 the hid_destroy_device call in hidp_session
cleaning up invokes a hook to the power_supply code which
in turn tries to read the battery capacity. This read will
trigger a call to hidp_get_raw_report which is bound to fail
because the device is being taken away - so rather than
wait for the 5 second timeout failure this changes enables
it to fail straight away.

Signed-off-by: Karl Relton <karllinuxtest.relton@ntlworld.com>
Reviewed-by: David Herrmann <dh.herrmann@gmail.com>
Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk>
net/bluetooth/hidp/core.c