Messages in this thread | | | From | "Adam J. Richter" <> | Date | Tue, 14 Apr 1998 12:24:48 -0700 | Subject | Re: Testers wanted: exorcised kmod.c: no more daemon! |
| |
Greg Zornetzer <gaz+@andrew.cmu.edu> writes: >so during this whole kmod fix process, I was thinking about problems of >extending kmod so that it's a more flexible interface between the kernel & >userspace. When I was looking through the kerneld code and saw the cute >things like replacing a beep with running a sound player, executing screen >savers instead of a screen blank, etc, I was thinking that instead of >request_module invoking /sbin/modprobe directly, it invokes a wrapper that >will call modprobe for the general case, but can be used for other tasks >also (even request_route, although as people have pointed out, >request_route is buggy at best). > >Lets take the example of the mixer settings not saved problem. >If we could make a system where the mixer settings are made available by >sysctl, we could have a program that gets called via request_module in >init_module and cleanup_module that restores and saves mixer settings from >one module invokation to the next. Most of the work is in userspace, the >kernel just tells userspace when to do its thing.
As everyone on this mailing list seems to agree, there needs to be a user level method for reading the mixer settings before the module is removed. As far as the kmod/modprobe support goes, that is already present. Just add lines like the following to /etc/conf.modules:
pre-remove sound /usr/bin/save_mixer_settings post-install sound /usr/bin/restore_mixer_settings
If you want to do something more exotic, you can change the program that request_module invokes (under all the versions of kmod) by writing to /proc/sys/kernel/modprobe.
-- Adam J. Richter __ ______________ 4880 Stevens Creek Blvd, Suite 205 adam@yggdrasil.com \ / San Jose, California 95129-1034 +1 408 261-6630 | g g d r a s i l United States of America fax +1 408 261-6631 "Free Software For The Rest Of Us."
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu
| |