]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - arch/mips/kernel/cpu-probe.c
Merge git://git.kernel.org/pub/scm/linux/kernel/git/brodo/pcmcia-fixes-2.6
[linux-2.6-omap-h63xx.git] / arch / mips / kernel / cpu-probe.c
index 5c2794391bf53423d8cd4a1282e17603701023f8..335a6ae3d594044fa0ca99e44ee189631238b609 100644 (file)
@@ -169,6 +169,7 @@ static inline void check_wait(void)
 
        case CPU_24K:
        case CPU_34K:
+       case CPU_1004K:
                cpu_wait = r4k_wait;
                if (read_c0_config7() & MIPS_CONF7_WII)
                        cpu_wait = r4k_wait_irqoff;
@@ -188,6 +189,8 @@ static inline void check_wait(void)
        case CPU_AU1500:
        case CPU_AU1550:
        case CPU_AU1200:
+       case CPU_AU1210:
+       case CPU_AU1250:
                if (allow_au1k_wait)
                        cpu_wait = au1k_wait;
                break;
@@ -548,7 +551,7 @@ static inline void cpu_probe_legacy(struct cpuinfo_mips *c)
        }
 }
 
-static char unknown_isa[] __initdata = KERN_ERR \
+static char unknown_isa[] __cpuinitdata = KERN_ERR \
        "Unsupported ISA type, c0.config0: %d.";
 
 static inline unsigned int decode_config0(struct cpuinfo_mips *c)
@@ -654,7 +657,7 @@ static inline unsigned int decode_config3(struct cpuinfo_mips *c)
        return config3 & MIPS_CONF_M;
 }
 
-static void __init decode_configs(struct cpuinfo_mips *c)
+static void __cpuinit decode_configs(struct cpuinfo_mips *c)
 {
        /* MIPS32 or MIPS64 compliant CPU.  */
        c->options = MIPS_CPU_4KEX | MIPS_CPU_4K_CACHE | MIPS_CPU_COUNTER |
@@ -673,6 +676,12 @@ static void __init decode_configs(struct cpuinfo_mips *c)
                return;
 }
 
+#ifdef CONFIG_CPU_MIPSR2
+extern void spram_config(void);
+#else
+static inline void spram_config(void) {}
+#endif
+
 static inline void cpu_probe_mips(struct cpuinfo_mips *c)
 {
        decode_configs(c);
@@ -709,7 +718,12 @@ static inline void cpu_probe_mips(struct cpuinfo_mips *c)
        case PRID_IMP_74K:
                c->cputype = CPU_74K;
                break;
+       case PRID_IMP_1004K:
+               c->cputype = CPU_1004K;
+               break;
        }
+
+       spram_config();
 }
 
 static inline void cpu_probe_alchemy(struct cpuinfo_mips *c)
@@ -733,6 +747,11 @@ static inline void cpu_probe_alchemy(struct cpuinfo_mips *c)
                        break;
                case 4:
                        c->cputype = CPU_AU1200;
+                       if (2 == (c->processor_id & 0xff))
+                               c->cputype = CPU_AU1250;
+                       break;
+               case 5:
+                       c->cputype = CPU_AU1210;
                        break;
                default:
                        panic("Unknown Au Core!");
@@ -771,7 +790,7 @@ static inline void cpu_probe_sandcraft(struct cpuinfo_mips *c)
        }
 }
 
-static inline void cpu_probe_philips(struct cpuinfo_mips *c)
+static inline void cpu_probe_nxp(struct cpuinfo_mips *c)
 {
        decode_configs(c);
        switch (c->processor_id & 0xff00) {
@@ -780,7 +799,7 @@ static inline void cpu_probe_philips(struct cpuinfo_mips *c)
                c->isa_level = MIPS_CPU_ISA_M32R1;
                break;
        default:
-               panic("Unknown Philips Core!"); /* REVISIT: die? */
+               panic("Unknown NXP Core!"); /* REVISIT: die? */
                break;
        }
 }
@@ -807,7 +826,7 @@ const char *__cpu_name[NR_CPUS];
 /*
  * Name a CPU
  */
-static __init const char *cpu_to_name(struct cpuinfo_mips *c)
+static __cpuinit const char *cpu_to_name(struct cpuinfo_mips *c)
 {
        const char *name = NULL;
 
@@ -858,6 +877,8 @@ static __init const char *cpu_to_name(struct cpuinfo_mips *c)
        case CPU_AU1100:        name = "Au1100"; break;
        case CPU_AU1550:        name = "Au1550"; break;
        case CPU_AU1200:        name = "Au1200"; break;
+       case CPU_AU1210:        name = "Au1210"; break;
+       case CPU_AU1250:        name = "Au1250"; break;
        case CPU_4KEC:          name = "MIPS 4KEc"; break;
        case CPU_4KSC:          name = "MIPS 4KSc"; break;
        case CPU_VR41XX:        name = "NEC Vr41xx"; break;
@@ -867,6 +888,7 @@ static __init const char *cpu_to_name(struct cpuinfo_mips *c)
        case CPU_24K:           name = "MIPS 24K"; break;
        case CPU_25KF:          name = "MIPS 25Kf"; break;
        case CPU_34K:           name = "MIPS 34K"; break;
+       case CPU_1004K:         name = "MIPS 1004K"; break;
        case CPU_74K:           name = "MIPS 74K"; break;
        case CPU_VR4111:        name = "NEC VR4111"; break;
        case CPU_VR4121:        name = "NEC VR4121"; break;
@@ -887,7 +909,7 @@ static __init const char *cpu_to_name(struct cpuinfo_mips *c)
        return name;
 }
 
-__init void cpu_probe(void)
+__cpuinit void cpu_probe(void)
 {
        struct cpuinfo_mips *c = &current_cpu_data;
        unsigned int cpu = smp_processor_id();
@@ -916,8 +938,8 @@ __init void cpu_probe(void)
        case PRID_COMP_SANDCRAFT:
                cpu_probe_sandcraft(c);
                break;
-       case PRID_COMP_PHILIPS:
-               cpu_probe_philips(c);
+       case PRID_COMP_NXP:
+               cpu_probe_nxp(c);
                break;
        default:
                c->cputype = CPU_UNKNOWN;
@@ -950,7 +972,7 @@ __init void cpu_probe(void)
                c->srsets = 1;
 }
 
-__init void cpu_report(void)
+__cpuinit void cpu_report(void)
 {
        struct cpuinfo_mips *c = &current_cpu_data;