X-Git-Url: http://git.rohieb.name/openwrt.git/blobdiff_plain/e521e0fb000c7b7e80a73cac4c1e264e7da8e98f..d59a23df99764f585e184a5cfc63873d38cc42dd:/target/linux/brcm47xx/patches-2.6.37/017-MIPS-BCM47xx-bmips4kc_fix.patch diff --git a/target/linux/brcm47xx/patches-2.6.37/017-MIPS-BCM47xx-bmips4kc_fix.patch b/target/linux/brcm47xx/patches-2.6.37/017-MIPS-BCM47xx-bmips4kc_fix.patch index 3b6c79704..049de9dca 100644 --- a/target/linux/brcm47xx/patches-2.6.37/017-MIPS-BCM47xx-bmips4kc_fix.patch +++ b/target/linux/brcm47xx/patches-2.6.37/017-MIPS-BCM47xx-bmips4kc_fix.patch @@ -1,34 +1,52 @@ +From 1ff5904f725e9816b5ff2b5ade1d6326558d8e01 Mon Sep 17 00:00:00 2001 +From: Kevin Cernekee +To: Ralf Baechle +Cc: , +Date: Mon, 22 Nov 2010 21:41:28 -0800 +Subject: [PATCH 7/7] MIPS: Fix regression on BCM4710 processor detection + +BCM4710 uses the BMIPS32 core (like BCM6345), not the MIPS 4Kc core as +was previously believed. + +Signed-off-by: Kevin Cernekee +--- + arch/mips/include/asm/cpu.h | 4 ++-- + arch/mips/kernel/cpu-probe.c | 7 ++----- + 2 files changed, 4 insertions(+), 7 deletions(-) + +--- a/arch/mips/include/asm/cpu.h ++++ b/arch/mips/include/asm/cpu.h +@@ -111,8 +111,8 @@ + * These are the PRID's for when 23:16 == PRID_COMP_BROADCOM + */ + +-#define PRID_IMP_BMIPS4KC 0x4000 +-#define PRID_IMP_BMIPS32 0x8000 ++#define PRID_IMP_BMIPS32_REV4 0x4000 ++#define PRID_IMP_BMIPS32_REV8 0x8000 + #define PRID_IMP_BMIPS3300 0x9000 + #define PRID_IMP_BMIPS3300_ALT 0x9100 + #define PRID_IMP_BMIPS3300_BUG 0x0000 --- a/arch/mips/kernel/cpu-probe.c +++ b/arch/mips/kernel/cpu-probe.c -@@ -934,8 +934,8 @@ static inline void cpu_probe_broadcom(st +@@ -905,7 +905,8 @@ static inline void cpu_probe_broadcom(st + { + decode_configs(c); + switch (c->processor_id & 0xff00) { +- case PRID_IMP_BMIPS32: ++ case PRID_IMP_BMIPS32_REV4: ++ case PRID_IMP_BMIPS32_REV8: + c->cputype = CPU_BMIPS32; + __cpu_name[cpu] = "Broadcom BMIPS32"; + break; +@@ -933,10 +934,6 @@ static inline void cpu_probe_broadcom(st + __cpu_name[cpu] = "Broadcom BMIPS5000"; c->options |= MIPS_CPU_ULRI; break; - case PRID_IMP_BMIPS4KC: +- case PRID_IMP_BMIPS4KC: - c->cputype = CPU_4KC; - __cpu_name[cpu] = "MIPS 4Kc"; -+ c->cputype = CPU_BMIPS4KC; -+ __cpu_name[cpu] = "Broadcom BMIPS4Kc"; - break; +- break; } } ---- a/arch/mips/include/asm/cpu.h -+++ b/arch/mips/include/asm/cpu.h -@@ -227,7 +227,7 @@ enum cpu_type_enum { - */ - CPU_4KC, CPU_4KEC, CPU_4KSC, CPU_24K, CPU_34K, CPU_1004K, CPU_74K, - CPU_ALCHEMY, CPU_PR4450, CPU_BMIPS32, CPU_BMIPS3300, CPU_BMIPS4350, -- CPU_BMIPS4380, CPU_BMIPS5000, CPU_JZRISC, -+ CPU_BMIPS4380, CPU_BMIPS4KC, CPU_BMIPS5000, CPU_JZRISC, - /* - * MIPS64 class processors ---- a/arch/mips/mm/tlbex.c -+++ b/arch/mips/mm/tlbex.c -@@ -342,6 +342,7 @@ static void __cpuinit build_tlb_write_en - case CPU_BMIPS3300: - case CPU_BMIPS4350: - case CPU_BMIPS4380: -+ case CPU_BMIPS4KC: - case CPU_BMIPS5000: - case CPU_LOONGSON2: - case CPU_R5500: