From: Oliver Neukum <oneukum@suse.de>
To: Daniel Kurtz <djkurtz@chromium.org>
Cc: jkosina@suse.cz, bleung@chromium.org, stern@rowland.harvard.edu,
olofj@chromium.org, linux-input@vger.kernel.org,
linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org
Subject: Re: [PATCH 3/3] HID: usbhid: defer LED setting to a workqueue
Date: Thu, 15 Dec 2011 10:01:52 +0100 [thread overview]
Message-ID: <201112151001.52761.oneukum@suse.de> (raw)
In-Reply-To: <CAGS+omB8kmALYg+m__WpiGzcpTdFEzHz1x3gFFkyqofpnANvNQ@mail.gmail.com>
Am Donnerstag, 15. Dezember 2011, 07:43:09 schrieb Daniel Kurtz:
Hi,
> I'm sorry, I'm not seeing how using a workqueue to set the LEDs
> changes anything with respect to how the driver deals with USB reset.
You are unfortunately right. This means that the driver currently is already
buggy.
> With or without a workqueue, LED control urbs are being queued and/or
> submitted asynchronously to reset. AFAICT, the only thing that
> changes here is exactly when __usbhid_submit_report() is called. In
> the original case, this happens directly in the input event handler.
> In the workqueue case, it happens in a system worker thread some short
> time after the input handler finishes.
The current driver kills the ctrl URB in cease_io() which is not enough
to prevent new IO.
> Could you please be more specific about what this patch breaks and
> perhaps give some guidance on how to fix it?
It breaks nothing. It just continues a bug and I assumed it was not present.
Basically the work queue must do nothing after pre_reset() and post_reset()
ought to rerun the work in case some request came down during that time.
Regards
Oliver
next prev parent reply other threads:[~2011-12-15 9:01 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-11-17 11:23 [PATCH 0/3 v2] usb/hid-core: drain URB queue when going to suspend Daniel Kurtz
2011-11-17 11:23 ` [PATCH 1/3] HID: usbhid: remove LED_ON Daniel Kurtz
2011-11-17 11:23 ` [PATCH 2/3] HID: usbhid: hid-core: submit queued urbs before suspend Daniel Kurtz
2011-12-14 7:55 ` Oliver Neukum
2011-12-14 8:00 ` Daniel Kurtz
[not found] ` <CAGS+omDMipRTVOGV9fG0ciWpuwMRBL-eTY8uDwaiSOW==CkQ-w-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2011-12-14 9:14 ` Oliver Neukum
2011-12-14 9:41 ` Daniel Kurtz
2011-12-14 11:36 ` Oliver Neukum
2011-11-17 11:23 ` [PATCH 3/3] HID: usbhid: defer LED setting to a workqueue Daniel Kurtz
2011-12-14 8:01 ` Oliver Neukum
2011-12-14 8:19 ` Daniel Kurtz
2011-12-14 9:25 ` Oliver Neukum
[not found] ` <201112140901.35203.oneukum-l3A5Bk7waGM@public.gmane.org>
2011-12-14 10:33 ` Daniel Kurtz
2011-12-14 11:22 ` Oliver Neukum
2011-12-15 6:43 ` Daniel Kurtz
2011-12-15 9:01 ` Oliver Neukum [this message]
[not found] ` <201112151001.52761.oneukum-l3A5Bk7waGM@public.gmane.org>
2011-12-20 10:12 ` Daniel Kurtz
2011-12-20 10:18 ` Oliver Neukum
2011-12-21 10:19 ` Jiri Kosina
[not found] ` <1321529030-7845-1-git-send-email-djkurtz-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
2011-12-07 2:42 ` [PATCH 0/3 v2] usb/hid-core: drain URB queue when going to suspend Daniel Kurtz
2011-12-07 9:27 ` Jiri Kosina
-- strict thread matches above, loose matches on Subject: below --
2011-11-01 9:25 [PATCH 0/3] " Daniel Kurtz
2011-11-01 9:25 ` [PATCH 3/3] HID: usbhid: defer LED setting to a workqueue Daniel Kurtz
2011-11-07 14:48 ` Oliver Neukum
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=201112151001.52761.oneukum@suse.de \
--to=oneukum@suse.de \
--cc=bleung@chromium.org \
--cc=djkurtz@chromium.org \
--cc=jkosina@suse.cz \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=olofj@chromium.org \
--cc=stern@rowland.harvard.edu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).