On Sun, 2003-09-28 at 22:36, Bill Nottingham wrote:
Stephen Moore (stephen(a)skmoore.com) said:
> How do you get ACPI modules like ac and barrerty to load at boot time?
Add them to /etc/rc.modules, /etc/rc.local, write your own init script,
etc. Code will be added to do this in rc.sysinit in the next build of
initscripts.
I added the following to my rc.local so that I can load modules from
either 2.4 or 2.6:
kern_maj_ver=`/bin/uname -r | /bin/awk -F. '{print $2}'`
kern_ver=`/bin/uname -r`
if [ "$kern_maj_ver" = "6" ]
then
/sbin/insmod /lib/modules/$kern_ver/kernel/drivers/acpi/battery.ko
/sbin/insmod /lib/modules/$kern_ver/kernel/drivers/acpi/processor.ko
/sbin/insmod /lib/modules/$kern_ver/kernel/drivers/acpi/thermal.ko
/sbin/insmod /lib/modules/$kern_ver/kernel/drivers/acpi/ac.ko
fi
if [ "$kern_maj_ver" = "4" ]
then
/sbin/insmod ac
/sbin/insmod battery
/sbin/insmod fan
/sbin/insmod processor
/sbin/insmod thermal
fi
Thinking about it further, I was going to write an initscript that
detected whether acpi=on was passed to the kernel via grub and then load
the appropraite acpi modules for my system. I would think that an
initscript that could be turned off via chkconfig would be the best way
to go, but I'm not expert...
-josh
--
Joshua Legbandt <jtlegbandt(a)earthlink.net>