sparc32: drop sun4c support
PATCH 1/14 sparc32: drop sun4c support
Machines with sun4c support are very rare these days, and noone is using them for any practical purposes.
The sun4c support has been know broken for quite some time too.
So rather than trying to keep it up-to-date, lets get rid of it. This allows us to do some very welcome cleanup of sparc32 support.
Updated the former sun4c specifc nmi (which was also used for sun4m UP) to be a generic UP NMI.
Signed-off-by Sam Ravnborg <[email protected]>
--- arch/sparc/include/asm/head_32.h | 10 - arch/sparc/include/asm/oplib_32.h | 8 - arch/sparc/kernel/Makefile | 2 +- arch/sparc/kernel/entry.S | 20 +- arch/sparc/kernel/head_32.S | 7 +- arch/sparc/kernel/irq_32.c | 5 - arch/sparc/kernel/kernel.h | 3 - arch/sparc/kernel/process_32.c | 2 +- arch/sparc/kernel/sun4c_irq.c | 269 ----- arch/sparc/mm/Makefile | 4 - arch/sparc/mm/sun4c.c | 2166 ------------------------------------- arch/sparc/prom/Makefile | 1 - arch/sparc/prom/segment.c | 28 - 13 files changed, 11 insertions(+), 2514 deletions(-) delete mode 100644 arch/sparc/kernel/sun4c_irq.c delete mode 100644 arch/sparc/mm/sun4c.c delete mode 100644 arch/sparc/prom/segment.c
arch/sparc/include/asm/head_32.h +0 -10
@@ -80,16 +80,6 @@#define TRAP_ENTRY_INTERRUPT (int_level) \ mov int_level, %l7; rd %psr, %l0; b real_irq_entry; rd %wim, %l3; -/* NMI's (Non Maskable Interrupts) are special, you can't keep them -* from coming in, and basically if you get one, the shows over. ;( -* On the sun4c they are usually asynchronous memory errors, on the -* the sun4m they could be either due to mem errors or a software -* initiated interrupt from the prom/kern on an SMP box saying "I -* command you to do CPU tricks, read your mailbox for more info." -*/ -#define NMI_TRAP \ - rd %wim, %l3; b linux_trap_nmi_sun4c; mov %psr, %l0; nop; -/* Window overflows/underflows are special and we need to try to be as * efficient as possible here.... */
arch/sparc/include/asm/oplib_32.h +0 -8
@@ -105,14 +105,6 @@ extern void prom_write(const char *buf, unsigned int len);extern int prom_startcpu (int cpunode,struct linux_prom_registers *context_table,int context,char *program_counter); -/* Sun4/sun4c specific memory-management startup hook. */ - -/* Map the passed segment in the given context at the passed -* virtual address. -*/ -extern void prom_putsegment (int context,unsigned long virt_addr, -int physical_segment); -/* Initialize the memory lists based upon the prom version. */ void prom_meminit (void );
arch/sparc/kernel/Makefile +1 -1
@@ -28,7 +28,7 @@ obj-y += traps_$(BITS).o # IRQ obj-y += irq_$(BITS).o -obj-$(CONFIG_SPARC32) += sun4m_irq.o sun4c_irq.o sun4d_irq.o +obj-$(CONFIG_SPARC32) += sun4m_irq.o sun4d_irq.o obj-y += process_$(BITS).o obj-y += signal_$(BITS).o
arch/sparc/kernel/entry.S +7 -13
@@ -317,8 +317,8 @@ maybe_smp4m_msg_out: RESTORE_ALL .align 4 - .globl linux_trap_ipi15_sun4m -linux_trap_ipi15_sun4m: + .globl linux_trap_ipi15 +linux_trap_ipi15: SAVE_ALL sethi %hi(0x80000000), %o2 GET_PROCESSOR4M_ID(o0)
@@ -760,20 +760,12 @@ setcc_trap_handler: jmp %l2 ! advance over trap instruction rett %l2 + 0x4 ! like this... +#ifndef CONFIG_SMP .align 4 - .globl linux_trap_nmi_sun4c -linux_trap_nmi_sun4c: + .globl linux_trap_ipi15 +linux_trap_ipi15: SAVE_ALL - /* Ugh, we need to clear the IRQ line. This is now - * a very sun4c specific trap handler... - */ - sethi %hi(interrupt_enable), %l5 - ld [%l5 + %lo(interrupt_enable)], %l5 - ldub [%l5], %l6 - andn %l6, INTS_ENAB, %l6 - stb %l6, [%l5] - /* Now it is safe to re-enable traps without recursion. */ or %l0, PSR_PIL, %l0 wr %l0, PSR_ET, %psr
@@ -797,6 +789,8 @@ linux_trap_nmi_sun4c: RESTORE_ALL +#endif /* CONFIG_SMP */ + .align 4 .globl invalid_segment_patch1_ff .globl invalid_segment_patch2_ff
arch/sparc/kernel/head_32.S +2 -5
@@ -111,11 +111,8 @@ t_irq12:TRAP_ENTRY_INTERRUPT(12) /* IRQ Zilog serial chip */ t_irq13:TRAP_ENTRY_INTERRUPT(13) /* IRQ Audio Intr. */ t_irq14:TRAP_ENTRY_INTERRUPT(14) /* IRQ Timer #2 */ .globl t_nmi -#ifndef CONFIG_SMP -t_nmi: NMI_TRAP /* Level 15 (NMI) */ -#else -t_nmi: TRAP_ENTRY(0x1f, linux_trap_ipi15_sun4m) -#endif +t_nmi: TRAP_ENTRY(0x1f, linux_trap_ipi15) + t_racc: TRAP_ENTRY(0x20, do_reg_access) /* General Register Access Error */ t_iacce:BAD_TRAP(0x21) /* Instr Access Error */ t_bad22:BAD_TRAP(0x22) BAD_TRAP(0x23)
arch/sparc/kernel/irq_32.c +0 -5
@@ -346,11 +346,6 @@ void sparc_floppy_irq(int irq, void *dev_id, struct pt_regs *regs)void __init init_IRQ (void ) {switch (sparc_cpu_model) { -case sun4c: -case sun4: -sun4c_init_IRQ (); -break ; -case sun4m:pcic_probe ();if (pcic_present ())
arch/sparc/kernel/kernel.h +0 -3
@@ -43,9 +43,6 @@ extern spinlock_t irq_action_lock;extern void unexpected_irq (int irq,void *dev_id,struct pt_regs * regs);extern void init_IRQ (void ); -/* sun4c_irq.c */ -extern void sun4c_init_IRQ (void ); -/* sun4m_irq.c */ extern void sun4m_init_IRQ (void );extern void sun4m_unmask_profile_irq (void );
arch/sparc/kernel/process_32.c +1 -1
@@ -100,7 +100,7 @@ void cpu_idle(void)printk ("kernel faults / second = %ld\n" , fps);#endif if (fps >=SUN4C_FAULT_HIGH ) { -sun4c_grow_kernel_ring (); +/*sun4c_grow_kernel_ring();*/ } }local_irq_enable ();
arch/sparc/kernel/sun4c_irq.c deleted +0 -268
268 lines not on this page · raw message
arch/sparc/mm/Makefile +0 -4
@@ -18,8 +18,4 @@ obj-$(CONFIG_HUGETLB_PAGE) += hugetlbpage.o # Only used by sparc32 obj-$(CONFIG_HIGHMEM) += highmem.o -ifdef CONFIG_SMP obj-$(CONFIG_SPARC32) += nosun4c.o -else -obj-$(CONFIG_SPARC32) += sun4c.o -endif
arch/sparc/mm/sun4c.c deleted +0 -2153
2,153 lines not on this page · raw message
arch/sparc/prom/Makefile +0 -1
@@ -10,7 +10,6 @@ lib-$(CONFIG_SPARC32) += memory.o lib-y += misc_$(BITS).o lib-$(CONFIG_SPARC32) += mp.o lib-$(CONFIG_SPARC32) += ranges.o -lib-$(CONFIG_SPARC32) += segment.o lib-y += console_$(BITS).o lib-y += printf.o lib-y += tree_$(BITS).o
arch/sparc/prom/segment.c deleted +0 -28
@@ -1,28 +0,0 @@ -/* -* segment.c: Prom routine to map segments in other contexts before -* a standalone is completely mapped. This is for sun4 and -* sun4c architectures only. -* -* Copyright (C) 1995 David S. Miller ([email protected]) -*/ - -#include <linux/types.h> -#include <linux/kernel.h> -#include <linux/sched.h> -#include <asm/openprom.h> -#include <asm/oplib.h> - -extern void restore_current (void ); - -/* Set physical segment 'segment' at virtual address 'vaddr' in -* context 'ctx'. -*/ -void -prom_putsegment (int ctx,unsigned long vaddr,int segment) -{ -unsigned long flags; -spin_lock_irqsave (&prom_lock, flags); - (*(romvec->pv_setctxt))(ctx, (char *) vaddr, segment); -restore_current (); -spin_unlock_irqrestore (&prom_lock, flags); -}
Signature · 1 line
1.6.0.6