]> git.baikalelectronics.ru Git - kernel.git/commit
kbuild: support loading extra symbols in modpost
authorRichard Hacker <lerichi@gmx.net>
Thu, 28 Feb 2008 08:40:52 +0000 (09:40 +0100)
committerSam Ravnborg <sam@uranus.ravnborg.org>
Fri, 25 Apr 2008 18:35:47 +0000 (20:35 +0200)
commitd97e842ef754ee3901e492277552bb45d5ece597
tree10d94ee815e7c98f40bb8a1c24813c7fb6c3ae64
parent65a85b2fd1434294df0ab5ce0f95785e4cf8e527
kbuild: support loading extra symbols in modpost

This patch adds a new command line option -E to modpost, expecting a symbol
file as an argument which is read prior to symbol processing. -E can be
supplied multiple times for as many files as is needed.

When building kernel modules that depend on other modules not in the main
kernel tree, modpost complains about undefined symbols:
# make -C /path/to/linux/kernel M=/path/to/my/module
...
Building modules, stage 2.
....
WARNING: "rt_copy_buf" [/home/rich/osc_etl_rtw/osc_kmod.ko] undefined!
...etc

This situation occurs when modpost processes the new module's symbols. When
it finds symbols not exported by the mainline kernel, it issues this warning.

The patch adds a new command line option -e to modpost which expects a symbol
file as an argument. The symbols listed in this file are added to modpost's
symbol tables during startup. -e can be supplied as often as required.

This patch works together with the second patch. It introduces a new make
variable, KBUILD_EXTRA_SYMBOLS, which is used when calling modpost.

Signed-off-by: Richard Hacker <lerichi@gmx.net>
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
scripts/mod/modpost.c