diff options
author | Wesley W. Terpstra <wesley@sifive.com> | 2020-05-12 19:26:36 +0200 |
---|---|---|
committer | Marc Zyngier <maz@kernel.org> | 2020-05-18 11:28:30 +0200 |
commit | 82f2202ddc97490994fad0dbfec04a014fa5163d (patch) | |
tree | 1592a6284e2d9a1b2da4b49f6f99381f0ebd3ff6 /drivers/irqchip | |
parent | irqchip/gic-v3: Fix missing "__init" for gic_smp_init() (diff) | |
download | linux-82f2202ddc97490994fad0dbfec04a014fa5163d.tar.xz linux-82f2202ddc97490994fad0dbfec04a014fa5163d.zip |
irqchip/sifive-plic: Remove incorrect requirement about number of irq contexts
A PLIC may not be connected to all the cores. In that case, nr_contexts
may be less than num_possible_cpus. This requirement is only valid a single
PLIC is the only interrupt controller for the whole system.
Signed-off-by: Atish Patra <atish.patra@wdc.com>
Signed-off-by: "Wesley W. Terpstra" <wesley@sifive.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Reviewed-by: Palmer Dabbelt <palmerdabbelt@google.com>
Acked-by: Palmer Dabbelt <palmerdabbelt@google.com>
Link: https://lore.kernel.org/r/20200512172636.96299-1-atish.patra@wdc.com
[Atish: Modified the commit text]
Diffstat (limited to 'drivers/irqchip')
-rw-r--r-- | drivers/irqchip/irq-sifive-plic.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/irqchip/irq-sifive-plic.c b/drivers/irqchip/irq-sifive-plic.c index d0a71febdadc..822e074c0600 100644 --- a/drivers/irqchip/irq-sifive-plic.c +++ b/drivers/irqchip/irq-sifive-plic.c @@ -301,8 +301,6 @@ static int __init plic_init(struct device_node *node, nr_contexts = of_irq_count(node); if (WARN_ON(!nr_contexts)) goto out_iounmap; - if (WARN_ON(nr_contexts < num_possible_cpus())) - goto out_iounmap; error = -ENOMEM; priv->irqdomain = irq_domain_add_linear(node, nr_irqs + 1, |