LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
* does udev support sw raid0?
@ 2004-05-14 17:42 Norberto Bensa
  2004-05-14 18:34 ` Greg KH
  0 siblings, 1 reply; 8+ messages in thread
From: Norberto Bensa @ 2004-05-14 17:42 UTC (permalink / raw)
  To: linux-kernel

Hello list,

I'm trying to setup my box to use udev but I'm stuck.

My /home partition is on a software raid0. Using devfs, I have no problems. I 
can "mount /dev/md/0 /home" and I'm done, but udev seems to ignore raid0 
completely. md and raid0 modules are loaded but there're no md/raid devices 
on /dev.

So what's the problem here? Does udev support sw raid0 devices? Or the other 
way around, does sw raid0 support udev?

Many thanks in advance,
Norberto

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: does udev support sw raid0?
  2004-05-14 17:42 does udev support sw raid0? Norberto Bensa
@ 2004-05-14 18:34 ` Greg KH
  2004-05-14 18:39   ` Christoph Hellwig
  2004-05-14 18:48   ` Norberto Bensa
  0 siblings, 2 replies; 8+ messages in thread
From: Greg KH @ 2004-05-14 18:34 UTC (permalink / raw)
  To: Norberto Bensa; +Cc: linux-kernel

On Fri, May 14, 2004 at 02:42:38PM -0300, Norberto Bensa wrote:
> Hello list,
> 
> I'm trying to setup my box to use udev but I'm stuck.
> 
> My /home partition is on a software raid0. Using devfs, I have no problems. I 
> can "mount /dev/md/0 /home" and I'm done, but udev seems to ignore raid0 
> completely. md and raid0 modules are loaded but there're no md/raid devices 
> on /dev.

Do your md raid devices show up in /sys/block?  If so, then udev should
support them.  If not, then udev will not.

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: does udev support sw raid0?
  2004-05-14 18:34 ` Greg KH
@ 2004-05-14 18:39   ` Christoph Hellwig
  2004-05-14 18:46     ` Greg KH
  2004-05-14 18:50     ` Norberto Bensa
  2004-05-14 18:48   ` Norberto Bensa
  1 sibling, 2 replies; 8+ messages in thread
From: Christoph Hellwig @ 2004-05-14 18:39 UTC (permalink / raw)
  To: Greg KH; +Cc: Norberto Bensa, linux-kernel

On Fri, May 14, 2004 at 11:34:50AM -0700, Greg KH wrote:
> Do your md raid devices show up in /sys/block?  If so, then udev should
> support them.  If not, then udev will not.

md has the chicken-egg problem of having to issue an ioctl on the md device
to register a gendisk. 


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: does udev support sw raid0?
  2004-05-14 18:39   ` Christoph Hellwig
@ 2004-05-14 18:46     ` Greg KH
  2004-05-14 18:51       ` Christoph Hellwig
  2004-05-14 19:10       ` Kevin P. Fleming
  2004-05-14 18:50     ` Norberto Bensa
  1 sibling, 2 replies; 8+ messages in thread
From: Greg KH @ 2004-05-14 18:46 UTC (permalink / raw)
  To: Christoph Hellwig, Norberto Bensa, linux-kernel

On Fri, May 14, 2004 at 07:39:13PM +0100, Christoph Hellwig wrote:
> On Fri, May 14, 2004 at 11:34:50AM -0700, Greg KH wrote:
> > Do your md raid devices show up in /sys/block?  If so, then udev should
> > support them.  If not, then udev will not.
> 
> md has the chicken-egg problem of having to issue an ioctl on the md device
> to register a gendisk. 

Ick.

How did this work with devfs then?  The device node would not be present
before the ioctl needed to be called, right?  Or did it do the "magic
lookup" mess and just "know" about md devices?

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: does udev support sw raid0?
  2004-05-14 18:34 ` Greg KH
  2004-05-14 18:39   ` Christoph Hellwig
@ 2004-05-14 18:48   ` Norberto Bensa
  1 sibling, 0 replies; 8+ messages in thread
From: Norberto Bensa @ 2004-05-14 18:48 UTC (permalink / raw)
  To: linux-kernel; +Cc: Greg KH

Greg KH wrote:
> On Fri, May 14, 2004 at 02:42:38PM -0300, Norberto Bensa wrote:
> > I'm trying to setup my box to use udev but I'm stuck.
> Do your md raid devices show up in /sys/block?  If so, then udev should
> support them.  If not, then udev will not.

No if I boot with devfs=nomount. Yes otherwise.

Regards,
Norberto

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: does udev support sw raid0?
  2004-05-14 18:39   ` Christoph Hellwig
  2004-05-14 18:46     ` Greg KH
@ 2004-05-14 18:50     ` Norberto Bensa
  1 sibling, 0 replies; 8+ messages in thread
From: Norberto Bensa @ 2004-05-14 18:50 UTC (permalink / raw)
  To: linux-kernel; +Cc: Christoph Hellwig, Greg KH

Christoph Hellwig wrote:
> md has the chicken-egg problem of having to issue an ioctl on the md device
> to register a gendisk.

So do I need to do something special?

Thanks,
Norberto

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: does udev support sw raid0?
  2004-05-14 18:46     ` Greg KH
@ 2004-05-14 18:51       ` Christoph Hellwig
  2004-05-14 19:10       ` Kevin P. Fleming
  1 sibling, 0 replies; 8+ messages in thread
From: Christoph Hellwig @ 2004-05-14 18:51 UTC (permalink / raw)
  To: Greg KH; +Cc: Norberto Bensa, linux-kernel

On Fri, May 14, 2004 at 11:46:59AM -0700, Greg KH wrote:
> How did this work with devfs then?  The device node would not be present
> before the ioctl needed to be called, right?  Or did it do the "magic
> lookup" mess and just "know" about md devices?

md uses blk_register_region to get a callback for it's dev_t region without
a registered gendisk, and also creates devfs entries before the gendisk
is registered.  It's a single big mess.


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: does udev support sw raid0?
  2004-05-14 18:46     ` Greg KH
  2004-05-14 18:51       ` Christoph Hellwig
@ 2004-05-14 19:10       ` Kevin P. Fleming
  1 sibling, 0 replies; 8+ messages in thread
From: Kevin P. Fleming @ 2004-05-14 19:10 UTC (permalink / raw)
  To: Greg KH; +Cc: Christoph Hellwig, Norberto Bensa, linux-kernel

Greg KH wrote:

> How did this work with devfs then?  The device node would not be present
> before the ioctl needed to be called, right?  Or did it do the "magic
> lookup" mess and just "know" about md devices?

Right, see my recent thread on linux-hotplug-devel about this very subject.

As it stands today, the only gendisk that md registers without being 
asked to do so is md0, so /dev/md0 will always be present on a 
udev-enabled system with md. If you have auto-start MD arrays on your 
system, then those will be registered as well when md autostarts them at 
kernel boot time.

All other arrays (those that you want to start using mdadm, or those 
that you want to create because they've never existing before) suffer 
from the problem of requiring a device node before they can be controlled.

I chatted with Neil Brown about this, and he would not be opposed to the 
md driver exposing a character device specifically for the purpose of 
handling the md ioctls (like dm does), but when I looked more into it it 
seemed to be a waste of effort; the time could be better spent porting 
the md personalities over to dm, where all this stuff already works 
properly and there is naming/splitting/partitioning/etc. available.

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2004-05-14 19:10 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-05-14 17:42 does udev support sw raid0? Norberto Bensa
2004-05-14 18:34 ` Greg KH
2004-05-14 18:39   ` Christoph Hellwig
2004-05-14 18:46     ` Greg KH
2004-05-14 18:51       ` Christoph Hellwig
2004-05-14 19:10       ` Kevin P. Fleming
2004-05-14 18:50     ` Norberto Bensa
2004-05-14 18:48   ` Norberto Bensa

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).