Re: [PATCH 1/1] mm/kasan: avoid export __kasan_kmalloc
From: Zhu Yanjun <zyjzyj2000@gmail.com>
Date: 2021-09-30 11:13:40
On Thu, Sep 30, 2021 at 2:20 PM Marco Elver [off-list ref] wrote:
On Thu, Sep 30, 2021 at 03:50AM +0000, yanjun.zhu@linux.dev wrote:quoted
quoted
quoted
-EXPORT_SYMBOL(__kasan_kmalloc); Sorry, but this will break all users of kmalloc() with KASAN on if !TRACING:*module users. An allmodconfig but with CONFIG_TRACING=n will probably show you the problem.Follow your advice, I changed CONFIG_TRACING=n in .config. Then I run "make -jxx modules". But CONFIG_TRACING is changed to y. So what you mentioned does not appear.CONFIG_TRACING is not user selectable but auto-selected, just have to disable all those that select it. See .config, which breaks.
Sorry. I did not find .config in the attachment just now.
Now I made tests with this .config.
I made tests in RHEL84. The followings are steps:
1. git pull
2. make olddefconfig
3. make -j xx modules
Then the followings appear
"
WARNING: Symbol version dump "vmlinux.symvers" is missing.
Modules may not have dependencies or modversions.
You may get many unresolved symbol warnings.
MODPOST modules-only.symvers
WARNING: modpost: "__asan_register_globals"
[net/ipv4/netfilter/iptable_nat.ko] undefined!
WARNING: modpost: "__asan_unregister_globals"
[net/ipv4/netfilter/iptable_nat.ko] undefined!
WARNING: modpost: "unregister_pernet_subsys"
[net/ipv4/netfilter/iptable_nat.ko] undefined!
WARNING: modpost: "xt_unregister_template"
[net/ipv4/netfilter/iptable_nat.ko] undefined!
WARNING: modpost: "register_pernet_subsys"
[net/ipv4/netfilter/iptable_nat.ko] undefined!
WARNING: modpost: "xt_register_template"
[net/ipv4/netfilter/iptable_nat.ko] undefined!
WARNING: modpost: "ipt_do_table" [net/ipv4/netfilter/iptable_nat.ko] undefined!
WARNING: modpost: "__asan_report_store8_noabort"
[net/ipv4/netfilter/iptable_nat.ko] undefined!
WARNING: modpost: "nf_nat_ipv4_register_fn"
[net/ipv4/netfilter/iptable_nat.ko] undefined!
WARNING: modpost: "kmemdup" [net/ipv4/netfilter/iptable_nat.ko] undefined!
WARNING: modpost: suppressed 1754 unresolved symbol warnings because
there were too many)
"
And the .config is in the attachment.
Any other methods to make what you mentioned appear?
Zhu Yanjun Attachments
- config [application/octet-stream] 132311 bytes