History

modpost: Allow extended modversions without basic MODVERSIONS

If you know that your kernel modules will only ever be loaded by a newer kernel, you can disable BASIC_MODVERSIONS to save space. This also allows easy creation of test modules to see how tooling will respond to modules that only have the new format.

Matthew Maurer committed 1 year ago

Commit e8639b71 parent fc7d5e33 files · +23 −2Browse files

Showing the changes to kernel/module (1 of 3 files). Show all

Unified · Split

kernel/module/Kconfig+15−0
@@ -217,6 +217,21 @@ config EXTENDED_MODVERSIONS · 216 unmodified lines
217217 The most likely reason you would enable this is to enable Rust
218218 support. If unsure, say N.
219219
220+config BASIC_MODVERSIONS
221+ bool "Basic Module Versioning Support"
222+ depends on MODVERSIONS
223+ default y
224+ help
225+ This enables basic MODVERSIONS support, allowing older tools or
226+ kernels to potentially load modules.
227+
228+ Disabling this may cause older `modprobe` or `kmod` to be unable
229+ to read MODVERSIONS information from built modules. With this
230+ disabled, older kernels may treat this module as unversioned.
231+
232+ This is enabled by default when MODVERSIONS are enabled.
233+ If unsure, say Y.
234+
220235 config MODULE_SRCVERSION_ALL
221236 bool "Source checksum for all modules"
222237 help