mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-16 06:41:39 -04:00
parisc: Avoid compat syscalls when COMPAT=n
Drop unnecessary code and syscall tables when we run a 64-bit kernel with conpat mode disabled. Signed-off-by: Helge Deller <deller@gmx.de>
This commit is contained in:
@@ -241,7 +241,7 @@ linux_gateway_entry:
|
||||
/* Note! We cannot use the syscall table that is mapped
|
||||
nearby since the gateway page is mapped execute-only. */
|
||||
|
||||
#ifdef CONFIG_64BIT
|
||||
#ifdef CONFIG_COMPAT
|
||||
ldil L%sys_call_table, %r1
|
||||
or,ev %r2,%r2,%r2
|
||||
ldil L%sys_call_table64, %r1
|
||||
@@ -250,7 +250,7 @@ linux_gateway_entry:
|
||||
ldo R%sys_call_table64(%r1), %r19
|
||||
#else
|
||||
load32 sys_call_table, %r19
|
||||
#endif
|
||||
#endif
|
||||
comiclr,>> __NR_Linux_syscalls, %r20, %r0
|
||||
b,n .Lsyscall_nosys
|
||||
|
||||
@@ -374,7 +374,7 @@ tracesys_next:
|
||||
/* Note! We cannot use the syscall table that is mapped
|
||||
nearby since the gateway page is mapped execute-only. */
|
||||
|
||||
#ifdef CONFIG_64BIT
|
||||
#ifdef CONFIG_COMPAT
|
||||
LDREG TASK_PT_GR30(%r1), %r19 /* get users sp back */
|
||||
extrd,u %r19,63,1,%r2 /* W hidden in bottom bit */
|
||||
|
||||
@@ -1326,16 +1326,19 @@ ENTRY(lws_table)
|
||||
END(lws_table)
|
||||
/* End of lws table */
|
||||
|
||||
#ifdef CONFIG_64BIT
|
||||
#ifdef CONFIG_COMPAT
|
||||
#define __SYSCALL_WITH_COMPAT(nr, native, compat) __SYSCALL(nr, compat)
|
||||
#else
|
||||
#define __SYSCALL_WITH_COMPAT(nr, native, compat) __SYSCALL(nr, native)
|
||||
#endif
|
||||
#define __SYSCALL(nr, entry) ASM_ULONG_INSN entry
|
||||
|
||||
.align 8
|
||||
ENTRY(sys_call_table)
|
||||
.export sys_call_table,data
|
||||
#if defined(CONFIG_COMPAT) || !defined(CONFIG_64BIT)
|
||||
#include <asm/syscall_table_32.h> /* 32-bit syscalls */
|
||||
#endif
|
||||
END(sys_call_table)
|
||||
|
||||
#ifdef CONFIG_64BIT
|
||||
|
||||
Reference in New Issue
Block a user