linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Greg KH <greg@kroah.com>
To: Linus Torvalds <torvalds@osdl.org>
Cc: Andrey Borzenkov <arvidjaar@mail.ru>,
	linux-hotplug-devel@lists.sourceforge.net,
	linux-kernel@vger.kernel.org
Subject: Re: removable media revalidation - udev vs. devfs or static /dev
Date: Wed, 7 Jan 2004 11:50:33 -0800	[thread overview]
Message-ID: <20040107195032.GB823@kroah.com> (raw)
In-Reply-To: <Pine.LNX.4.58.0401071123490.12602@home.osdl.org>

On Wed, Jan 07, 2004 at 11:31:55AM -0800, Linus Torvalds wrote:
> On Wed, 7 Jan 2004, Greg KH wrote:
> > > But udev should probably also create all the sub-nodes if it doesn't 
> > > already.
> > 
> > It doesn't, as I thought we could rely on the kernel partition support.
> 
> Indeed, we _can_ rely on the kernel partition support, but the subnodes 
> are needed to get at those partitions.
> 
> Obviously, a "repartitioning hotplug event" can create the subnodes, but 
> that will fail exactly because it wouldn't allow the user to just access 
> the nodes.

It sounds like just having the device node around will not cause the
rescan if you access it.  I don't have any such devices here to test
this out or not.  If true, having udev create all nodes will not help
out much :(

> > Hm, that would work, but what about a user program that just polls on
> > the device, as the rest of this thread discusses?
> 
> I hate those "background CPU users". Have you looked at "ps" output after 
> something like kscd has run, and does a CD check every second? It's 
> _expensive_. It goes all the way down to the hardware, sends a request 
> to the device.

Oh I know, it's one of the first things I disable when setting up a box :)

> Doing it every five minutes wouldn't be an issue, but doing it every five 
> minutes would be absolutely _horrible_ from a user perspective standpoint. 
> If you insert a smartmedia card in your cardreader, you expect to be able 
> to access it pretty much immediately when you start typing. So a second or 
> two of delay is fine, but even just five or ten seconds are already bad.
> 
> So the choice is:
>  - probe every removable device once a second
>  - pre-populate the device nodes, and when the user presses the icon that 
>    says "mount", it will just do so. Immediately. No delay at all.

Based on the previous info, I think we are stuck with probing :(

> NOTE! We do have an alternative: if we were to just make block device 
> nodes support "readdir" and "lookup", you could just do
> 
> 	open("/dev/sda/1" ...)
> 
> and it magically works right. I've wanted to do this for a long time, but 
> every time I suggest allowing it, people scream.

Hm, that would be nice.  I don't remember seeing it being proposed
before, what are the main complaints people have with this?

thanks,

greg k-h

  reply	other threads:[~2004-01-07 19:50 UTC|newest]

Thread overview: 66+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-01-01 20:33 removable media revalidation - udev vs. devfs or static /dev Andrey Borzenkov
2004-01-03  5:58 ` Greg KH
2004-01-03  8:51   ` Andrey Borzenkov
2004-01-03 12:37     ` Andries Brouwer
2004-01-03 12:42       ` Olaf Hering
2004-01-03 16:05         ` Andrey Borzenkov
2004-01-03 17:54           ` Jens Axboe
2004-01-07  9:43             ` Olaf Hering
2004-01-07  9:50               ` Jens Axboe
2004-01-07  9:56                 ` Olaf Hering
2004-01-07  9:59                   ` Jens Axboe
2004-01-07 10:25                     ` Olaf Hering
2004-01-07 10:31                       ` Jens Axboe
2004-01-07 10:47                         ` Andrey Borzenkov
2004-01-07 10:54                           ` Jens Axboe
2004-01-07 17:56                       ` Greg KH
2004-01-30 12:59                     ` Olaf Hering
2004-01-07 11:00                 ` Andrey Borzenkov
2004-01-07 11:05                   ` Jens Axboe
2004-01-07 11:14                     ` Andrey Borzenkov
2004-01-07 11:16                       ` Jens Axboe
2004-01-03 20:51     ` Greg KH
2004-01-07 18:38   ` Linus Torvalds
2004-01-07 18:57     ` Greg KH
2004-01-07 19:23       ` Mika Penttilä
2004-01-07 19:24         ` Greg KH
2004-01-07 19:31           ` Mika Penttilä
2004-01-08  1:38           ` Linus Torvalds
2004-01-07 19:31       ` Linus Torvalds
2004-01-07 19:50         ` Greg KH [this message]
2004-01-07 20:25           ` Richard Troth
2004-01-07 20:38             ` Valdis.Kletnieks
2004-01-07 23:34             ` Greg KH
2004-01-08  0:32           ` Martin J. Bligh
2004-01-08  0:41             ` Greg KH
2004-01-08  1:07               ` Martin J. Bligh
2004-01-08  1:15                 ` Greg KH
2004-01-08  1:50                   ` Martin J. Bligh
2004-01-08 18:34                   ` Martin Schlemmer
2004-01-08  1:48           ` Linus Torvalds
2004-01-08 14:06           ` "Andrey Borzenkov" 
2004-01-08  0:42         ` viro
2004-01-08  1:16           ` Greg KH
2004-01-09  3:36       ` Joel Becker
2004-01-09  9:49         ` Gerd Knorr
2004-01-12 17:16           ` Joel Becker
2004-01-12 23:08             ` J.A. Magallon
2004-01-07 20:52     ` Olaf Hering
2004-01-08  2:03       ` Linus Torvalds
2004-01-08  4:16         ` Gene Heskett
2004-01-08  4:23           ` Linus Torvalds
2004-01-08  7:45         ` Olaf Hering
2004-01-08  2:13     ` Andries Brouwer
2004-01-08  2:19       ` Linus Torvalds
2004-01-08  2:49         ` Andries Brouwer
2004-01-08  2:56           ` Linus Torvalds
2004-01-08  3:35             ` Andries Brouwer
2004-01-08  3:43               ` Linus Torvalds
2004-01-08  8:00                 ` Xavier Bestel
2004-01-09  0:28                 ` Robert Love
2004-01-09  0:52                   ` Linus Torvalds
2004-01-09  1:16                   ` Matt Mackall
2004-01-08 10:32             `  Éric Brunet
2004-01-08  5:19 Iqbal
2004-01-12  9:09 Ling, Xiaofeng
2004-01-12 13:02 Nicolas Mailhot

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=20040107195032.GB823@kroah.com \
    --to=greg@kroah.com \
    --cc=arvidjaar@mail.ru \
    --cc=linux-hotplug-devel@lists.sourceforge.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@osdl.org \
    /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).