All of lore.kernel.org
 help / color / mirror / Atom feed
From: Denis Benato <denis.benato@linux.dev>
To: Thorsten Leemhuis <regressions@leemhuis.info>
Cc: "Ahmed Yaseen" <yaseen@ghoul.dev>,
	"Jiri Kosina" <jikos@kernel.org>,
	"Benjamin Tissoires" <bentiss@kernel.org>,
	"Antheas Kapenekakis" <lkml@antheas.dev>,
	"Ilpo Järvinen" <ilpo.jarvinen@linux.intel.com>,
	"Dmitry Torokhov" <dmitry.torokhov@gmail.com>,
	"Alan Stern" <stern@rowland.harvard.edu>,
	"Kerim Kabirov" <the.privat33r+linux@pm.me>,
	GameBurrow <gameburrow@pm.me>,
	regressions@lists.linux.dev, linux-usb@vger.kernel.org,
	linux-input@vger.kernel.org, linux-kernel@vger.kernel.org,
	stable@vger.kernel.org
Subject: Re: [PATCH v2] HID: usbhid: skip interrupt IN polling for devices with no input reports
Date: Tue, 13 Oct 2026 16:12:04 +0300	[thread overview]
Message-ID: <2f85200c-ecc3-4318-9156-16ace09cac7f@linux.dev> (raw)
In-Reply-To: <fe51a4ac-540f-4d14-ba76-b69b0eb17164@leemhuis.info>

13 ott 2026 15:55:33 Thorsten Leemhuis <regressions@leemhuis.info>:

> On 8/28/26 12:42, Ahmed Yaseen wrote:
>> usbhid starts polling a device's interrupt IN endpoint on open
>> (usbhid_open() -> hid_start_in()). If the report descriptor declares no
>> input reports there is nothing to read there, so the poll is useless,
>> and on some composite devices it is also harmful.
>>
>> The ASUS ROG N-Key keyboards expose a second, input-less interface used
>> only for RGB control via feature reports. Opening its hidraw node (any
>> hidraw reader does, including SDL/Steam Input or a plain cat) starts the
>> pointless IN poll and keypress reports on the keyboard interface get
>> dropped for as long as the node stays open: a lost key-down drops a
>> letter, a lost key-up leaves the key stuck. usbmon shows the dropped
>> reports never reach the URB layer.
>>
>> The useless poll itself is long-standing; commit 4ac74ea68f64 ("HID:
>> asus: early return for ROG devices") is what exposes it on these
>> devices by keeping the input-less interface alive instead of ejecting
>> it, so its hidraw node can be opened and the poll started.
>
> Hmmm, what's the status here? Ahmed, is this still needed, or was this
> fixed in some other way? From the the outside it looks a lot like this
> regression fix feel through the cracks, but would be good to get into
> 7.4-rc1 to finally fix the dropped keypress reports.
>

Hi Thorsten,

This is very much needed and we had to include it in OGC kernel to avoid hid devices resetting constantly.

It is a very important fix and we are waiting for inclusion upstream because games becomes flat out unplayable with certain combination of tools.

Best regards,
Denis Benato

> Ciao, Thorsten
>> Skip the poll in usbhid_open() when the device has no input reports.
>> Feature reports and hidraw output keep working over the control and OUT
>> endpoints, so the interface is otherwise unaffected.
>>
>> Fixes: 4ac74ea68f64 ("HID: asus: early return for ROG devices")
>> Link: https://discuss.cachyos.org/t/keyboard-input-issues-on-asus-rog-strix-16-2025-with-cachyos-during-gaming/30823
>> Link: https://github.com/ublue-os/bazzite/issues/4590
>> Cc: stable@vger.kernel.org
>> Tested-by: Kerim Kabirov <the.privat33r+linux@pm.me>
>> Tested-by: GameBurrow <gameburrow@pm.me>
>> Signed-off-by: Ahmed Yaseen <yaseen@ghoul.dev>
>> Reviewed-by: Denis Benato <denis.benato@linux.dev>
>> ---
>> drivers/hid/usbhid/hid-core.c | 9 ++++++++-
>> 1 file changed, 8 insertions(+), 1 deletion(-)
>>
>> diff --git a/drivers/hid/usbhid/hid-core.c b/drivers/hid/usbhid/hid-core.c
>> index 96b0181cf819..d7cf2b56e117 100644
>> --- a/drivers/hid/usbhid/hid-core.c
>> +++ b/drivers/hid/usbhid/hid-core.c
>> @@ -688,7 +688,14 @@ static int usbhid_open(struct hid_device *hid)
>>
>>     set_bit(HID_OPENED, &usbhid->iofl);
>>
>> -   if (hid->quirks & HID_QUIRK_ALWAYS_POLL) {
>> +   /*
>> +    * ALWAYS_POLL devices are already polled from usbhid_start(), and a
>> +    * device with no input reports has nothing to send on the interrupt
>> +    * IN endpoint. In some cases polling is harmful: on the ASUS ROG
>> +    * N-Key keyboards it makes the sibling interface drop keypresses.
>> +    */
>> +   if ((hid->quirks & HID_QUIRK_ALWAYS_POLL) ||
>> +       list_empty(&hid->report_enum[HID_INPUT_REPORT].report_list)) {
>>         res = 0;
>>         goto Done;
>>     }
>>
>> base-commit: 8d3ae59288f1e7d58d76558a6ee96d533bc5019f


      parent reply	other threads:[~2026-10-13 13:12 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-28 10:42 [PATCH v2 0/1] HID: usbhid: skip interrupt IN polling for devices with no input reports Ahmed Yaseen
2026-08-28 10:42 ` [PATCH v2] " Ahmed Yaseen
2026-10-13 12:54   ` Thorsten Leemhuis
2026-10-13 13:11     ` Antheas Kapenekakis
2026-10-13 13:12     ` Denis Benato [this message]

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=2f85200c-ecc3-4318-9156-16ace09cac7f@linux.dev \
    --to=denis.benato@linux.dev \
    --cc=bentiss@kernel.org \
    --cc=dmitry.torokhov@gmail.com \
    --cc=gameburrow@pm.me \
    --cc=ilpo.jarvinen@linux.intel.com \
    --cc=jikos@kernel.org \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=lkml@antheas.dev \
    --cc=regressions@leemhuis.info \
    --cc=regressions@lists.linux.dev \
    --cc=stable@vger.kernel.org \
    --cc=stern@rowland.harvard.edu \
    --cc=the.privat33r+linux@pm.me \
    --cc=yaseen@ghoul.dev \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.