Thanks so much for the information and sorry for not making myself clear.
The details are like this:
- modA.o needs to be loaded first and it will do some
work after been loaded. After the work is done,
- modB.o needs to be loaded.
Is there a system call, something like "load_another_lkm"? If there is one, then we can call it from modA after modA completes its works.
Thanks,
T.
"Curran, Dominic" <dcurran@ti.com> wrote:
I've never done this but I believe it works like this.Copy your LKM's to somewhere under the tree:/lib/modules/<version>where <version> is the current kernel version ('uname -r').Then run depmod.depmod should create the module dependency file. This determines interdependencies between LKM's.The module dependency file will live here:/lib/modules/<version>/modules.depThen load your modules using modprobe.Thus if modA.o depends on modB.oThen the command:# modprobe modA.o...should load modB.o and then modA.oI'm sure someone will correct me if I'm wrong.dom-----Original Message-----
From: kernelnewbies-bounce@nl.linux.org [mailto:kernelnewbies-bounce@nl.linux.org] On Behalf Of l x
Sent: Friday, May 14, 2004 5:43 PM
To: kernelnewbies@nl.linux.org
Subject: Help - how to let a module load another moduleHi,People usually use insmod to load a module from the command-line. How can we let a module load another module? Suppose we have module_a.o and module_b.o, how to code module_a, so running "insmod module_a.o" will cause module_b.o loaded.Thanks,T.
Do you Yahoo!?
SBC Yahoo! - Internet access at a great low price.
Do you Yahoo!?
SBC Yahoo! - Internet access at a great low price.