mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-29 23:53:32 +00:00
ff09f6fd29
Trying to restrict the '$'-prefix change to RISC-V caused some fallout,
so let's just treat all those symbols as special.
Fixes: c05780ef3c
("module: Ignore RISC-V mapping symbols too")
Link: https://lore.kernel.org/all/20230712015747.77263-1-wangkefeng.wang@huawei.com/
Signed-off-by: Palmer Dabbelt <palmer@rivosinc.com>
Reviewed-by: Masahiro Yamada <masahiroy@kernel.org>
Signed-off-by: Luis Chamberlain <mcgrof@kernel.org>
15 lines
408 B
C
15 lines
408 B
C
/* SPDX-License-Identifier: GPL-2.0-only */
|
|
#ifndef _LINUX_MODULE_SYMBOL_H
|
|
#define _LINUX_MODULE_SYMBOL_H
|
|
|
|
/* This ignores the intensely annoying "mapping symbols" found in ELF files. */
|
|
static inline int is_mapping_symbol(const char *str)
|
|
{
|
|
if (str[0] == '.' && str[1] == 'L')
|
|
return true;
|
|
if (str[0] == 'L' && str[1] == '0')
|
|
return true;
|
|
return str[0] == '$';
|
|
}
|
|
|
|
#endif /* _LINUX_MODULE_SYMBOL_H */
|