Re: [PATCH] powerpc: Wire up clone3 syscall
From: Arseny Solokha
Date: Wed Jul 24 2019 - 01:25:24 EST
Hi,
may I also ask to provide ppc_clone3 symbol also for 32-bit powerpc? Otherwise
Michael's patch breaks build for me:
powerpc-e500v2-linux-gnuspe-ld: arch/powerpc/kernel/systbl.o: in function `sys_call_table':
(.rodata+0x6cc): undefined reference to `ppc_clone3'
make: *** [Makefile:1060: vmlinux] Error 1
The patch was tested using Christian's program on a real e500 machine.
--- a/arch/powerpc/kernel/entry_32.S
+++ b/arch/powerpc/kernel/entry_32.S
@@ -597,6 +597,14 @@ ppc_clone:
stw r0,_TRAP(r1) /* register set saved */
b sys_clone
+ .globl ppc_clone3
+ppc_clone3:
+ SAVE_NVGPRS(r1)
+ lwz r0,_TRAP(r1)
+ rlwinm r0,r0,0,0,30 /* clear LSB to indicate full */
+ stw r0,_TRAP(r1) /* register set saved */
+ b sys_clone3
+
.globl ppc_swapcontext
ppc_swapcontext:
SAVE_NVGPRS(r1)
I don't think this trivial hunk deserves a separate patch submission.
Thanks,
Arseny