HID: wiimote: narrow spinlock range in wiimote_hid_event()
authorIan Abbott <abbotti@mev.co.uk>
Fri, 4 Sep 2020 13:21:43 +0000 (14:21 +0100)
committerJiri Kosina <jkosina@suse.cz>
Mon, 7 Sep 2020 14:03:51 +0000 (16:03 +0200)
commit5eae59cc876c8c1043d3eb55a2e965bb36e90bba
tree1684c1a18253b7581549f283a86f566ca375ede1
parentaeeba45a9df34a00113f96f9f52c45e250ff7b7d
HID: wiimote: narrow spinlock range in wiimote_hid_event()

In `wiimote_hid_event()`, the `wdata->state.lock` spinlock does not need
to be held while searching `handlers[]` for a suitable handler function.
Change it so the spinlock is only held during the call to the handler
function itself.

Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
Reviewed-by: David Rheinsberg <david.rheinsberg@gmail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
drivers/hid/hid-wiimote-core.c