diff options
Diffstat (limited to 'arch/mips/mti-malta/malta-init.c')
-rw-r--r-- | arch/mips/mti-malta/malta-init.c | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/arch/mips/mti-malta/malta-init.c b/arch/mips/mti-malta/malta-init.c index 475038a141a6..27c807b67fea 100644 --- a/arch/mips/mti-malta/malta-init.c +++ b/arch/mips/mti-malta/malta-init.c | |||
@@ -30,6 +30,7 @@ | |||
30 | #include <asm/cacheflush.h> | 30 | #include <asm/cacheflush.h> |
31 | #include <asm/traps.h> | 31 | #include <asm/traps.h> |
32 | 32 | ||
33 | #include <asm/gcmpregs.h> | ||
33 | #include <asm/mips-boards/prom.h> | 34 | #include <asm/mips-boards/prom.h> |
34 | #include <asm/mips-boards/generic.h> | 35 | #include <asm/mips-boards/generic.h> |
35 | #include <asm/mips-boards/bonito64.h> | 36 | #include <asm/mips-boards/bonito64.h> |
@@ -192,6 +193,8 @@ extern struct plat_smp_ops msmtc_smp_ops; | |||
192 | 193 | ||
193 | void __init prom_init(void) | 194 | void __init prom_init(void) |
194 | { | 195 | { |
196 | int result; | ||
197 | |||
195 | prom_argc = fw_arg0; | 198 | prom_argc = fw_arg0; |
196 | _prom_argv = (int *) fw_arg1; | 199 | _prom_argv = (int *) fw_arg1; |
197 | _prom_envp = (int *) fw_arg2; | 200 | _prom_envp = (int *) fw_arg2; |
@@ -358,12 +361,21 @@ void __init prom_init(void) | |||
358 | #ifdef CONFIG_SERIAL_8250_CONSOLE | 361 | #ifdef CONFIG_SERIAL_8250_CONSOLE |
359 | console_config(); | 362 | console_config(); |
360 | #endif | 363 | #endif |
364 | /* Early detection of CMP support */ | ||
365 | result = gcmp_probe(GCMP_BASE_ADDR, GCMP_ADDRSPACE_SZ); | ||
366 | |||
361 | #ifdef CONFIG_MIPS_CMP | 367 | #ifdef CONFIG_MIPS_CMP |
362 | register_smp_ops(&cmp_smp_ops); | 368 | if (result) |
369 | register_smp_ops(&cmp_smp_ops); | ||
363 | #endif | 370 | #endif |
364 | #ifdef CONFIG_MIPS_MT_SMP | 371 | #ifdef CONFIG_MIPS_MT_SMP |
372 | #ifdef CONFIG_MIPS_CMP | ||
373 | if (!result) | ||
374 | register_smp_ops(&vsmp_smp_ops); | ||
375 | #else | ||
365 | register_smp_ops(&vsmp_smp_ops); | 376 | register_smp_ops(&vsmp_smp_ops); |
366 | #endif | 377 | #endif |
378 | #endif | ||
367 | #ifdef CONFIG_MIPS_MT_SMTC | 379 | #ifdef CONFIG_MIPS_MT_SMTC |
368 | register_smp_ops(&msmtc_smp_ops); | 380 | register_smp_ops(&msmtc_smp_ops); |
369 | #endif | 381 | #endif |