amfc: fix symbols for erofs and sym_helper [1/2]

PD#SWPL-206286

Problem:
GKI symbol check failed

Solution:
1, import a new symbol help ko
2, fix symbols in erofs

Verify:
S7d

Change-Id: Ic996220ee53bb183a1a932b6f8c5284a4d71c805
Signed-off-by: Dezhen Wang <dezhen.wang@amlogic.com>
This commit is contained in:
Dezhen Wang
2025-04-07 05:51:16 +00:00
committed by gerrit autosubmit
parent 42d20d6224
commit 3989ba8fbf
+11 -5
View File
@@ -87,6 +87,8 @@ struct ksymbol {
unsigned int name_len;
};
int __symbol_fixed;
#ifdef CONFIG_ARM64
static struct ksymbol module_symbols[] = {
KSYM_FUN(xxh32),
@@ -138,8 +140,6 @@ static struct ksymbol module_symbols[] = {
{}
};
int __symbol_fixed;
/* see struct proc_dir_entry in fs/proc/internal.h */
struct proc_node {
/*
@@ -421,6 +421,10 @@ int symbol_fix(void)
}
#else
/* for arm32 */
#include <linux/xxhash.h>
#include <linux/psi.h>
#include <linux/posix_acl_xattr.h>
int symbol_fix(void)
{
/*--------- erofs symbols ----------*/
@@ -467,9 +471,9 @@ int symbol_fix(void)
FUN_ASSIGN(iov_iter_bvec);
FUN_ASSIGN(kmemdup_nul);
FUN_ASSIGN(memchr_inv);
OBJ_ASSIGN(dotdot_name);
OBJ_ASSIGN(nop_posix_acl_access);
OBJ_ASSIGN(nop_posix_acl_default);
dotdot_name_t = (struct qstr *)&dotdot_name;
nop_posix_acl_access_t = (struct xattr_handler *)&nop_posix_acl_access;
nop_posix_acl_default_t = (struct xattr_handler *)&nop_posix_acl_default;
__symbol_fixed = 1;
return 0;
@@ -506,7 +510,9 @@ int __init sym_helper_init(void)
void __exit sym_helper_exit(void)
{
__symbol_fixed = 0;
#ifdef CONFIG_ARM64
memset(module_symbols, 0, sizeof(module_symbols));
#endif
}
module_init(sym_helper_init);
module_exit(sym_helper_exit);