tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Autoloading of pseudo-device modules



Adam Hamsik writes:
> 
> Hi folks,
> 
> Because dm driver is not enabled in kernel yet, and it is installed as  
> new style module.
> I have written this small patch [1] to subr_devsw.c which enable auto- 
> loading of pseudo-device
> drivers. In my patch I'm changing cdev_open/bdev_open routines to try  
> to load module if they
> was not able to look up it.
> 
> I have also converted some of our well known pseudo-drivers to modules  
> so we can remove them from kernel.
> [2], [3], [4]. I don't have cgd or raidframe* setup but I will test it  
> more.
> 
> There is one outstanding problem with loading device drivers which  
> need argument in kernel
> config file e.g. pseudo-device cgd 4, I do not know how to pass this  
> number to modcmd function
> which calls driver attach routine. With removing these drivers from  
> kernel we can shrink it by
> 200k.
> 
> * I'm really not sure if raid diff is ok because radiframe code is  
> hard to understand.

The RAIDframe code has a number of issues which will require fixing 
before it can become a module... For example, raidattach() is only 
designed to be called exactly once, and then only very early on in 
the boot process...  As well, this code is expected to have been run 
before any particular RAID device is configured...  

I know nothing about the module stuff, but perhaps between the two of 
us we can turn RAIDframe into a module too :)

Later...

Greg Oster




Home | Main Index | Thread Index | Old Index