- From: Andreas Leuner <al14_at_inf.tu-dresden.de>
- Date: Tue, 1 Mar 2005 17:06:35 +0100 (CET)
> How can 'modprobe' be made aware that RTAI's modules are in
> /usr/realtime/modules?
The following is an "amendment" to the module search path:
#---------------------------------------------------
#for RTAI
if `uname -r` == YOUR_KERNEL_NAME
path=/lib/modules/`uname -r`
path=RTAI_DIR/modules
endif
#---------------------------------------------------
Replace YOUR_KERNEL_NAME with the output of "uname -r" with your adeos
enhanced kernel running and RTAI_DIR with the path to your rtai
installation, /usr/realtime in your case.
If (you run Debian Sarge, and maybe older)
{
add the "amendment" to /etc/modutils/paths, and
run (as root) "update-modules"
}
else
{
add the "amendment" to /etc/modules.conf
}
Then run (as root) "depmod -ae". This creates a file
/lib/modules/YOUR_KERNEL_NAME/modules.dep where modprobe will take
information about module dependencies from. Then it will not only know
where rtai_hal.(k)o is placed, but also that e.g. module comedi.(k)o
depends on rtai_hal.(k)o and where both are installed.
Now you won't have to do
modprobe rtai_hal
modprobe comedi
but only
modprobe comedi
and both modules will be loaded. Or you could just modprobe your card
driver. Unloading with "modprobe -r comedi" will remove those modules
again.
> Isn't it, by default, just looking in "/lib/modules/`uname -r`"?
Yes. "/lib/modules/`uname -r`" is the standard search path. By amending it
you can make modprobe look in other places too. Be aware that if you add
any "path" statements to /etc/modules.conf you'll also have to add one for
the standard search path (just as in the fragment above) since it will no
longer be implied.
Have fun!
Andreas
Received on 2005-03-01Z16:06:35