]> www.infradead.org Git - users/jedix/linux-maple.git/commit
rust: Use gendwarfksyms + extended modversions for CONFIG_MODVERSIONS
authorSami Tolvanen <samitolvanen@google.com>
Fri, 3 Jan 2025 17:37:05 +0000 (17:37 +0000)
committerMasahiro Yamada <masahiroy@kernel.org>
Fri, 17 Jan 2025 23:51:48 +0000 (08:51 +0900)
commitac61506bf2d1a6766d98b7d94b0c7b2134a0806a
tree2075c9bd881f8f8bff7aa1186775744fefe1b314
parent272f8a6d625a0cf7fba9c5af5202edc84dee326c
rust: Use gendwarfksyms + extended modversions for CONFIG_MODVERSIONS

Previously, two things stopped Rust from using MODVERSIONS:
1. Rust symbols are occasionally too long to be represented in the
   original versions table
2. Rust types cannot be properly hashed by the existing genksyms
   approach because:
* Looking up type definitions in Rust is more complex than C
* Type layout is potentially dependent on the compiler in Rust,
  not just the source type declaration.

CONFIG_EXTENDED_MODVERSIONS addresses the first point, and
CONFIG_GENDWARFKSYMS the second. If Rust wants to use MODVERSIONS, allow
it to do so by selecting both features.

Signed-off-by: Sami Tolvanen <samitolvanen@google.com>
Co-developed-by: Matthew Maurer <mmaurer@google.com>
Signed-off-by: Matthew Maurer <mmaurer@google.com>
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
init/Kconfig
rust/Makefile