Messages in this thread | | | From | Oliver Neukum <> | Subject | Re: [PATCH 3/3] HID: usbhid: defer LED setting to a workqueue | Date | Mon, 7 Nov 2011 15:48:04 +0100 |
| |
Am Dienstag, 1. November 2011, 10:25:47 schrieb Daniel Kurtz: > Defer LED setting action to a workqueue. > This is more likely to perform all LED change events in a single URB. > > Signed-off-by: Daniel Kurtz <djkurtz@chromium.org> > --- > drivers/hid/hid-input.c | 42 ++++++++++++++++++++++++++++++++++++++++ > drivers/hid/usbhid/hid-core.c | 43 +++++++++++++++++++++++++++++++--------- > drivers/hid/usbhid/usbhid.h | 2 + > include/linux/hid.h | 2 +
> @@ -1292,6 +1314,7 @@ static void hid_cancel_delayed_stuff(struct usbhid_device *usbhid) > { > del_timer_sync(&usbhid->io_retry); > cancel_work_sync(&usbhid->reset_work); > + cancel_work_sync(&usbhid->led_work); > }
Hi,
this seems to introduce a race in usbhid_stop() which might fail to kill the urb used to change the LEDs.
Regards Oliver
| |