Auto load of kernel modules on startup and on-demand?

Marcus Crafter crafterm at managesoft.com
Fri Dec 23 17:13:42 UTC 2005


Hi Rob,

Thanks for your response.

On 17/12/2005, at 2:15 AM, Rob Landley wrote:

> On Friday 16 December 2005 08:59, Marcus Crafter wrote:
>> Hi All,
>>
>> Hope all is going well.
>>
>> How do people usually handle automatic loading of kernel modules  
>> in an
>> uclibc environment created with buildroot?
>>
>> Does everyone build kerneld from modutils for 2.4.xx kernels and rely
>> on it to autoload each module as required? or does busybox offer
>> something like that?
>
> Busybox just grew a micro-udev implementation (mdev), and I'm working
> on /etc/mdev.conf support for that now.  We aren't handling module  
> loading
> yet, but if that information does appear in sysfs I can see about  
> adding an
> option.  (Or possibly a separate applet to call in the hotplug  
> script before
> calling mdev...)
>
>> Is there also something like an /etc/modules to force loads of  
>> certain
>> modules as well within buildroot?
>>
>> Any thoughts/recommendations?
>
> If you want to force a module to load, what's wrong with calling  
> insmod from
> your init scripts?
>
> I need a clearer idea of your requirements.

Well, what I'm looking for is support for 2 scenarios:

1. Equivalent of /etc/modules (ie. put in the name of the modules  
you'd like to load at boot time always, each line in /etc/modules is  
modprobe'd).  This could be done as you describe above, I was just  
wondering if it was built into buildroot/busybox somehow already (eg.  
through another file or some other method).


2. Automatic load of modules for devices detected at boot time that  
might be for optional hardware, drivers, etc. As far as I understand  
kerneld (or similar daemons) do this on usual Linux systems to auto- 
load modules at runtime. eg. pcnet32 isn't loaded by default under  
VMware even though there's a network card device available. If  
there's something that supports this in buildroot/busybox by default,  
that would be great - if not, I'm just wondering how people handle it  
(if at all?) in their buildroot environments.

Hope this makes things a bit more clearer.

Cheers,

Marcus





More information about the uClibc mailing list