* How make modprobe find my kernel module?
@ 2011-09-02 15:12 Parmenides
2011-09-02 15:18 ` Dave Hylands
0 siblings, 1 reply; 3+ messages in thread
From: Parmenides @ 2011-09-02 15:12 UTC (permalink / raw)
To: kernelnewbies
Hi,
I have write a 'hello, world!' module which is in a directory
rather than the kernel source tree. I compiled it by:
make -C /usr/src/linux SUBDIRS=$PWD modules
and installed it by:
make -C /usr/src/linux SUBDIRS=$PWD modules_install
I find it was installed at /lib/modules/2.6.34/extra. Then, I invoked
modprobe hello.ko
to load this module, but get a message:
FATAL: Module hello.ko not found.
It seems that my module is not in the modprobe's search path. Is that
true? If so, how can I configure its search path?
^ permalink raw reply [flat|nested] 3+ messages in thread
* How make modprobe find my kernel module?
2011-09-02 15:12 How make modprobe find my kernel module? Parmenides
@ 2011-09-02 15:18 ` Dave Hylands
2011-09-03 3:33 ` Mulyadi Santosa
0 siblings, 1 reply; 3+ messages in thread
From: Dave Hylands @ 2011-09-02 15:18 UTC (permalink / raw)
To: kernelnewbies
Hi Parmenides,
On Fri, Sep 2, 2011 at 8:12 AM, Parmenides <mobile.parmenides@gmail.com> wrote:
> Hi,
>
> ? ?I have write a 'hello, world!' module which is in a directory
> rather than the kernel source tree. I compiled it by:
>
> ? ? ? ? ? ? ? ? ? ? ? make -C /usr/src/linux SUBDIRS=$PWD modules
>
> and installed it by:
>
> ? ? ? ? ? ? ? ? ? ? ? make -C /usr/src/linux SUBDIRS=$PWD modules_install
>
> I find it was installed at /lib/modules/2.6.34/extra. Then, I invoked
>
> ? ? ? ? ? ? ? ? ? ? ? ?modprobe hello.ko
>
> to load this module, but get a message:
>
> ? ? ? ? ? ? ? ? ? ? ? ?FATAL: Module hello.ko not found.
>
> It seems that my module is not in the modprobe's search path. Is that
> true? If so, how can I configure its search path?
modprobe uses modules.dep to translate module names into module
locations. You can either manually add an entry into that file - found
in /lib/modules/$(uname -r)
or you can rerun depmod on your device (if its available).
Alternatively, you can insmod your module bu providing a fully
qualified path to the .ko file. insmod doesn't do any dependancy
checking, so it just fails if you need symbols from some other module
which isn't loaded.
--
Dave Hylands
Shuswap, BC, Canada
http://www.davehylands.com
^ permalink raw reply [flat|nested] 3+ messages in thread
* How make modprobe find my kernel module?
2011-09-02 15:18 ` Dave Hylands
@ 2011-09-03 3:33 ` Mulyadi Santosa
0 siblings, 0 replies; 3+ messages in thread
From: Mulyadi Santosa @ 2011-09-03 3:33 UTC (permalink / raw)
To: kernelnewbies
Hi all..
On 02/09/2011, Dave Hylands <dhylands@gmail.com> wrote:
> or you can rerun depmod on your device (if its available).
I second that...... it is the easiest and the most straightforward way
to rebuild modules.dep.
--
regards,
Mulyadi Santosa
Freelance Linux trainer and consultant
blog: the-hydra.blogspot.com
training: mulyaditraining.blogspot.com
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2011-09-03 3:33 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-09-02 15:12 How make modprobe find my kernel module? Parmenides
2011-09-02 15:18 ` Dave Hylands
2011-09-03 3:33 ` Mulyadi Santosa
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.