lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Mon, 8 Feb 2021 18:58:46 +0800
From:   Luo Jiaxing <luojiaxing@...wei.com>
To:     <maz@...nel.org>
CC:     <linux-kernel@...r.kernel.org>, <linux-pci@...r.kernel.org>,
        <linuxarm@...neuler.org>
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 <luojiaxing@...wei.com>
---
 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,
 					       desc->affinity);
 		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)
-- 
2.7.4

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ