summaryrefslogtreecommitdiff
path: root/Documentation
diff options
context:
space:
mode:
authorMasahiro Yamada <masahiroy@kernel.org>2021-03-26 03:54:09 +0900
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2021-05-19 10:56:20 +0200
commit2c1cfecc94d09e61265a2118d6980c1d0b4bfc8a (patch)
tree01079818ad26d42d29743c3697decc97a9b64d2d /Documentation
parentd3f0131b86a9a016eb1577d556f540097675f1a5 (diff)
downloadlinux-2c1cfecc94d09e61265a2118d6980c1d0b4bfc8a.tar.gz
linux-2c1cfecc94d09e61265a2118d6980c1d0b4bfc8a.tar.bz2
linux-2c1cfecc94d09e61265a2118d6980c1d0b4bfc8a.zip
kbuild: generate Module.symvers only when vmlinux exists
[ Upstream commit 69bc8d386aebbd91a6bb44b6d33f77c8dfa9ed8c ] The external module build shows the following warning if Module.symvers is missing in the kernel tree. WARNING: Symbol version dump "Module.symvers" is missing. Modules may not have dependencies or modversions. I think this is an important heads-up because the resulting modules may not work as expected. This happens when you did not build the entire kernel tree, for example, you might have prepared the minimal setups for external modules by 'make defconfig && make modules_preapre'. A problem is that 'make modules' creates Module.symvers even without vmlinux. In this case, that warning is suppressed since Module.symvers already exists in spite of its incomplete content. The incomplete (i.e. invalid) Module.symvers should not be created. This commit changes the second pass of modpost to dump symbols into modules-only.symvers. The final Module.symvers is created by concatenating vmlinux.symvers and modules-only.symvers if both exist. Module.symvers is supposed to collect symbols from both vmlinux and modules. It might be a bit confusing, and I am not quite sure if it is an official interface, but presumably it is difficult to rename it because some tools (e.g. kmod) parse it. Signed-off-by: Masahiro Yamada <masahiroy@kernel.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/dontdiff1
1 files changed, 1 insertions, 0 deletions
diff --git a/Documentation/dontdiff b/Documentation/dontdiff
index e361fc95ca29..82e3eee7363b 100644
--- a/Documentation/dontdiff
+++ b/Documentation/dontdiff
@@ -178,6 +178,7 @@ mktables
mktree
mkutf8data
modpost
+modules-only.symvers
modules.builtin
modules.builtin.modinfo
modules.nsdeps