Commit 347a8dc3 authored by Martin Schwidefsky's avatar Martin Schwidefsky Committed by Linus Torvalds
Browse files

[PATCH] s390: cleanup Kconfig



Sanitize some s390 Kconfig options.  We have ARCH_S390, ARCH_S390X,
ARCH_S390_31, 64BIT, S390_SUPPORT and COMPAT.  Replace these 6 options by
S390, 64BIT and COMPAT.
Signed-off-by: default avatarMartin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent 9bbc8346
...@@ -23,14 +23,14 @@ config GENERIC_BUST_SPINLOCK ...@@ -23,14 +23,14 @@ config GENERIC_BUST_SPINLOCK
mainmenu "Linux Kernel Configuration" mainmenu "Linux Kernel Configuration"
config ARCH_S390 config S390
bool bool
default y default y
config UID16 config UID16
bool bool
default y default y
depends on ARCH_S390X = 'n' depends on !64BIT
source "init/Kconfig" source "init/Kconfig"
...@@ -38,20 +38,12 @@ menu "Base setup" ...@@ -38,20 +38,12 @@ menu "Base setup"
comment "Processor type and features" comment "Processor type and features"
config ARCH_S390X config 64BIT
bool "64 bit kernel" bool "64 bit kernel"
help help
Select this option if you have a 64 bit IBM zSeries machine Select this option if you have a 64 bit IBM zSeries machine
and want to use the 64 bit addressing mode. and want to use the 64 bit addressing mode.
config 64BIT
def_bool ARCH_S390X
config ARCH_S390_31
bool
depends on ARCH_S390X = 'n'
default y
config SMP config SMP
bool "Symmetric multi-processing support" bool "Symmetric multi-processing support"
---help--- ---help---
...@@ -101,20 +93,15 @@ config MATHEMU ...@@ -101,20 +93,15 @@ config MATHEMU
on older S/390 machines. Say Y unless you know your machine doesn't on older S/390 machines. Say Y unless you know your machine doesn't
need this. need this.
config S390_SUPPORT config COMPAT
bool "Kernel support for 31 bit emulation" bool "Kernel support for 31 bit emulation"
depends on ARCH_S390X depends on 64BIT
help help
Select this option if you want to enable your system kernel to Select this option if you want to enable your system kernel to
handle system-calls from ELF binaries for 31 bit ESA. This option handle system-calls from ELF binaries for 31 bit ESA. This option
(and some other stuff like libraries and such) is needed for (and some other stuff like libraries and such) is needed for
executing 31 bit applications. It is safe to say "Y". executing 31 bit applications. It is safe to say "Y".
config COMPAT
bool
depends on S390_SUPPORT
default y
config SYSVIPC_COMPAT config SYSVIPC_COMPAT
bool bool
depends on COMPAT && SYSVIPC depends on COMPAT && SYSVIPC
...@@ -122,7 +109,7 @@ config SYSVIPC_COMPAT ...@@ -122,7 +109,7 @@ config SYSVIPC_COMPAT
config BINFMT_ELF32 config BINFMT_ELF32
tristate "Kernel support for 31 bit ELF binaries" tristate "Kernel support for 31 bit ELF binaries"
depends on S390_SUPPORT depends on COMPAT
help help
This allows you to run 32-bit Linux/ELF binaries on your zSeries This allows you to run 32-bit Linux/ELF binaries on your zSeries
in 64 bit mode. Everybody wants this; say Y. in 64 bit mode. Everybody wants this; say Y.
...@@ -135,7 +122,7 @@ choice ...@@ -135,7 +122,7 @@ choice
config MARCH_G5 config MARCH_G5
bool "S/390 model G5 and G6" bool "S/390 model G5 and G6"
depends on ARCH_S390_31 depends on !64BIT
help help
Select this to build a 31 bit kernel that works Select this to build a 31 bit kernel that works
on all S/390 and zSeries machines. on all S/390 and zSeries machines.
......
...@@ -13,16 +13,14 @@ ...@@ -13,16 +13,14 @@
# Copyright (C) 1994 by Linus Torvalds # Copyright (C) 1994 by Linus Torvalds
# #
ifdef CONFIG_ARCH_S390_31 ifndef CONFIG_64BIT
LDFLAGS := -m elf_s390 LDFLAGS := -m elf_s390
CFLAGS += -m31 CFLAGS += -m31
AFLAGS += -m31 AFLAGS += -m31
UTS_MACHINE := s390 UTS_MACHINE := s390
STACK_SIZE := 8192 STACK_SIZE := 8192
CHECKFLAGS += -D__s390__ CHECKFLAGS += -D__s390__
endif else
ifdef CONFIG_ARCH_S390X
LDFLAGS := -m elf64_s390 LDFLAGS := -m elf64_s390
MODFLAGS += -fpic -D__PIC__ MODFLAGS += -fpic -D__PIC__
CFLAGS += -m64 CFLAGS += -m64
......
...@@ -40,7 +40,7 @@ ...@@ -40,7 +40,7 @@
#define TOD_MICRO 0x01000 /* nr. of TOD clock units #define TOD_MICRO 0x01000 /* nr. of TOD clock units
for 1 microsecond */ for 1 microsecond */
#ifndef CONFIG_ARCH_S390X #ifndef CONFIG_64BIT
#define APPLDATA_START_INTERVAL_REC 0x00 /* Function codes for */ #define APPLDATA_START_INTERVAL_REC 0x00 /* Function codes for */
#define APPLDATA_STOP_REC 0x01 /* DIAG 0xDC */ #define APPLDATA_STOP_REC 0x01 /* DIAG 0xDC */
...@@ -54,13 +54,13 @@ ...@@ -54,13 +54,13 @@
#define APPLDATA_GEN_EVENT_RECORD 0x82 #define APPLDATA_GEN_EVENT_RECORD 0x82
#define APPLDATA_START_CONFIG_REC 0x83 #define APPLDATA_START_CONFIG_REC 0x83
#endif /* CONFIG_ARCH_S390X */ #endif /* CONFIG_64BIT */
/* /*
* Parameter list for DIAGNOSE X'DC' * Parameter list for DIAGNOSE X'DC'
*/ */
#ifndef CONFIG_ARCH_S390X #ifndef CONFIG_64BIT
struct appldata_parameter_list { struct appldata_parameter_list {
u16 diag; /* The DIAGNOSE code X'00DC' */ u16 diag; /* The DIAGNOSE code X'00DC' */
u8 function; /* The function code for the DIAGNOSE */ u8 function; /* The function code for the DIAGNOSE */
...@@ -82,7 +82,7 @@ struct appldata_parameter_list { ...@@ -82,7 +82,7 @@ struct appldata_parameter_list {
u64 product_id_addr; u64 product_id_addr;
u64 buffer_addr; u64 buffer_addr;
}; };
#endif /* CONFIG_ARCH_S390X */ #endif /* CONFIG_64BIT */
/* /*
* /proc entries (sysctl) * /proc entries (sysctl)
......
...@@ -112,7 +112,7 @@ struct crypt_s390_query_status { ...@@ -112,7 +112,7 @@ struct crypt_s390_query_status {
* [ret] is the variable to receive the error code * [ret] is the variable to receive the error code
* [ERR] is the error code value * [ERR] is the error code value
*/ */
#ifndef __s390x__ #ifndef CONFIG_64BIT
#define __crypt_s390_fixup \ #define __crypt_s390_fixup \
".section .fixup,\"ax\" \n" \ ".section .fixup,\"ax\" \n" \
"7: lhi %0,%h[e1] \n" \ "7: lhi %0,%h[e1] \n" \
...@@ -129,7 +129,7 @@ struct crypt_s390_query_status { ...@@ -129,7 +129,7 @@ struct crypt_s390_query_status {
" .long 0b,7b \n" \ " .long 0b,7b \n" \
" .long 1b,8b \n" \ " .long 1b,8b \n" \
".previous" ".previous"
#else /* __s390x__ */ #else /* CONFIG_64BIT */
#define __crypt_s390_fixup \ #define __crypt_s390_fixup \
".section .fixup,\"ax\" \n" \ ".section .fixup,\"ax\" \n" \
"7: lhi %0,%h[e1] \n" \ "7: lhi %0,%h[e1] \n" \
...@@ -142,7 +142,7 @@ struct crypt_s390_query_status { ...@@ -142,7 +142,7 @@ struct crypt_s390_query_status {
" .quad 0b,7b \n" \ " .quad 0b,7b \n" \
" .quad 1b,8b \n" \ " .quad 1b,8b \n" \
".previous" ".previous"
#endif /* __s390x__ */ #endif /* CONFIG_64BIT */
/* /*
* Standard code for setting the result of s390 crypto instructions. * Standard code for setting the result of s390 crypto instructions.
...@@ -150,10 +150,10 @@ struct crypt_s390_query_status { ...@@ -150,10 +150,10 @@ struct crypt_s390_query_status {
* [result]: the register containing the result (e.g. second operand length * [result]: the register containing the result (e.g. second operand length
* to compute number of processed bytes]. * to compute number of processed bytes].
*/ */
#ifndef __s390x__ #ifndef CONFIG_64BIT
#define __crypt_s390_set_result \ #define __crypt_s390_set_result \
" lr %0,%[result] \n" " lr %0,%[result] \n"
#else /* __s390x__ */ #else /* CONFIG_64BIT */
#define __crypt_s390_set_result \ #define __crypt_s390_set_result \
" lgr %0,%[result] \n" " lgr %0,%[result] \n"
#endif #endif
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
CONFIG_MMU=y CONFIG_MMU=y
CONFIG_RWSEM_XCHGADD_ALGORITHM=y CONFIG_RWSEM_XCHGADD_ALGORITHM=y
CONFIG_GENERIC_CALIBRATE_DELAY=y CONFIG_GENERIC_CALIBRATE_DELAY=y
CONFIG_ARCH_S390=y CONFIG_S390=y
CONFIG_UID16=y CONFIG_UID16=y
# #
...@@ -89,9 +89,7 @@ CONFIG_DEFAULT_IOSCHED="anticipatory" ...@@ -89,9 +89,7 @@ CONFIG_DEFAULT_IOSCHED="anticipatory"
# #
# Processor type and features # Processor type and features
# #
# CONFIG_ARCH_S390X is not set
# CONFIG_64BIT is not set # CONFIG_64BIT is not set
CONFIG_ARCH_S390_31=y
CONFIG_SMP=y CONFIG_SMP=y
CONFIG_NR_CPUS=32 CONFIG_NR_CPUS=32
CONFIG_HOTPLUG_CPU=y CONFIG_HOTPLUG_CPU=y
......
...@@ -8,31 +8,26 @@ obj-y := bitmap.o traps.o time.o process.o \ ...@@ -8,31 +8,26 @@ obj-y := bitmap.o traps.o time.o process.o \
setup.o sys_s390.o ptrace.o signal.o cpcmd.o ebcdic.o \ setup.o sys_s390.o ptrace.o signal.o cpcmd.o ebcdic.o \
semaphore.o s390_ext.o debug.o profile.o irq.o reipl_diag.o semaphore.o s390_ext.o debug.o profile.o irq.o reipl_diag.o
obj-y += $(if $(CONFIG_64BIT),entry64.o,entry.o)
obj-y += $(if $(CONFIG_64BIT),reipl64.o,reipl.o)
extra-y += head.o init_task.o vmlinux.lds extra-y += head.o init_task.o vmlinux.lds
obj-$(CONFIG_MODULES) += s390_ksyms.o module.o obj-$(CONFIG_MODULES) += s390_ksyms.o module.o
obj-$(CONFIG_SMP) += smp.o obj-$(CONFIG_SMP) += smp.o
obj-$(CONFIG_S390_SUPPORT) += compat_linux.o compat_signal.o \ obj-$(CONFIG_COMPAT) += compat_linux.o compat_signal.o \
compat_ioctl.o compat_wrapper.o \ compat_ioctl.o compat_wrapper.o \
compat_exec_domain.o compat_exec_domain.o
obj-$(CONFIG_BINFMT_ELF32) += binfmt_elf32.o obj-$(CONFIG_BINFMT_ELF32) += binfmt_elf32.o
obj-$(CONFIG_ARCH_S390_31) += entry.o reipl.o
obj-$(CONFIG_ARCH_S390X) += entry64.o reipl64.o
obj-$(CONFIG_VIRT_TIMER) += vtime.o obj-$(CONFIG_VIRT_TIMER) += vtime.o
# Kexec part # Kexec part
S390_KEXEC_OBJS := machine_kexec.o crash.o S390_KEXEC_OBJS := machine_kexec.o crash.o
ifeq ($(CONFIG_ARCH_S390X),y) S390_KEXEC_OBJS += $(if $(CONFIG_64BIT),relocate_kernel64.o,relocate_kernel.o)
S390_KEXEC_OBJS += relocate_kernel64.o
else
S390_KEXEC_OBJS += relocate_kernel.o
endif
obj-$(CONFIG_KEXEC) += $(S390_KEXEC_OBJS) obj-$(CONFIG_KEXEC) += $(S390_KEXEC_OBJS)
# #
# This is just to get the dependencies... # This is just to get the dependencies...
# #
......
...@@ -39,7 +39,7 @@ int __cpcmd(const char *cmd, char *response, int rlen, int *response_code) ...@@ -39,7 +39,7 @@ int __cpcmd(const char *cmd, char *response, int rlen, int *response_code)
if (response != NULL && rlen > 0) { if (response != NULL && rlen > 0) {
memset(response, 0, rlen); memset(response, 0, rlen);
#ifndef CONFIG_ARCH_S390X #ifndef CONFIG_64BIT
asm volatile ( "lra 2,0(%2)\n" asm volatile ( "lra 2,0(%2)\n"
"lr 4,%3\n" "lr 4,%3\n"
"o 4,%6\n" "o 4,%6\n"
...@@ -55,7 +55,7 @@ int __cpcmd(const char *cmd, char *response, int rlen, int *response_code) ...@@ -55,7 +55,7 @@ int __cpcmd(const char *cmd, char *response, int rlen, int *response_code)
: "a" (cpcmd_buf), "d" (cmdlen), : "a" (cpcmd_buf), "d" (cmdlen),
"a" (response), "d" (rlen), "m" (mask) "a" (response), "d" (rlen), "m" (mask)
: "cc", "2", "3", "4", "5" ); : "cc", "2", "3", "4", "5" );
#else /* CONFIG_ARCH_S390X */ #else /* CONFIG_64BIT */
asm volatile ( "lrag 2,0(%2)\n" asm volatile ( "lrag 2,0(%2)\n"
"lgr 4,%3\n" "lgr 4,%3\n"
"o 4,%6\n" "o 4,%6\n"
...@@ -73,11 +73,11 @@ int __cpcmd(const char *cmd, char *response, int rlen, int *response_code) ...@@ -73,11 +73,11 @@ int __cpcmd(const char *cmd, char *response, int rlen, int *response_code)
: "a" (cpcmd_buf), "d" (cmdlen), : "a" (cpcmd_buf), "d" (cmdlen),
"a" (response), "d" (rlen), "m" (mask) "a" (response), "d" (rlen), "m" (mask)
: "cc", "2", "3", "4", "5" ); : "cc", "2", "3", "4", "5" );
#endif /* CONFIG_ARCH_S390X */ #endif /* CONFIG_64BIT */
EBCASC(response, rlen); EBCASC(response, rlen);
} else { } else {
return_len = 0; return_len = 0;
#ifndef CONFIG_ARCH_S390X #ifndef CONFIG_64BIT
asm volatile ( "lra 2,0(%1)\n" asm volatile ( "lra 2,0(%1)\n"
"lr 3,%2\n" "lr 3,%2\n"
"diag 2,3,0x8\n" "diag 2,3,0x8\n"
...@@ -85,7 +85,7 @@ int __cpcmd(const char *cmd, char *response, int rlen, int *response_code) ...@@ -85,7 +85,7 @@ int __cpcmd(const char *cmd, char *response, int rlen, int *response_code)
: "=d" (return_code) : "=d" (return_code)
: "a" (cpcmd_buf), "d" (cmdlen) : "a" (cpcmd_buf), "d" (cmdlen)
: "2", "3" ); : "2", "3" );
#else /* CONFIG_ARCH_S390X */ #else /* CONFIG_64BIT */
asm volatile ( "lrag 2,0(%1)\n" asm volatile ( "lrag 2,0(%1)\n"
"lgr 3,%2\n" "lgr 3,%2\n"
"sam31\n" "sam31\n"
...@@ -95,7 +95,7 @@ int __cpcmd(const char *cmd, char *response, int rlen, int *response_code) ...@@ -95,7 +95,7 @@ int __cpcmd(const char *cmd, char *response, int rlen, int *response_code)
: "=d" (return_code) : "=d" (return_code)
: "a" (cpcmd_buf), "d" (cmdlen) : "a" (cpcmd_buf), "d" (cmdlen)
: "2", "3" ); : "2", "3" );
#endif /* CONFIG_ARCH_S390X */ #endif /* CONFIG_64BIT */
} }
spin_unlock_irqrestore(&cpcmd_lock, flags); spin_unlock_irqrestore(&cpcmd_lock, flags);
if (response_code != NULL) if (response_code != NULL)
...@@ -105,7 +105,7 @@ int __cpcmd(const char *cmd, char *response, int rlen, int *response_code) ...@@ -105,7 +105,7 @@ int __cpcmd(const char *cmd, char *response, int rlen, int *response_code)
EXPORT_SYMBOL(__cpcmd); EXPORT_SYMBOL(__cpcmd);
#ifdef CONFIG_ARCH_S390X #ifdef CONFIG_64BIT
int cpcmd(const char *cmd, char *response, int rlen, int *response_code) int cpcmd(const char *cmd, char *response, int rlen, int *response_code)
{ {
char *lowbuf; char *lowbuf;
...@@ -129,4 +129,4 @@ int cpcmd(const char *cmd, char *response, int rlen, int *response_code) ...@@ -129,4 +129,4 @@ int cpcmd(const char *cmd, char *response, int rlen, int *response_code)
} }
EXPORT_SYMBOL(cpcmd); EXPORT_SYMBOL(cpcmd);
#endif /* CONFIG_ARCH_S390X */ #endif /* CONFIG_64BIT */
...@@ -213,7 +213,7 @@ sysc_nr_ok: ...@@ -213,7 +213,7 @@ sysc_nr_ok:
mvc SP_ARGS(8,%r15),SP_R7(%r15) mvc SP_ARGS(8,%r15),SP_R7(%r15)
sysc_do_restart: sysc_do_restart:
larl %r10,sys_call_table larl %r10,sys_call_table
#ifdef CONFIG_S390_SUPPORT #ifdef CONFIG_COMPAT
tm __TI_flags+5(%r9),(_TIF_31BIT>>16) # running in 31 bit mode ? tm __TI_flags+5(%r9),(_TIF_31BIT>>16) # running in 31 bit mode ?
jno sysc_noemu jno sysc_noemu
larl %r10,sys_call_table_emu # use 31 bit emulation system calls larl %r10,sys_call_table_emu # use 31 bit emulation system calls
...@@ -361,7 +361,7 @@ sys_clone_glue: ...@@ -361,7 +361,7 @@ sys_clone_glue:
la %r2,SP_PTREGS(%r15) # load pt_regs la %r2,SP_PTREGS(%r15) # load pt_regs
jg sys_clone # branch to sys_clone jg sys_clone # branch to sys_clone
#ifdef CONFIG_S390_SUPPORT #ifdef CONFIG_COMPAT
sys32_clone_glue: sys32_clone_glue:
la %r2,SP_PTREGS(%r15) # load pt_regs la %r2,SP_PTREGS(%r15) # load pt_regs
jg sys32_clone # branch to sys32_clone jg sys32_clone # branch to sys32_clone
...@@ -383,7 +383,7 @@ sys_execve_glue: ...@@ -383,7 +383,7 @@ sys_execve_glue:
bnz 0(%r12) # it did fail -> store result in gpr2 bnz 0(%r12) # it did fail -> store result in gpr2
b 6(%r12) # SKIP STG 2,SP_R2(15) in b 6(%r12) # SKIP STG 2,SP_R2(15) in
# system_call/sysc_tracesys # system_call/sysc_tracesys
#ifdef CONFIG_S390_SUPPORT #ifdef CONFIG_COMPAT
sys32_execve_glue: sys32_execve_glue:
la %r2,SP_PTREGS(%r15) # load pt_regs la %r2,SP_PTREGS(%r15) # load pt_regs
lgr %r12,%r14 # save return address lgr %r12,%r14 # save return address
...@@ -398,7 +398,7 @@ sys_sigreturn_glue: ...@@ -398,7 +398,7 @@ sys_sigreturn_glue:
la %r2,SP_PTREGS(%r15) # load pt_regs as parameter la %r2,SP_PTREGS(%r15) # load pt_regs as parameter
jg sys_sigreturn # branch to sys_sigreturn jg sys_sigreturn # branch to sys_sigreturn
#ifdef CONFIG_S390_SUPPORT #ifdef CONFIG_COMPAT
sys32_sigreturn_glue: sys32_sigreturn_glue:
la %r2,SP_PTREGS(%r15) # load pt_regs as parameter la %r2,SP_PTREGS(%r15) # load pt_regs as parameter
jg sys32_sigreturn # branch to sys32_sigreturn jg sys32_sigreturn # branch to sys32_sigreturn
...@@ -408,7 +408,7 @@ sys_rt_sigreturn_glue: ...@@ -408,7 +408,7 @@ sys_rt_sigreturn_glue:
la %r2,SP_PTREGS(%r15) # load pt_regs as parameter la %r2,SP_PTREGS(%r15) # load pt_regs as parameter
jg sys_rt_sigreturn # branch to sys_sigreturn jg sys_rt_sigreturn # branch to sys_sigreturn
#ifdef CONFIG_S390_SUPPORT #ifdef CONFIG_COMPAT
sys32_rt_sigreturn_glue: sys32_rt_sigreturn_glue:
la %r2,SP_PTREGS(%r15) # load pt_regs as parameter la %r2,SP_PTREGS(%r15) # load pt_regs as parameter
jg sys32_rt_sigreturn # branch to sys32_sigreturn jg sys32_rt_sigreturn # branch to sys32_sigreturn
...@@ -429,7 +429,7 @@ sys_sigsuspend_glue: ...@@ -429,7 +429,7 @@ sys_sigsuspend_glue:
la %r14,6(%r14) # skip store of return value la %r14,6(%r14) # skip store of return value
jg sys_sigsuspend # branch to sys_sigsuspend jg sys_sigsuspend # branch to sys_sigsuspend
#ifdef CONFIG_S390_SUPPORT #ifdef CONFIG_COMPAT
sys32_sigsuspend_glue: sys32_sigsuspend_glue:
llgfr %r4,%r4 # unsigned long llgfr %r4,%r4 # unsigned long
lgr %r5,%r4 # move mask back lgr %r5,%r4 # move mask back
...@@ -449,7 +449,7 @@ sys_rt_sigsuspend_glue: ...@@ -449,7 +449,7 @@ sys_rt_sigsuspend_glue:
la %r14,6(%r14) # skip store of return value la %r14,6(%r14) # skip store of return value
jg sys_rt_sigsuspend # branch to sys_rt_sigsuspend jg sys_rt_sigsuspend # branch to sys_rt_sigsuspend
#ifdef CONFIG_S390_SUPPORT #ifdef CONFIG_COMPAT
sys32_rt_sigsuspend_glue: sys32_rt_sigsuspend_glue:
llgfr %r3,%r3 # size_t llgfr %r3,%r3 # size_t
lgr %r4,%r3 # move sigsetsize parameter lgr %r4,%r3 # move sigsetsize parameter
...@@ -464,7 +464,7 @@ sys_sigaltstack_glue: ...@@ -464,7 +464,7 @@ sys_sigaltstack_glue:
la %r4,SP_PTREGS(%r15) # load pt_regs as parameter la %r4,SP_PTREGS(%r15) # load pt_regs as parameter
jg sys_sigaltstack # branch to sys_sigreturn jg sys_sigaltstack # branch to sys_sigreturn
#ifdef CONFIG_S390_SUPPORT #ifdef CONFIG_COMPAT
sys32_sigaltstack_glue: sys32_sigaltstack_glue:
la %r4,SP_PTREGS(%r15) # load pt_regs as parameter la %r4,SP_PTREGS(%r15) # load pt_regs as parameter
jg sys32_sigaltstack_wrapper # branch to sys_sigreturn jg sys32_sigaltstack_wrapper # branch to sys_sigreturn
...@@ -1009,7 +1009,7 @@ sys_call_table: ...@@ -1009,7 +1009,7 @@ sys_call_table:
#include "syscalls.S" #include "syscalls.S"
#undef SYSCALL #undef SYSCALL
#ifdef CONFIG_S390_SUPPORT #ifdef CONFIG_COMPAT
#define SYSCALL(esa,esame,emu) .long emu #define SYSCALL(esa,esame,emu) .long emu
.globl sys_call_table_emu .globl sys_call_table_emu
......
...@@ -30,7 +30,7 @@ ...@@ -30,7 +30,7 @@
#include <asm/thread_info.h> #include <asm/thread_info.h>
#include <asm/page.h> #include <asm/page.h>
#ifdef CONFIG_ARCH_S390X #ifdef CONFIG_64BIT
#define ARCH_OFFSET 4 #define ARCH_OFFSET 4
#else #else
#define ARCH_OFFSET 0 #define ARCH_OFFSET 0
...@@ -539,7 +539,7 @@ ipl_devno: ...@@ -539,7 +539,7 @@ ipl_devno:
.word 0 .word 0
.endm .endm
#ifdef CONFIG_ARCH_S390X #ifdef CONFIG_64BIT
#include "head64.S" #include "head64.S"
#else #else
#include "head31.S" #include "head31.S"
......
...@@ -37,11 +37,11 @@ ...@@ -37,11 +37,11 @@
#define DEBUGP(fmt , ...) #define DEBUGP(fmt , ...)
#endif #endif
#ifndef CONFIG_ARCH_S390X #ifndef CONFIG_64BIT
#define PLT_ENTRY_SIZE 12 #define PLT_ENTRY_SIZE 12
#else /* CONFIG_ARCH_S390X */ #else /* CONFIG_64BIT */
#define PLT_ENTRY_SIZE 20 #define PLT_ENTRY_SIZE 20
#endif /* CONFIG_ARCH_S390X */ #endif /* CONFIG_64BIT */
void *module_alloc(unsigned long size) void *module_alloc(unsigned long size)
{ {
...@@ -294,17 +294,17 @@ apply_rela(Elf_Rela *rela, Elf_Addr base, Elf_Sym *symtab, ...@@ -294,17 +294,17 @@ apply_rela(Elf_Rela *rela, Elf_Addr base, Elf_Sym *symtab,
unsigned int *ip; unsigned int *ip;
ip = me->module_core + me->arch.plt_offset + ip = me->module_core + me->arch.plt_offset +
info->plt_offset; info->plt_offset;
#ifndef CONFIG_ARCH_S390X #ifndef CONFIG_64BIT
ip[0] = 0x0d105810; /* basr 1,0; l 1,6(1); br 1 */ ip[0] = 0x0d105810; /* basr 1,0; l 1,6(1); br 1 */
ip[1] = 0x100607f1; ip[1] = 0x100607f1;
ip[2] = val; ip[2] = val;
#else /* CONFIG_ARCH_S390X */ #else /* CONFIG_64BIT */
ip[0] = 0x0d10e310; /* basr 1,0; lg 1,10(1); br 1 */ ip[0] = 0x0d10e310; /* basr 1,0; lg 1,10(1); br 1 */
ip[1] = 0x100a0004; ip[1] = 0x100a0004;
ip[2] = 0x07f10000; ip[2] = 0x07f10000;
ip[3] = (unsigned int) (val >> 32); ip[3] = (unsigned int) (val >> 32);
ip[4] = (unsigned int) val; ip[4] = (unsigned int) val;
#endif /* CONFIG_ARCH_S390X */ #endif /* CONFIG_64BIT */
info->plt_initialized = 1; info->plt_initialized = 1;
} }
if (r_type == R_390_PLTOFF16 || if (r_type == R_390_PLTOFF16 ||
......
...@@ -235,7 +235,7 @@ int copy_thread(int nr, unsigned long clone_flags, unsigned long new_stackp, ...@@ -235,7 +235,7 @@ int copy_thread(int nr, unsigned long clone_flags, unsigned long new_stackp,