Saturday, April 27, 2024
 Popular · Latest · Hot · Upcoming
22
rated 0 times [  22] [ 0]  / answers: 1 / hits: 61203  / 2 Years ago, sun, june 12, 2022, 7:40:26

How to add a kernel module parameter in Ubuntu 11.04?



Can I use the /etc/module file? If yes, how?


More From » 11.04

 Answers
5

/etc/modules seems to be loaded by /etc/init/module-init-tools.conf. The first argument is the module name, other arguments are the parameters. Adding the following to /etc/modules seems fine:



thinkpad_acpi fan_control=1


To load this module and set these parameters in the very early stage of boot, add the previous line to /etc/initramfs-tools/modules file. After a change in that file, you need to regenerate the ramdisk:



sudo update-initramfs -u


As a possible alternative, you can try to add the options to the kernel line (I haven't tested it myself, but it seems to work for settings like i915.modeset=1. Edit /etc/default/grub and find the line with GRUB_CMDLINE_LINUX_DEFAULT="quiet splash". Replace it by something like:



GRUB_CMDLINE_LINUX_DEFAULT="quiet splash thinkpad_acpi.fan_control=1"


To get a list of options for a kernel module:



modinfo -p thinkpad_acpi


This did not work for i915, for that I had to run:



modinfo i915 | grep ^parm


To get the current value of a module parameter, run:



sudo cat /sys/module/MODULE/parameters/PARAM


For the fan_control parameter of the thinkpad_acpi module, you have to run:



sudo cat /sys/module/thinkpad_acpi/parameters/fan_control


If this function returns an error, check if the module was loaded and whether the option exist or not.


[#44392] Monday, June 13, 2022, 2 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
iething

Total Points: 49
Total Questions: 127
Total Answers: 112

Location: Luxembourg
Member since Tue, Jan 25, 2022
2 Years ago
;