[PATCH RFC v3 5/8] rseq: add __always_inline for rseq_kernel_fields
Chen Linxuan via B4 Relay
devnull+chenlinxuan.uniontech.com at kernel.org
Mon Apr 28 21:06:09 PDT 2025
From: Chen Linxuan <chenlinxuan at uniontech.com>
Presume that kernel is compiled for x86_64 with gcc version 13.3.0:
make allmodconfig
make KCFLAGS="-fno-inline-small-functions -fno-inline-functions-called-once"
This results some objtool warnings:
vmlinux.o: warning: objtool: rseq_update_cpu_node_id+0x14c: call to rseq_kernel_fields() with UACCESS enabled
vmlinux.o: warning: objtool: rseq_reset_rseq_cpu_node_id+0xef: call to rseq_kernel_fields() with UACCESS enabled
Signed-off-by: Chen Linxuan <chenlinxuan at uniontech.com>
---
kernel/rseq.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/kernel/rseq.c b/kernel/rseq.c
index b7a1ec327e8117b47e353cab92d62111dd261520..7a4b6c211359714087a753047581bc8ff0c6c76b 100644
--- a/kernel/rseq.c
+++ b/kernel/rseq.c
@@ -27,7 +27,7 @@
RSEQ_CS_FLAG_NO_RESTART_ON_MIGRATE)
#ifdef CONFIG_DEBUG_RSEQ
-static struct rseq *rseq_kernel_fields(struct task_struct *t)
+static __always_inline struct rseq *rseq_kernel_fields(struct task_struct *t)
{
return (struct rseq *) t->rseq_fields;
}
--
2.43.0
More information about the Linux-nvme
mailing list