Skip to contentSkip to conversation

linux-next: build warning after merge of the tip tree

DISCUSSION Stephen Rothwell 2 participants 2 messages Oct 24, 2022

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

Hi all,

After merging the tip tree, today's linux-next build (x86_64 allmodconfig) produced this warning:

vmlinux.o: warning: objtool: get_cpu_entry_area+0x4: call to cea_offset() leaves .noinstr.text section

Presumably something to do with commit

1248fb6a8201 ("x86/mm: Randomize per-cpu entry area")

Signature · 2 lines
Cheers,
Stephen Rothwell
maintainer
#1 lore raw
Quoted 10 lines · Stephen Rothwell

Hi all,

After merging the tip tree, today's linux-next build (x86_64 allmodconfig) produced this warning:

vmlinux.o: warning: objtool: get_cpu_entry_area+0x4: call to cea_offset() leaves .noinstr.text section

Presumably something to do with commit

1248fb6a8201 ("x86/mm: Randomize per-cpu entry area")

Thanks, and yesh Boris said the same late on Friday... all the *SAN stuff tickled the compiler's stupid bone again.

The below cures it, Dave, do we fold it in or mash on top?

arch/x86/mm/cpu_entry_area.c +2 -2
index ad1f750517a1..a8f18e613190 100644
@@ -18,7 +18,7 @@ DEFINE_PER_CPU(struct cea_exception_stacks*, cea_exception_stacks);
 
 static DEFINE_PER_CPU_READ_MOSTLY(unsigned long, _cea_offset);
 
-static inline unsigned int cea_offset(unsigned int cpu)
+static __always_inline unsigned int cea_offset(unsigned int cpu)
 {
 	return per_cpu(_cea_offset, cpu);
 }
@@ -52,7 +52,7 @@ static __init void init_cea_offsets(void)
 #else /* !X86_64 */
 DECLARE_PER_CPU_PAGE_ALIGNED(struct doublefault_stack, doublefault_stack);
 
-static inline unsigned int cea_offset(unsigned int cpu)
+static __always_inline unsigned int cea_offset(unsigned int cpu)
 {
 	return cpu;
 }