I have some questions concerning the /sys/module/ in linux
-
Does the
/sys/modulecontain all modules of kernel -
Does the
/sys/module/xxx/parameterscontains all parameters of the kernel module xxxx -
Does the
/sys/module/xxx/parameters/yyyycontain realtime values of the parameter yyyy of the kernel module xxxx -
if a parameter is changed in a giving kernel module, how to detect this change in RealTime? I want to develop a C application (user space) or a shell script which detect the change of a giving kernel module parameter in real time.
Parameters are input values and not state values. You can not change a parameter after the recipient of the parameter has started.
If you want to change the behavior of the kernel at run time you have to use /proc/sys. See here: http://tournasdimitrios1.wordpress.com/2011/02/07/passing-parameters-to-the-kernel-at-run-time-time-on-linux/