mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Matthew Dharm <mdharm-kernel@one-eyed-alien.net>
To: David Brownell <david-b@pacbell.net>
Cc: Manfred Spraul <manfred@colorfullife.com>,
	linux-usb-devel@lists.sourceforge.net, greg@kroah.com,
	linux-kernel@vger.kernel.org
Subject: Re: [linux-usb-devel] Re: usb storage cleanup
Date: Thu, 4 Jul 2002 14:16:26 -0700	[thread overview]
Message-ID: <20020704141626.E17360@one-eyed-alien.net> (raw)
In-Reply-To: <3D24AEDA.9090100@pacbell.net>; from david-b@pacbell.net on Thu, Jul 04, 2002 at 01:23:54PM -0700

[-- Attachment #1: Type: text/plain, Size: 1646 bytes --]

Now... wait a second here....

You say the dirver "is supposed to wait until all urbs" are completed...
but we're talking about the case where the device is now gone...

So how do the urbs complete?  Something is causing them to complete when
the cable is removed -- that's the behavior I've observed, at least.

Matt

On Thu, Jul 04, 2002 at 01:23:54PM -0700, David Brownell wrote:
> >>Test case: user pulls out the usb cable while a transfer is in progress. 
> >>urb submitted to the device, reply not yet received.
> >>Result: storage_disconnect() would hang for 20 seconds until 
> >>command_abort() is called.
> > 
> > 
> > No, not quite.   The HCD accelerates the URBs to completion if the device
> > is removed with an URB pending on it.  It therefore shouldn't hang for the
> > timeout -- if you're seeing this behavior, then the HCD is broken.
> 
> Actually all of the interesting work is triggered by khubd,
> and then the device driver.
> 
> Khubd calls usb_disconnect() for the device.  That disconnects
> each driver (which is supposed to wait until all urbs it's
> submitted have completed, and not submit any more URBS).
> 
> Only at the very end of this does the HCD hear anything about
> devices going away.  If there's any URB still submitted at that
> point it's not a bug in the HCD at all ... but in a device
> driver that didn't implement disconnect() correctly.
> 
> - Dave
> 
> 
> 

-- 
Matthew Dharm                              Home: mdharm-usb@one-eyed-alien.net 
Maintainer, Linux USB Mass Storage Driver

Way to go, lava boy.
					-- Stef to Greg
User Friendly, 3/26/1998

[-- Attachment #2: Type: application/pgp-signature, Size: 232 bytes --]

  reply	other threads:[~2002-07-04 21:14 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-07-03 21:14 Manfred Spraul
2002-07-03 21:43 ` Matthew Dharm
2002-07-03 22:19   ` Manfred Spraul
2002-07-04  0:05     ` Matthew Dharm
2002-07-04 17:12       ` Manfred Spraul
2002-07-04 19:50         ` Matthew Dharm
2002-07-04 19:54           ` Arnaldo Carvalho de Melo
2002-07-04 20:02             ` Greg KH
2002-07-04 20:23           ` [linux-usb-devel] " David Brownell
2002-07-04 21:16             ` Matthew Dharm [this message]
2002-07-04 22:05               ` David Brownell

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=20020704141626.E17360@one-eyed-alien.net \
    --to=mdharm-kernel@one-eyed-alien.net \
    --cc=david-b@pacbell.net \
    --cc=greg@kroah.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-usb-devel@lists.sourceforge.net \
    --cc=manfred@colorfullife.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 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®