diff options
Diffstat (limited to 'arch/mips/kernel/smp.c')
-rw-r--r-- | arch/mips/kernel/smp.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/arch/mips/kernel/smp.c b/arch/mips/kernel/smp.c index 37708d9af638..27cb638f0824 100644 --- a/arch/mips/kernel/smp.c +++ b/arch/mips/kernel/smp.c | |||
@@ -243,6 +243,18 @@ static int __init mips_smp_ipi_init(void) | |||
243 | struct irq_domain *ipidomain; | 243 | struct irq_domain *ipidomain; |
244 | struct device_node *node; | 244 | struct device_node *node; |
245 | 245 | ||
246 | /* | ||
247 | * In some cases like qemu-malta, it is desired to try SMP with | ||
248 | * a single core. Qemu-malta has no GIC, so an attempt to set any IPIs | ||
249 | * would cause a BUG_ON() to be triggered since there's no ipidomain. | ||
250 | * | ||
251 | * Since for a single core system IPIs aren't required really, skip the | ||
252 | * initialisation which should generally keep any such configurations | ||
253 | * happy and only fail hard when trying to truely run SMP. | ||
254 | */ | ||
255 | if (cpumask_weight(cpu_possible_mask) == 1) | ||
256 | return 0; | ||
257 | |||
246 | node = of_irq_find_parent(of_root); | 258 | node = of_irq_find_parent(of_root); |
247 | ipidomain = irq_find_matching_host(node, DOMAIN_BUS_IPI); | 259 | ipidomain = irq_find_matching_host(node, DOMAIN_BUS_IPI); |
248 | 260 | ||