Remove COMPAT_IA32 support from ia64.
Subsystems (2)
PATCH 1/1 Remove COMPAT_IA32 support from ia64.
This has been broken since May 2008 when Al Viro killed altroot support. Since nobody has complained, it would appear that there are no users of this code (A plausible theory since the main OSVs that support ia64 prefer to use the IA32-EL software emulation).
---
xargs rm -f << 'EOF'arch/ia64/ia32/Makefilearch/ia64/ia32/audit.carch/ia64/ia32/binfmt_elf32.carch/ia64/ia32/elfcore32.harch/ia64/ia32/ia32_entry.Sarch/ia64/ia32/ia32_ldt.carch/ia64/ia32/ia32_signal.carch/ia64/ia32/ia32_support.carch/ia64/ia32/ia32_traps.carch/ia64/ia32/ia32priv.harch/ia64/ia32/sys_ia32.carch/ia64/include/asm/ia32.h
EOF
arch/ia64/Kconfig +0 -17
@@ -499,23 +499,6 @@ config ARCH_PROC_KCORE_TEXT def_bool y depends on PROC_KCORE -config IA32_SUPPORT - bool "Support for Linux/x86 binaries" - help - IA-64 processors can execute IA-32 (X86) instructions. By - saying Y here, the kernel will include IA-32 system call - emulation support which makes it possible to transparently - run IA-32 Linux binaries on an IA-64 Linux system. - If in doubt, say Y. - -config COMPAT - bool - depends on IA32_SUPPORT - default y - -config COMPAT_FOR_U64_ALIGNMENT - def_bool COMPAT - config IA64_MCA_RECOVERY tristate "MCA recovery from errors other than TLB."
arch/ia64/Makefile +0 -1
@@ -46,7 +46,6 @@ head-y := arch/ia64/kernel/head.o arch/ia64/kernel/init_task.o libs-y += arch/ia64/lib/ core-y += arch/ia64/kernel/ arch/ia64/mm/ -core-$(CONFIG_IA32_SUPPORT) += arch/ia64/ia32/ core-$(CONFIG_IA64_DIG) += arch/ia64/dig/ core-$(CONFIG_IA64_DIG_VTD) += arch/ia64/dig/ core-$(CONFIG_IA64_GENERIC) += arch/ia64/dig/
arch/ia64/configs/bigsur_defconfig +0 -2
@@ -131,8 +131,6 @@ CONFIG_ARCH_DISCONTIGMEM_ENABLE=y CONFIG_ARCH_FLATMEM_ENABLE=y CONFIG_ARCH_SPARSEMEM_ENABLE=y # CONFIG_VIRTUAL_MEM_MAP is not set -CONFIG_IA32_SUPPORT=y -CONFIG_COMPAT=y # CONFIG_IA64_MCA_RECOVERY is not set CONFIG_PERFMON=y CONFIG_IA64_PALINFO=y
arch/ia64/configs/generic_defconfig +0 -2
@@ -205,8 +205,6 @@ CONFIG_VIRTUAL_MEM_MAP=y CONFIG_HOLES_IN_ZONE=y CONFIG_HAVE_ARCH_EARLY_PFN_TO_NID=y CONFIG_HAVE_ARCH_NODEDATA_EXTENSION=y -CONFIG_IA32_SUPPORT=y -CONFIG_COMPAT=y CONFIG_COMPAT_FOR_U64_ALIGNMENT=y CONFIG_IA64_MCA_RECOVERY=y CONFIG_PERFMON=y
arch/ia64/configs/gensparse_defconfig +0 -2
@@ -139,8 +139,6 @@ CONFIG_ARCH_SPARSEMEM_ENABLE=y CONFIG_ARCH_DISCONTIGMEM_DEFAULT=y CONFIG_NUMA=y CONFIG_HAVE_ARCH_EARLY_PFN_TO_NID=y -CONFIG_IA32_SUPPORT=y -CONFIG_COMPAT=y CONFIG_IA64_MCA_RECOVERY=y CONFIG_PERFMON=y CONFIG_IA64_PALINFO=y
arch/ia64/configs/sim_defconfig +0 -2
@@ -130,8 +130,6 @@ CONFIG_ARCH_DISCONTIGMEM_ENABLE=y CONFIG_ARCH_FLATMEM_ENABLE=y CONFIG_ARCH_SPARSEMEM_ENABLE=y # CONFIG_VIRTUAL_MEM_MAP is not set -CONFIG_IA32_SUPPORT=y -CONFIG_COMPAT=y # CONFIG_IA64_MCA_RECOVERY is not set # CONFIG_PERFMON is not set CONFIG_IA64_PALINFO=m
arch/ia64/configs/tiger_defconfig +0 -1
@@ -154,7 +154,6 @@ CONFIG_ARCH_SPARSEMEM_ENABLE=y CONFIG_ARCH_POPULATES_NODE_MAP=y CONFIG_VIRTUAL_MEM_MAP=y CONFIG_HOLES_IN_ZONE=y -# CONFIG_IA32_SUPPORT is not set CONFIG_IA64_MCA_RECOVERY=y CONFIG_PERFMON=y CONFIG_IA64_PALINFO=y
arch/ia64/configs/xen_domu_defconfig +0 -2
@@ -200,8 +200,6 @@ CONFIG_ARCH_SPARSEMEM_ENABLE=y CONFIG_ARCH_POPULATES_NODE_MAP=y CONFIG_VIRTUAL_MEM_MAP=y CONFIG_HOLES_IN_ZONE=y -# CONFIG_IA32_SUPPORT is not set -# CONFIG_COMPAT_FOR_U64_ALIGNMENT is not set CONFIG_IA64_MCA_RECOVERY=y CONFIG_PERFMON=y CONFIG_IA64_PALINFO=y
arch/ia64/configs/zx1_defconfig +0 -2
@@ -150,8 +150,6 @@ CONFIG_ARCH_DISCONTIGMEM_DEFAULT=y CONFIG_ARCH_POPULATES_NODE_MAP=y CONFIG_VIRTUAL_MEM_MAP=y CONFIG_HOLES_IN_ZONE=y -CONFIG_IA32_SUPPORT=y -CONFIG_COMPAT=y CONFIG_IA64_MCA_RECOVERY=y CONFIG_PERFMON=y CONFIG_IA64_PALINFO=y
arch/ia64/include/asm/processor.h +0 -46
70 lines not on this page · raw message
arch/ia64/include/asm/syscall.h +0 -81
117 lines not on this page · raw message
arch/ia64/include/asm/system.h +1 -10
@@ -191,15 +191,6 @@ do { \#ifdef __KERNEL__ -#ifdef CONFIG_IA32_SUPPORT -# define IS_IA32_PROCESS (regs) (ia64_psr(regs)->is != 0) -#else -# define IS_IA32_PROCESS (regs) 0 -struct task_struct ; -static inline void ia32_save_state (struct task_struct *t __attribute__((unused))){} -static inline void ia32_load_state (struct task_struct *t __attribute__((unused))){} -#endif -/* * Context switch from one thread to another. If the two threads have * different address spaces, schedule() has already taken care of
@@ -233,7 +224,7 @@ extern void ia64_account_on_switch (struct task_struct *prev, struct task_struct#define IA64_HAS_EXTRA_STATE (t) \ ((t)->thread.flags & (IA64_THREAD_DBG_VALID|IA64_THREAD_PM_VALID) \ - || IS_IA32_PROCESS(task_pt_regs(t)) || PERFMON_IS_SYSWIDE()) + || PERFMON_IS_SYSWIDE())#define __switch_to (prev,next,last) do { \ IA64_ACCOUNT_ON_SWITCH(prev, next); \
arch/ia64/include/asm/unistd.h +0 -14
@@ -335,20 +335,6 @@#define __ARCH_WANT_SYS_RT_SIGACTION#define __ARCH_WANT_SYS_RT_SIGSUSPEND -#ifdef CONFIG_IA32_SUPPORT -# define __ARCH_WANT_SYS_FADVISE64 -# define __ARCH_WANT_SYS_GETPGRP -# define __ARCH_WANT_SYS_LLSEEK -# define __ARCH_WANT_SYS_NICE -# define __ARCH_WANT_SYS_OLD_GETRLIMIT -# define __ARCH_WANT_SYS_OLDUMOUNT -# define __ARCH_WANT_SYS_PAUSE -# define __ARCH_WANT_SYS_SIGPENDING -# define __ARCH_WANT_SYS_SIGPROCMASK -# define __ARCH_WANT_COMPAT_SYS_RT_SIGSUSPEND -# define __ARCH_WANT_COMPAT_SYS_TIME -#endif -#if !defined(__ASSEMBLY__) && !defined(ASSEMBLER )#include <linux/types.h>
arch/ia64/kernel/audit.c +0 -21
@@ -30,20 +30,11 @@ static unsigned signal_class[] = {int audit_classify_arch (int arch) { -#ifdef CONFIG_IA32_SUPPORT -if (arch =AUDIT_ARCH_I386 ) -return 1 ; -#endif return 0 ; }int audit_classify_syscall (int abi,unsigned syscall) { -#ifdef CONFIG_IA32_SUPPORT -extern int ia32_classify_syscall (unsigned ); -if (abi =AUDIT_ARCH_I386 ) -return ia32_classify_syscall (syscall); -#endif switch (syscall) {case __NR_open:return 2 ;
@@ -58,18 +49,6 @@ int audit_classify_syscall(int abi, unsigned syscall)static int __init audit_classes_init (void ) { -#ifdef CONFIG_IA32_SUPPORT -extern __u32 ia32_dir_class[]; -extern __u32 ia32_write_class[]; -extern __u32 ia32_read_class[]; -extern __u32 ia32_chattr_class[]; -extern __u32 ia32_signal_class[]; -audit_register_class (AUDIT_CLASS_WRITE_32 , ia32_write_class); -audit_register_class (AUDIT_CLASS_READ_32 , ia32_read_class); -audit_register_class (AUDIT_CLASS_DIR_WRITE_32 , ia32_dir_class); -audit_register_class (AUDIT_CLASS_CHATTR_32 , ia32_chattr_class); -audit_register_class (AUDIT_CLASS_SIGNAL_32 , ia32_signal_class); -#endif audit_register_class (AUDIT_CLASS_WRITE , write_class);audit_register_class (AUDIT_CLASS_READ , read_class);audit_register_class (AUDIT_CLASS_DIR_WRITE , dir_class);
arch/ia64/kernel/entry.S +0 -39
@@ -71,15 +71,6 @@ ENTRY(ia64_execve) add out3,sp // regs br.call.sptk.many rp=sys_execve .ret0: -#ifdef CONFIG_IA32_SUPPORT - /* - * Check if we're returning to ia32 mode. If so, we need to restore ia32 registers - * from pt_regs. - */ - adds r16=PT(CR_IPSR)+16,sp - ;; - ld8 r16=[r16] -#endif cmp4.ge p6,p7=r8,r0 mov ar.pfs=loc1 // restore ar.pfs sxt4 r8=r8 // return 64-bit result
@@ -108,12 +99,6 @@ ENTRY(ia64_execve) ldf.fill f23=[sp]; ldf.fill f24=[sp]; mov f25ð ldf.fill f26=[sp]; ldf.fill f27=[sp]; mov f28ð ldf.fill f29=[sp]; ldf.fill f30=[sp]; mov f31ð -#ifdef CONFIG_IA32_SUPPORT - tbit.nz p6,p0=r16, IA64_PSR_IS_BIT - movl loc0=ia64_ret_from_ia32_execve - ;; -(p6) mov rp=loc0 -#endif br.ret.sptk.many rp END(ia64_execve)
@@ -848,30 +833,6 @@ __paravirt_work_processed_syscall: br.cond.sptk.many rbs_switch // B END(__paravirt_leave_syscall) -#ifdef __IA64_ASM_PARAVIRTUALIZED_NATIVE -#ifdef CONFIG_IA32_SUPPORT -GLOBAL_ENTRY(ia64_ret_from_ia32_execve) - PT_REGS_UNWIND_INFO(0) - adds r2=PT(R8)+16,sp // r2 = &pt_regs.r8 - adds r3=PT(R10)+16,sp // r3 = &pt_regs.r10 - ;; - .mem.offset 0,0 - st8.spill [r2]=r8 // store return value in slot for r8 and set unat bit - .mem.offset 8,0 - st8.spill [r3]=r0 // clear error indication in slot for r10 and set unat bit -#ifdef CONFIG_PARAVIRT - ;; - // don't fall through, ia64_leave_kernel may be #define'd - br.cond.sptk.few ia64_leave_kernel - ;; -#endif /* CONFIG_PARAVIRT */ -END(ia64_ret_from_ia32_execve) -#ifndef CONFIG_PARAVIRT - // fall through -#endif -#endif /* CONFIG_IA32_SUPPORT */ -#endif /* __IA64_ASM_PARAVIRTUALIZED_NATIVE */ - GLOBAL_ENTRY(__paravirt_leave_kernel) PT_REGS_UNWIND_INFO(0) /*
arch/ia64/kernel/ivt.S +0 -114
136 lines not on this page · raw message
arch/ia64/kernel/process.c +3 -52
115 lines not on this page · raw message
arch/ia64/kernel/ptrace.c +2 -12
@@ -1250,13 +1250,8 @@ syscall_trace_enter (long arg0, long arg1, long arg2, long arg3,long syscall;int arch; -if (IS_IA32_PROCESS (®s)) { - syscall = regs.r1; - arch =AUDIT_ARCH_I386 ; - }else { - syscall = regs.r15; - arch =AUDIT_ARCH_IA64 ; - } + syscall = regs.r15; + arch =AUDIT_ARCH_IA64 ;audit_syscall_entry (arch, syscall, arg0, arg1, arg2, arg3); }
@@ -2172,11 +2167,6 @@ static const struct user_regset_view user_ia64_view = {const struct user_regset_view *task_user_regset_view (struct task_struct *tsk) { -#ifdef CONFIG_IA32_SUPPORT -extern const struct user_regset_view user_ia32_view; -if (IS_IA32_PROCESS (task_pt_regs (tsk))) -return &user_ia32_view; -#endif return &user_ia64_view; }
arch/ia64/kernel/setup.c +0 -5
@@ -46,7 +46,6 @@#include <linux/kexec.h> #include <linux/crash_dump.h> -#include <asm/ia32.h> #include <asm/machvec.h> #include <asm/mca.h> #include <asm/meminit.h>
@@ -1016,10 +1015,6 @@ cpu_init (void)ia64_mmu_init (ia64_imva (cpu_data));ia64_mca_cpu_init (ia64_imva (cpu_data)); -#ifdef CONFIG_IA32_SUPPORT -ia32_cpu_init (); -#endif -/* Clear ITC to eliminate sched_clock() overflows in human time. */ ia64_set_itc (0 );
arch/ia64/kernel/signal.c +14 -40
99 lines not on this page · raw message
arch/ia64/kernel/smpboot.c +0 -5
@@ -44,7 +44,6 @@#include <asm/cache.h> #include <asm/current.h> #include <asm/delay.h> -#include <asm/ia32.h> #include <asm/io.h> #include <asm/irq.h> #include <asm/machvec.h>
@@ -443,10 +442,6 @@ smp_callin (void)calibrate_delay (); local_cpu_data->loops_per_jiffy = loops_per_jiffy; -#ifdef CONFIG_IA32_SUPPORT -ia32_gdt_init (); -#endif -/* * Allow the master to continue. */
arch/ia64/kernel/traps.c +0 -9
@@ -19,7 +19,6 @@#include <linux/kdebug.h> #include <asm/fpswa.h> -#include <asm/ia32.h> #include <asm/intrinsics.h> #include <asm/processor.h> #include <asm/uaccess.h>
@@ -626,10 +625,6 @@ ia64_fault (unsigned long vector, unsigned long isr, unsigned long ifa,break ;case 45 : -#ifdef CONFIG_IA32_SUPPORT -if (ia32_exception (®s, isr) =0 ) -return ; -#endif printk (KERN_ERR "Unexpected IA-32 exception (Trap 45)\n" );printk (KERN_ERR " iip - 0x%lx, ifa - 0x%lx, isr - 0x%lx\n" , iip, ifa, isr);
@@ -637,10 +632,6 @@ ia64_fault (unsigned long vector, unsigned long isr, unsigned long ifa,break ;case 46 : -#ifdef CONFIG_IA32_SUPPORT -if (ia32_intercept (®s, isr) =0 ) -return ; -#endif printk (KERN_ERR "Unexpected IA-32 intercept trap (Trap 46)\n" );printk (KERN_ERR " iip - 0x%lx, ifa - 0x%lx, isr - 0x%lx, iim - 0x%lx\n" , iip, ifa, isr, iim);
arch/ia64/mm/init.c +0 -5
@@ -22,7 +22,6 @@#include <linux/kexec.h> #include <asm/dma.h> -#include <asm/ia32.h> #include <asm/io.h> #include <asm/machvec.h> #include <asm/numa.h>
@@ -668,10 +667,6 @@ mem_init (void) fsyscall_table[i] = sys_call_table[i] |1 ; }setup_gate (); - -#ifdef CONFIG_IA32_SUPPORT -ia32_mem_init (); -#endif }#ifdef CONFIG_MEMORY_HOTPLUG
arch/ia64/xen/hypercall.S +0 -5
@@ -58,11 +58,6 @@ __HCALL2(xen_ptcga, HYPERPRIVOP_PTC_GA) __HCALL2(xen_set_rr, HYPERPRIVOP_SET_RR) __HCALL2(xen_set_kr, HYPERPRIVOP_SET_KR) -#ifdef CONFIG_IA32_SUPPORT -__HCALL0(xen_get_eflag, HYPERPRIVOP_GET_EFLAG) -__HCALL1(xen_set_eflag, HYPERPRIVOP_SET_EFLAG) // refer SDM vol1 3.1.8 -#endif /* CONFIG_IA32_SUPPORT */ - GLOBAL_ENTRY(xen_set_rr0_to_rr4) mov r8=r32 mov r9=r33
arch/ia64/xen/xen_pv_ops.c +0 -16
@@ -301,11 +301,6 @@ static void xen_setreg(int regnum, unsigned long val) case _IA64_REG_AR_KR0 ... _IA64_REG_AR_KR7:xen_set_kr (regnum - _IA64_REG_AR_KR0, val);break ; -#ifdef CONFIG_IA32_SUPPORT -case _IA64_REG_AR_EFLAG: -xen_set_eflag (val); -break ; -#endif case _IA64_REG_AR_ITC:xen_set_itc (val);break ;
@@ -332,11 +327,6 @@ static unsigned long xen_getreg(int regnum)case _IA64_REG_PSR: res =xen_get_psr ();break ; -#ifdef CONFIG_IA32_SUPPORT -case _IA64_REG_AR_EFLAG: - res =xen_get_eflag (); -break ; -#endif case _IA64_REG_AR_ITC: res =xen_get_itc ();break ;
@@ -710,9 +700,6 @@ extern unsigned long xen_getreg(int regnum);__DEFINE_FUNC (getreg, __DEFINE_GET_REG(PSR, PSR) -#ifdef CONFIG_IA32_SUPPORT - __DEFINE_GET_REG(AR_EFLAG, EFLAG) -#endif/* get_itc */ "mov r2 = " __stringify(_IA64_REG_AR_ITC) "\n"
@@ -789,9 +776,6 @@ __DEFINE_FUNC(setreg,";;\n" "(p6) br.cond.spnt xen_set_itc\n" -#ifdef CONFIG_IA32_SUPPORT - __DEFINE_SET_REG(AR_EFLAG, SET_EFLAG) -#endif __DEFINE_SET_REG(CR_TPR, SET_TPR)__DEFINE_SET_REG (CR_EOI ,EOI )
drivers/input/input-compat.h +0 -2
@@ -21,8 +21,6 @@you why the ifdefs are needed? Think about it again. -AK */ #ifdef CONFIG_X86_64 # define INPUT_COMPAT_TEST is_compat_task() -#elif defined(CONFIG_IA64 ) -# define INPUT_COMPAT_TEST IS_IA32_PROCESS(task_pt_regs(current))#elif defined(CONFIG_S390 )# define INPUT_COMPAT_TEST test_thread_flag(TIF_31BIT)#elif defined(CONFIG_MIPS )
Quoted 6 lines · Tony
This has been broken since May 2008 when Al Viro killed altroot support. Since nobody has complained, it would appear that there are no users of this code (A plausible theory since the main OSVs that support ia64 prefer to use the IA32-EL software emulation).
Signed-off-by Tony Luck <[email protected]>
Reading old email ... one should note that some of that code lives on in the x86-64 32bit emulation. I copied some code (not all, other was written from scratch or from other archs) from ia64 when I did that.
R.I.P.
-And
Signature · 1 line
[email protected] -- Speaking for myself only.