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>] [day] [month] [year] [list]
Message-ID: <160243904427.7002.9696332039937365454.tip-bot2@tip-bot2>
Date:   Sun, 11 Oct 2020 17:57:24 -0000
From:   "tip-bot2 for Marc Zyngier" <tip-bot2@...utronix.de>
To:     linux-tip-commits@...r.kernel.org
Cc:     Guillaume Tucker <guillaume.tucker@...labora.com>,
        "kernelci.org bot" <bot@...nelci.org>,
        Marc Zyngier <maz@...nel.org>, x86 <x86@...nel.org>,
        LKML <linux-kernel@...r.kernel.org>
Subject: [tip: irq/core] ARM: Handle no IPI being registered in show_ipi_list()

The following commit has been merged into the irq/core branch of tip:

Commit-ID:     220387048d859896ccc362c0ebf9bc1e0fa62eb9
Gitweb:        https://git.kernel.org/tip/220387048d859896ccc362c0ebf9bc1e0fa62eb9
Author:        Marc Zyngier <maz@...nel.org>
AuthorDate:    Fri, 25 Sep 2020 16:22:00 +01:00
Committer:     Marc Zyngier <maz@...nel.org>
CommitterDate: Mon, 28 Sep 2020 11:32:04 +01:00

ARM: Handle no IPI being registered in show_ipi_list()

As SMP-on-UP is a valid configuration on 32bit ARM, do not assume that
IPIs are populated in show_ipi_list().

Reported-by: Guillaume Tucker <guillaume.tucker@...labora.com>
Reported-by: kernelci.org bot <bot@...nelci.org>
Tested-by: Guillaume Tucker <guillaume.tucker@...labora.com>
Signed-off-by: Marc Zyngier <maz@...nel.org>
---
 arch/arm/kernel/smp.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/arch/arm/kernel/smp.c b/arch/arm/kernel/smp.c
index 8425da5..48099c6 100644
--- a/arch/arm/kernel/smp.c
+++ b/arch/arm/kernel/smp.c
@@ -541,7 +541,12 @@ void show_ipi_list(struct seq_file *p, int prec)
 	unsigned int cpu, i;
 
 	for (i = 0; i < NR_IPI; i++) {
-		unsigned int irq = irq_desc_get_irq(ipi_desc[i]);
+		unsigned int irq;
+
+		if (!ipi_desc[i])
+			continue;
+
+		irq = irq_desc_get_irq(ipi_desc[i]);
 		seq_printf(p, "%*s%u: ", prec - 1, "IPI", i);
 
 		for_each_online_cpu(cpu)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ