[lkml]   [2021]   [Feb]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
Patch in this message
Subject[PATCH v1 2/2] genirq/msi: add an error print when __irq_domain_alloc_irqs() failed
During debug, we found that the return value of __irq_domain_alloc_irqs()
will be overwritten by the return value of subsequent function. As a
result, the locating clue will be lost.

To improve debug efficiency, an error message is added to print the
return value of __irq_domain_alloc_irqs().

Signed-off-by: Luo Jiaxing <>
kernel/irq/msi.c | 1 +
1 file changed, 1 insertion(+)

diff --git a/kernel/irq/msi.c b/kernel/irq/msi.c
index b338d62..f8729b0 100644
--- a/kernel/irq/msi.c
+++ b/kernel/irq/msi.c
@@ -418,6 +418,7 @@ int __msi_domain_alloc_irqs(struct irq_domain *domain, struct device *dev,
if (virq < 0) {
ret = -ENOSPC;
+ dev_err(dev, "failed to allocate irq, virq=%d\n", virq);
if (ops->handle_error)
ret = ops->handle_error(domain, desc, ret);
if (ops->msi_finish)
 \ /
  Last update: 2021-02-08 12:05    [W:0.063 / U:0.496 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site