All of lore.kernel.org
 help / color / mirror / Atom feed
From: Alan Stern <stern@rowland.harvard.edu>
To: Paul Zimmerman <pauldzim@gmail.com>
Cc: Greg KH <greg@kroah.com>,
	David Heinzelmann <heinzelmann.david@gmail.com>,
	USB list <linux-usb@vger.kernel.org>
Subject: Re: [PATCH] USB: hub: Don't record a connect-change event during reset-resume
Date: Fri, 31 Jan 2020 16:04:12 -0500 (EST)	[thread overview]
Message-ID: <Pine.LNX.4.44L0.2001311559490.1577-100000@iolanthe.rowland.org> (raw)
In-Reply-To: <20200131123653.2ef373e4@EliteBook>

On Fri, 31 Jan 2020, Paul Zimmerman wrote:

> > Note that performing the unnecessary check is not actually a bug.
> > Devices are supposed to be able to send descriptors back to the host
> > even when they are busy doing something else.  The underlying cause of
> > Paul's problem lies in his Bluetooth adapter.  Nevertheless, we
> > shouldn't perform the same check twice in a row -- and as a nice side
> > benefit, removing the extra check allows the Bluetooth adapter to work
> > more reliably.
> 
> Actually, at the time the failure happens, the bluetooth driver is putting
> the device into a "manufacturer mode" and downloading a firmware patch to
> the device. So I don't think we can fault the device for not responding to
> a get-descriptor request at that point. Probably there should be some kind
> of locking in the driver while that is being done.

Heh.  We don't have any locking of that sort in the kernel.  Any user 
at any time can run "lsusb -v" and that program will try to communicate 
with every attached USB device.  There's no way to claim exclusive 
rights to a device.

The fact that firmware loading works at all is more or less a matter of
luck (although the odds are with us).

> Nevertheless, your patch makes everything work again, so I think it's
> "good enough" :)
> 
> Thanks,
> Paul

You're welcome.

Alan Stern


      reply	other threads:[~2020-01-31 21:04 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-01-31 15:39 [PATCH] USB: hub: Don't record a connect-change event during reset-resume Alan Stern
2020-01-31 19:36 ` Paul Zimmerman
2020-01-31 21:04   ` Alan Stern [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=Pine.LNX.4.44L0.2001311559490.1577-100000@iolanthe.rowland.org \
    --to=stern@rowland.harvard.edu \
    --cc=greg@kroah.com \
    --cc=heinzelmann.david@gmail.com \
    --cc=linux-usb@vger.kernel.org \
    --cc=pauldzim@gmail.com \
    /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.