summaryrefslogtreecommitdiffstats
path: root/arch/powerpc/include/asm/unistd.h
diff options
context:
space:
mode:
authorMichael Ellerman <mpe@ellerman.id.au>2015-03-28 21:35:16 +1100
committerMichael Ellerman <mpe@ellerman.id.au>2015-03-28 22:03:40 +1100
commit529d235a0e190ded1d21ccc80a73e625ebcad09b (patch)
treec807f7526f29b79a7ce0b233daf8a1c3030d8dd0 /arch/powerpc/include/asm/unistd.h
parentc03e73740d24fbe990291cd9ac2d6ae0d95b975f (diff)
downloadop-kernel-dev-529d235a0e190ded1d21ccc80a73e625ebcad09b.zip
op-kernel-dev-529d235a0e190ded1d21ccc80a73e625ebcad09b.tar.gz
powerpc: Add a proper syscall for switching endianness
We currently have a "special" syscall for switching endianness. This is syscall number 0x1ebe, which is handled explicitly in the 64-bit syscall exception entry. That has a few problems, firstly the syscall number is outside of the usual range, which confuses various tools. For example strace doesn't recognise the syscall at all. Secondly it's handled explicitly as a special case in the syscall exception entry, which is complicated enough without it. As a first step toward removing the special syscall, we need to add a regular syscall that implements the same functionality. The logic is simple, it simply toggles the MSR_LE bit in the userspace MSR. This is the same as the special syscall, with the caveat that the special syscall clobbers fewer registers. This version clobbers r9-r12, XER, CTR, and CR0-1,5-7. Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Diffstat (limited to 'arch/powerpc/include/asm/unistd.h')
-rw-r--r--arch/powerpc/include/asm/unistd.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/powerpc/include/asm/unistd.h b/arch/powerpc/include/asm/unistd.h
index 36b79c3..f4f8b66 100644
--- a/arch/powerpc/include/asm/unistd.h
+++ b/arch/powerpc/include/asm/unistd.h
@@ -12,7 +12,7 @@
#include <uapi/asm/unistd.h>
-#define __NR_syscalls 363
+#define __NR_syscalls 364
#define __NR__exit __NR_exit
#define NR_syscalls __NR_syscalls
OpenPOWER on IntegriCloud