Subject: Re: possible root devices?
To: der Mouse <mouse@Rodents.Montreal.QC.CA>
From: Jachym Holecek <freza@NetBSD.org>
List: tech-kern
Date: 08/27/2007 19:43:39
# der Mouse 2007-08-27:
> >> I'm working on my "root on cgd" stuff [and cgd0 doesn't show in the
> >> list from ? at "root device:"].
> > Are you sure there's a device_t corresponding to "cgd0"?
> 
> [... possibly seeing the same problem with 1.4T codebase ...]
> 
> What's the right fix here, have you any thoughts?  Should I create a
> pseudo bus as I did for 1.4T, or is there some way to get a device_t
> for cgd0 as a conventional pseudo-device?

The canonical way to attach a pseudo device is via config_attach_pseudo(),
you could either make cgd(4) call it directly or investigate callers
of pseudo_disk_attach() and see if it makes sense to attach a pseudo
device from therein (I'm not familiar with the disk code, so this
is just an idea of handling all pseudo-disks in one shot).

	-- Jachym