linux-scsi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Matthew Wilcox <matthew@wil.cx>
To: Stefan Richter <stefanr@s5r6.in-berlin.de>
Cc: Pekka J Enberg <penberg@cs.helsinki.fi>,
	Alan Stern <stern@rowland.harvard.edu>,
	linux-kernel@vger.kernel.org, dsd@gentoo.org,
	mdharm-usb@one-eyed-alien.net, linux-usb@vger.kernel.org,
	vegardno@ifi.uio.no, James.Bottomley@HansenPartnership.com,
	linux-scsi@vger.kernel.org, Greg KH <greg@kroah.com>
Subject: Re: [RFC/PATCH] usb-storage: wait for device scanning before mounting root
Date: Thu, 19 Jun 2008 14:22:26 -0600	[thread overview]
Message-ID: <20080619202226.GP4392@parisc-linux.org> (raw)
In-Reply-To: <485AB95E.5070609@s5r6.in-berlin.de>

On Thu, Jun 19, 2008 at 09:54:06PM +0200, Stefan Richter wrote:
> [...]
> > The mail that I just pinged described a way to enhance the
> > API -- letting you tell scsi "I've started scanning, save me a place in
> > the queue" and "I've finished scanning, hook me up".
> 
> When would be the right time to say "I've started scanning"?  SCSI
> transport driver initialization?  Or end of USB/FireWire/... HCD
> registration?

You would need to call it before you could attempt to register any
devices.  So fairly early on in the initialisation of sbp2/usb-storage.

> When to say "I've finished scanning"? --- I think the answer is:  When
> (a) probing of a configurable number of SCSI targets or logical units
> was finished or (b) a configurable timeout occurs, whatever of the two
> happens first.
> 
> (Explanation, if one is necessary:  SCSI targets may pop out of the
> woods any time; it is impossible to say "from this moment on there won't
> show up any new ones anymore".  This is just as true for cold boot and
> warm boot as it is for subsequent operation.)

Yes, I do see the problem.  There's no way the SCSI core can know when
a driver has finished scanning, so I've punted to the driver to set its
own timeout here.  I know that new devices really can show up at any
time, but I think it's reasonable to say that if a machine is booted
with the same configuration as last time, the drives should show up with
the same names.

-- 
Intel are signing my paycheques ... these opinions are still mine
"Bill, look, we understand that you're interested in selling us this
operating system, but compare it to ours.  We can't possibly take such
a retrograde step."

  reply	other threads:[~2008-06-19 20:22 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <Pine.LNX.4.44L0.0804241704220.14840-100000@iolanthe.rowland.org>
2008-04-24 21:25 ` [RFC/PATCH] usb-storage: wait for device scanning before mounting root Pekka J Enberg
2008-04-24 22:56   ` Greg KH
     [not found]     ` <20080424225604.GA18737-U8xfFu+wG4EAvxtiuMwx3w@public.gmane.org>
2008-04-24 23:30       ` Matthew Dharm
2008-04-25  6:30         ` Pekka J Enberg
2008-04-25  7:04           ` Matthew Dharm
     [not found]             ` <20080425070439.GA18915-JGfshJpz5UybPZpvUQj5UqxOck334EZe@public.gmane.org>
2008-04-25  8:19               ` Pekka J Enberg
2008-04-25 15:35                 ` Matthew Dharm
     [not found]                 ` <Pine.LNX.4.64.0804251116000.758-E5M5q+8Jmr6WKadcF5yKzn5wuOn9r4cE@public.gmane.org>
2008-04-25 16:05                   ` Greg KH
2008-04-25  6:09       ` Pekka J Enberg
2008-04-25  7:53   ` Stefan Richter
2008-04-25  8:15     ` Pekka J Enberg
2008-04-25  9:11       ` Matthew Wilcox
     [not found]         ` <20080425091122.GA14990-6jwH94ZQLHl74goWV3ctuw@public.gmane.org>
2008-06-19 18:23           ` Matthew Wilcox
2008-06-19 18:39             ` Stefan Richter
2008-06-19 18:43               ` Stefan Richter
     [not found]               ` <485AA7EA.6080105-MtYdepGKPcBMYopoZt5u/LNAH6kLmebB@public.gmane.org>
2008-06-19 18:54                 ` Matthew Wilcox
     [not found]                   ` <20080619185419.GN4392-6jwH94ZQLHl74goWV3ctuw@public.gmane.org>
2008-06-19 19:52                     ` Matthew Dharm
2008-06-19 20:49                       ` Matthew Wilcox
     [not found]                       ` <20080619204954.GQ4392@parisc-linux.org>
     [not found]                         ` <20080619204954.GQ4392-6jwH94ZQLHl74goWV3ctuw@public.gmane.org>
2008-06-19 21:19                           ` Stefan Richter
2008-06-19 19:54                     ` Stefan Richter
2008-06-19 20:22                       ` Matthew Wilcox [this message]
     [not found]                         ` <20080619202226.GP4392-6jwH94ZQLHl74goWV3ctuw@public.gmane.org>
2008-06-19 20:34                           ` Stefan Richter
     [not found]             ` <20080619182310.GA30833-6jwH94ZQLHl74goWV3ctuw@public.gmane.org>
2008-06-19 21:39               ` Alan Stern
2008-06-19 23:13                 ` David Brownell
2008-06-20  9:53                   ` Gabor Gombas
     [not found]                     ` <20080620095311.GK15159-WfxVeM0IB4OcrO3FVCo2em/Xy1I+TMuj@public.gmane.org>
2008-06-20 14:14                       ` Matthew Dharm
     [not found]                 ` <Pine.LNX.4.44L0.0806191735570.2229-100000-IYeN2dnnYyZXsRXLowluHWD2FQJk+8+b@public.gmane.org>
2008-06-20 15:15                   ` Vegard Nossum
2008-06-20 15:31                     ` Matthew Wilcox
2008-06-20 15:42                     ` Alan Stern
2008-06-20 16:37                       ` Stefan Richter

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=20080619202226.GP4392@parisc-linux.org \
    --to=matthew@wil.cx \
    --cc=James.Bottomley@HansenPartnership.com \
    --cc=dsd@gentoo.org \
    --cc=greg@kroah.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=mdharm-usb@one-eyed-alien.net \
    --cc=penberg@cs.helsinki.fi \
    --cc=stefanr@s5r6.in-berlin.de \
    --cc=stern@rowland.harvard.edu \
    --cc=vegardno@ifi.uio.no \
    /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;
as well as URLs for NNTP newsgroup(s).