Skip to content

Commit 0e446e3

Browse files
maurerojeda
authored andcommitted
rust: kbuild: do not export generated KASAN ODR symbols
ASAN generates special synthetic symbols to help check for ODR violations. These synthetic symbols lack debug information, so gendwarfksyms emits warnings when processing them. No code should ever have a dependency on these symbols, so we should not be exporting them, just like the __cfi symbols. Signed-off-by: Matthew Maurer <[email protected]> Reviewed-by: Alice Ryhl <[email protected]> Link: https://lore.kernel.org/r/[email protected] [ Fixed typo in commit message. Slightly reworded title. - Miguel ] Signed-off-by: Miguel Ojeda <[email protected]>
1 parent a9c621a commit 0e446e3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

rust/Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -332,7 +332,7 @@ $(obj)/bindings/bindings_helpers_generated.rs: private bindgen_target_extra = ;
332332
$(obj)/bindings/bindings_helpers_generated.rs: $(src)/helpers/helpers.c FORCE
333333
$(call if_changed_dep,bindgen)
334334

335-
rust_exports = $(NM) -p --defined-only $(1) | awk '$$2~/(T|R|D|B)/ && $$3!~/__cfi/ { printf $(2),$$3 }'
335+
rust_exports = $(NM) -p --defined-only $(1) | awk '$$2~/(T|R|D|B)/ && $$3!~/__cfi/ && $$3!~/__odr_asan/ { printf $(2),$$3 }'
336336

337337
quiet_cmd_exports = EXPORTS $@
338338
cmd_exports = \

0 commit comments

Comments
 (0)