Commit 31079488 authored by Sam Ravnborg's avatar Sam Ravnborg Committed by David S. Miller

sparc32,leon: always include leon_smp + leon_mm in build

Fix-up leon specific assembler to use ASI_LEON_MMUREGS
Signed-off-by: default avatarSam Ravnborg <sam@ravnborg.org>
Cc: Daniel Hellstrom <daniel@gaisler.com>
Cc: Konrad Eisele <konrad@gaisler.com>
parent 5561cd26
...@@ -254,16 +254,4 @@ extern int leon_ipi_irq; ...@@ -254,16 +254,4 @@ extern int leon_ipi_irq;
#define _pfn_valid(pfn) ((pfn < last_valid_pfn) && (pfn >= PFN(phys_base))) #define _pfn_valid(pfn) ((pfn < last_valid_pfn) && (pfn >= PFN(phys_base)))
#define _SRMMU_PTE_PMASK_LEON 0xffffffff #define _SRMMU_PTE_PMASK_LEON 0xffffffff
#ifndef CONFIG_SPARC_LEON
/* nop definitions for !LEON case */
#define leon_switch_mm() do {} while (0)
#define init_leon() do {} while (0)
#define leon_smp_done() do {} while (0)
#define leon_boot_cpus() do {} while (0)
#define leon_boot_one_cpu(i, t) 1
#define leon_init_smp() do {} while (0)
#endif /* !defined(CONFIG_SPARC_LEON) */
#endif #endif
...@@ -393,7 +393,6 @@ linux_trap_ipi15_sun4d: ...@@ -393,7 +393,6 @@ linux_trap_ipi15_sun4d:
/* FIXME */ /* FIXME */
1: b,a 1b 1: b,a 1b
#ifdef CONFIG_SPARC_LEON
.globl smpleon_ipi .globl smpleon_ipi
.extern leon_ipi_interrupt .extern leon_ipi_interrupt
/* SMP per-cpu IPI interrupts are handled specially. */ /* SMP per-cpu IPI interrupts are handled specially. */
...@@ -424,8 +423,6 @@ linux_trap_ipi15_leon: ...@@ -424,8 +423,6 @@ linux_trap_ipi15_leon:
b ret_trap_lockless_ipi b ret_trap_lockless_ipi
clr %l6 clr %l6
#endif /* CONFIG_SPARC_LEON */
#endif /* CONFIG_SMP */ #endif /* CONFIG_SMP */
/* This routine handles illegal instructions and privileged /* This routine handles illegal instructions and privileged
......
...@@ -387,11 +387,8 @@ execute_in_high_mem: ...@@ -387,11 +387,8 @@ execute_in_high_mem:
#ifdef CONFIG_SMP #ifdef CONFIG_SMP
ldub [%g2 + %lo(boot_cpu_id)], %g1 ldub [%g2 + %lo(boot_cpu_id)], %g1
cmp %g1, 0xff ! unset means first CPU cmp %g1, 0xff ! unset means first CPU
#ifdef CONFIG_SPARC_LEON
/* XXX Hack to allow build - remove ifdef later */
bne leon_smp_cpu_startup ! continue only with master bne leon_smp_cpu_startup ! continue only with master
nop nop
#endif
#endif #endif
/* Get CPU-ID from most significant 4-bit of ASR17 */ /* Get CPU-ID from most significant 4-bit of ASR17 */
rd %asr17, %g1 rd %asr17, %g1
......
...@@ -48,8 +48,6 @@ ...@@ -48,8 +48,6 @@
#include "kernel.h" #include "kernel.h"
#ifdef CONFIG_SPARC_LEON
#include "irq.h" #include "irq.h"
extern ctxd_t *srmmu_ctx_table_phys; extern ctxd_t *srmmu_ctx_table_phys;
...@@ -507,5 +505,3 @@ void __init leon_init_smp(void) ...@@ -507,5 +505,3 @@ void __init leon_init_smp(void)
sparc32_ipi_ops = &leon_ipi_ops; sparc32_ipi_ops = &leon_ipi_ops;
} }
#endif /* CONFIG_SPARC_LEON */
...@@ -149,8 +149,6 @@ sun4d_cpu_startup: ...@@ -149,8 +149,6 @@ sun4d_cpu_startup:
b,a smp_do_cpu_idle b,a smp_do_cpu_idle
#ifdef CONFIG_SPARC_LEON
__CPUINIT __CPUINIT
.align 4 .align 4
.global leon_smp_cpu_startup, smp_penguin_ctable .global leon_smp_cpu_startup, smp_penguin_ctable
...@@ -161,7 +159,7 @@ leon_smp_cpu_startup: ...@@ -161,7 +159,7 @@ leon_smp_cpu_startup:
ld [%g1+4],%g1 ld [%g1+4],%g1
srl %g1,4,%g1 srl %g1,4,%g1
set 0x00000100,%g5 /* SRMMU_CTXTBL_PTR */ set 0x00000100,%g5 /* SRMMU_CTXTBL_PTR */
sta %g1, [%g5] ASI_M_MMUREGS sta %g1, [%g5] ASI_LEON_MMUREGS
/* Set up a sane %psr -- PIL<0xf> S<0x1> PS<0x1> CWP<0x0> */ /* Set up a sane %psr -- PIL<0xf> S<0x1> PS<0x1> CWP<0x0> */
set (PSR_PIL | PSR_S | PSR_PS), %g1 set (PSR_PIL | PSR_S | PSR_PS), %g1
...@@ -207,5 +205,3 @@ leon_smp_cpu_startup: ...@@ -207,5 +205,3 @@ leon_smp_cpu_startup:
nop nop
b,a smp_do_cpu_idle b,a smp_do_cpu_idle
#endif
...@@ -9,7 +9,7 @@ obj-y += fault_$(BITS).o ...@@ -9,7 +9,7 @@ obj-y += fault_$(BITS).o
obj-y += init_$(BITS).o obj-y += init_$(BITS).o
obj-$(CONFIG_SPARC32) += extable.o srmmu.o iommu.o io-unit.o obj-$(CONFIG_SPARC32) += extable.o srmmu.o iommu.o io-unit.o
obj-$(CONFIG_SPARC32) += hypersparc.o viking.o tsunami.o swift.o obj-$(CONFIG_SPARC32) += hypersparc.o viking.o tsunami.o swift.o
obj-$(CONFIG_SPARC_LEON)+= leon_mm.o obj-$(CONFIG_SPARC32) += leon_mm.o
# Only used by sparc64 # Only used by sparc64
obj-$(CONFIG_HUGETLB_PAGE) += hugetlbpage.o obj-$(CONFIG_HUGETLB_PAGE) += hugetlbpage.o
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment