mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Jiri Kosina <jikos@kernel.org>
To: Marius Zachmann <mail@mariuszachmann.de>
Cc: Guenter Roeck <linux@roeck-us.net>,
	Jean Delvare <jdelvare@suse.com>,
	linux-hwmon@vger.kernel.org, linux-kernel@vger.kernel.org,
	Benjamin Tissoires <benjamin.tissoires@redhat.com>,
	Dmitry Torokhov <dmitry.torokhov@gmail.com>,
	linux-input@vger.kernel.org
Subject: Re: [PATCH v2] hwmon: corsair-cpro: fix ccp_probe, add delay [HID related]
Date: Tue, 18 Aug 2020 19:51:38 +0200 (CEST)	[thread overview]
Message-ID: <nycvar.YFH.7.76.2008181948290.27422@cbobk.fhfr.pm> (raw)
In-Reply-To: <79890342.HV0Al07Iil@marius>

On Tue, 18 Aug 2020, Marius Zachmann wrote:

> > > Possibly because of the changes in usbhid/hid-core.c the first
> > > raw input report is not received during ccp_probe function and it will
> > > timeout. I am not sure, whether this behaviour is expected after
> > > hid_device_io_start or if I am missing something.
> > > As a solution this adds msleep(50) to ccp_probe so that all initial
> > > input reports can be received.
> > > 
> > > Signed-off-by: Marius Zachmann <mail@mariuszachmann.de>
> > 
> > Let's just ask the HID maintainers. Is this expected, and the correct fix ?
> 
> This seems to be a problem with "HID: usbhid: do not sleep when opening
> device". There is a bug report with some Logitech devices at the correct
> thread. These drivers also use hid_device_io_start and fail. Seems to me,
> this is the same problem and I retract this (not so beautiful) fix until
> this is sorted out.

[ CCing Dmitry ]

Yeah, this problem popped out also in other contexts, where many Logitech 
devices didn't probe properly, because of the race where the first IRQ is 
dropped on the floor (after hid_device_io_start() happens, but before the 
50ms timeout passess), and report descriptor never gets parsed and 
populated.

As this is just a boot time micro-optimization, I am going to revert the 
patch for 5.9 now, and we can try to fix this properly for next merge 
window.

Thanks,

-- 
Jiri Kosina
SUSE Labs


      parent reply	other threads:[~2020-08-18 17:51 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-08-17  7:00 [PATCH v2] hwmon: corsair-cpro: fix ccp_probe, add delay Marius Zachmann
2020-08-17 15:35 ` [PATCH v2] hwmon: corsair-cpro: fix ccp_probe, add delay [HID related] Guenter Roeck
2020-08-18 13:12   ` Marius Zachmann
2020-08-18 13:42     ` Guenter Roeck
2020-08-18 17:51     ` Jiri Kosina [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=nycvar.YFH.7.76.2008181948290.27422@cbobk.fhfr.pm \
    --to=jikos@kernel.org \
    --cc=benjamin.tissoires@redhat.com \
    --cc=dmitry.torokhov@gmail.com \
    --cc=jdelvare@suse.com \
    --cc=linux-hwmon@vger.kernel.org \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@roeck-us.net \
    --cc=mail@mariuszachmann.de \
    /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

all inboxes | Powered by JetHome®