[PATCH v6 19/25] powerpc: Remove high-order word clearing on compat syscall entry

Rohan McLure rmclure at linux.ibm.com
Wed Sep 21 16:55:59 AEST 2022


Remove explicit clearing of the high order-word of user parameters when
handling compatibility syscalls in system_call_exception. The
COMPAT_SYSCALL_DEFINEx macros handle this clearing through an
explicit cast to the signature type of the target handler.

Signed-off-by: Rohan McLure <rmclure at linux.ibm.com>
Reported-by: Nicholas Piggin <npiggin at gmail.com>
---
V6: New patch
---
 arch/powerpc/kernel/syscall.c | 8 --------
 1 file changed, 8 deletions(-)

diff --git a/arch/powerpc/kernel/syscall.c b/arch/powerpc/kernel/syscall.c
index 9875486f6168..15af0ed019a7 100644
--- a/arch/powerpc/kernel/syscall.c
+++ b/arch/powerpc/kernel/syscall.c
@@ -157,14 +157,6 @@ notrace long system_call_exception(long r3, long r4, long r5,
 
 	if (unlikely(is_compat_task())) {
 		f = (void *)compat_sys_call_table[r0];
-
-		r3 &= 0x00000000ffffffffULL;
-		r4 &= 0x00000000ffffffffULL;
-		r5 &= 0x00000000ffffffffULL;
-		r6 &= 0x00000000ffffffffULL;
-		r7 &= 0x00000000ffffffffULL;
-		r8 &= 0x00000000ffffffffULL;
-
 	} else {
 		f = (void *)sys_call_table[r0];
 	}
-- 
2.34.1



More information about the Linuxppc-dev mailing list