lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Mon, 20 Feb 2012 16:40:49 -0500 (EST)
From:	Alan Stern <stern@...land.harvard.edu>
To:	Sebastian Andrzej Siewior <bigeasy@...utronix.de>
cc:	Oliver Neukum <oliver@...kum.org>, <netdev@...r.kernel.org>,
	<linux-usb@...r.kernel.org>
Subject: Re: [PATCH] net/usbnet: avoid recursive locking in usbnet_stop()

On Mon, 20 Feb 2012, Sebastian Andrzej Siewior wrote:

> > What's the issue here?
> >
> > If a driver calls usb_unlink_urb() while holding a lock, and the
> > completion routine tries to acquire the same lock, then deadlock is
> > possible.  The fact that usb_unlink_urb() is asynchronous is not a
> > guarantee of anything; the HCD is allowed to call the completion
> > handler from within usb_unlink_urb().
> >
> > It's true that the kerneldoc for usb_unlink_urb() says "This request is
> > always asynchronous".  It might be a good idea to remove the word
> > "always", because it seems to give people the wrong idea.
> 
> I see. So you approve that patch and suggest to remove the "always"
> wording plus adding something like "the hcd might call complete routine
> during unlink" ?

Well, I haven't read the patch and don't really understand what issue 
it tries to solve.  But if that issue is the one I talked about above 
then yes, it makes sense.  And changing the documentation as you 
suggest would be a good thing to do in any case.

Alan Stern

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ