Reunbreak the MEM_ENCRYPT build
Current top of tree doesn't build for me:
../arch/x86/include/asm/mem_encrypt.h:23:20: error: static declaration of ‘mem_encrypt_init’ follows non-static declaration
23 | static inline void mem_encrypt_init(void) { }
| ^~~~~~~~~~~~~~~~
In file included from ../include/linux/printk.h:6,
from ../include/linux/kernel.h:30,
from ../arch/x86/include/asm/percpu.h:27,
from ../arch/x86/include/asm/preempt.h:6:
../include/linux/init.h:158:6: note: previous declaration of ‘mem_encrypt_init’ with type ‘void(void)’
158 | void mem_encrypt_init(void);
| ^~~~~~~~~~~~~~~~I applied this locally:
include/linux/init.h +0 -1
@@ -155,7 +155,6 @@ void __init init_rootfs(void);void init_IRQ (void );void time_init (void ); -void mem_encrypt_init (void );void poking_init (void );void pgtable_cache_init (void );
Probably this is the wrong fix.
Quoted 2 lines · Matthew Wilcox
Probably this is the wrong fix.
No, that looks like the obviously correct fix, I just don't see how we all missed that stale declaration.
I guess we all had X86_MEM_ENCRYPT enabled, which hides the problem. And other architectures wouldn't have had the issue.
Linus
Quoted 9 lines · Linus Torvalds
Quoted 2 lines · Matthew Wilcox
Probably this is the wrong fix.
No, that looks like the obviously correct fix, I just don't see how we all missed that stale declaration.
I guess we all had
X86_MEM_ENCRYPTenabled, which hides the problem. And other architectures wouldn't have had the issue.
Sigh. I'm sure that I fixed that before. No idea how I missed it in the final reference merge (again).
Sorry.
tglx
Hi Linus,
Quoted 10 lines · On Wed, 28 Jun 2023 12:52:24 -0700 Linus Torvalds…
Quoted 2 lines · Matthew Wilcox
Probably this is the wrong fix.
No, that looks like the obviously correct fix, I just don't see how we all missed that stale declaration.
I guess we all had
X86_MEM_ENCRYPTenabled, which hides the problem. And other architectures wouldn't have had the issue.
https://lore.kernel.org/all/[email protected]/
:-(
Signature · 2 lines
Cheers, Stephen Rothwell