Message ID | 20210102175859.335447-3-adam@l4re.org |
---|---|
State | New |
Headers | show |
Series | None | expand |
diff --git a/kernel/irq/msi.c b/kernel/irq/msi.c index 2c0c4d6d0f83..e1fe832e7161 100644 --- a/kernel/irq/msi.c +++ b/kernel/irq/msi.c @@ -416,7 +416,7 @@ int __msi_domain_alloc_irqs(struct irq_domain *domain, struct device *dev, virq = __irq_domain_alloc_irqs(domain, -1, desc->nvec_used, dev_to_node(dev), &arg, false, desc->affinity); - if (virq < 0) { + if (virq <= 0) { ret = -ENOSPC; if (ops->handle_error) ret = ops->handle_error(domain, desc, ret);
0 is not a proper IRQ number and also indicates failure. Signed-off-by: Adam Lackorzynski <adam@l4re.org> --- kernel/irq/msi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)