linux-input.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] usbhid: discarded events don't abort idleness
@ 2015-11-05 11:55 Oliver Neukum
  2015-11-20 10:00 ` Jiri Kosina
  2015-11-23 14:47 ` Jiri Kosina
  0 siblings, 2 replies; 4+ messages in thread
From: Oliver Neukum @ 2015-11-05 11:55 UTC (permalink / raw)
  To: jkosina, linux-input; +Cc: Oliver Neukum

If an event is discarded the device stays idle.
Just reverse the order of check and marking busy.

Signed-off-by: Oliver Neukum <oneukum@suse.com>
---
 drivers/hid/usbhid/hid-core.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/hid/usbhid/hid-core.c b/drivers/hid/usbhid/hid-core.c
index 36712e9..19a4364 100644
--- a/drivers/hid/usbhid/hid-core.c
+++ b/drivers/hid/usbhid/hid-core.c
@@ -274,10 +274,10 @@ static void hid_irq_in(struct urb *urb)
 
 	switch (urb->status) {
 	case 0:			/* success */
-		usbhid_mark_busy(usbhid);
 		usbhid->retry_delay = 0;
 		if ((hid->quirks & HID_QUIRK_ALWAYS_POLL) && !hid->open)
 			break;
+		usbhid_mark_busy(usbhid);
 		if (!test_bit(HID_RESUME_RUNNING, &usbhid->iofl)) {
 			hid_input_report(urb->context, HID_INPUT_REPORT,
 					 urb->transfer_buffer,
-- 
2.1.4


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2015-11-23 14:47 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-11-05 11:55 [PATCH] usbhid: discarded events don't abort idleness Oliver Neukum
2015-11-20 10:00 ` Jiri Kosina
2015-11-23  9:17   ` Oliver Neukum
2015-11-23 14:47 ` Jiri Kosina

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).