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]
Message-ID: <172304792702.2215.15469259240448673717.tip-bot2@tip-bot2>
Date: Wed, 07 Aug 2024 16:25:27 -0000
From: "tip-bot2 for Thomas Gleixner" <tip-bot2@...utronix.de>
To: linux-tip-commits@...r.kernel.org
Cc: Thomas Gleixner <tglx@...utronix.de>, Qiuxu Zhuo <qiuxu.zhuo@...el.com>,
 Breno Leitao <leitao@...ian.org>, x86@...nel.org,
 linux-kernel@...r.kernel.org
Subject:
 [tip: x86/apic] x86/ioapic: Move replace_pin_at_irq_node() to the call site

The following commit has been merged into the x86/apic branch of tip:

Commit-ID:     ee64510fb959991c3afd94e05e468a5b27e77f68
Gitweb:        https://git.kernel.org/tip/ee64510fb959991c3afd94e05e468a5b27e77f68
Author:        Thomas Gleixner <tglx@...utronix.de>
AuthorDate:    Fri, 02 Aug 2024 18:15:47 +02:00
Committer:     Thomas Gleixner <tglx@...utronix.de>
CommitterDate: Wed, 07 Aug 2024 18:13:28 +02:00

x86/ioapic: Move replace_pin_at_irq_node() to the call site

It's only used by check_timer().

Signed-off-by: Thomas Gleixner <tglx@...utronix.de>
Tested-by: Qiuxu Zhuo <qiuxu.zhuo@...el.com>
Tested-by: Breno Leitao <leitao@...ian.org>
Link: https://lore.kernel.org/all/20240802155440.906636514@linutronix.de

---
 arch/x86/kernel/apic/io_apic.c | 40 ++++++++++++++-------------------
 1 file changed, 18 insertions(+), 22 deletions(-)

diff --git a/arch/x86/kernel/apic/io_apic.c b/arch/x86/kernel/apic/io_apic.c
index 3669b5d..51ecfb5 100644
--- a/arch/x86/kernel/apic/io_apic.c
+++ b/arch/x86/kernel/apic/io_apic.c
@@ -370,28 +370,6 @@ static void __remove_pin_from_irq(struct mp_chip_data *data, int apic, int pin)
 		}
 }
 
-/*
- * Reroute an IRQ to a different pin.
- */
-static void __init replace_pin_at_irq_node(struct mp_chip_data *data, int node,
-					   int oldapic, int oldpin,
-					   int newapic, int newpin)
-{
-	struct irq_pin_list *entry;
-
-	for_each_irq_pin(entry, data->irq_2_pin) {
-		if (entry->apic == oldapic && entry->pin == oldpin) {
-			entry->apic = newapic;
-			entry->pin = newpin;
-			/* every one is different, right? */
-			return;
-		}
-	}
-
-	/* old apic/pin didn't exist, so just add new ones */
-	add_pin_to_irq_node(data, node, newapic, newpin);
-}
-
 static void io_apic_modify_irq(struct mp_chip_data *data, bool masked,
 			       void (*final)(struct irq_pin_list *entry))
 {
@@ -2067,6 +2045,24 @@ static int __init mp_alloc_timer_irq(int ioapic, int pin)
 	return irq;
 }
 
+static void __init replace_pin_at_irq_node(struct mp_chip_data *data, int node,
+					   int oldapic, int oldpin,
+					   int newapic, int newpin)
+{
+	struct irq_pin_list *entry;
+
+	for_each_irq_pin(entry, data->irq_2_pin) {
+		if (entry->apic == oldapic && entry->pin == oldpin) {
+			entry->apic = newapic;
+			entry->pin = newpin;
+			return;
+		}
+	}
+
+	/* Old apic/pin didn't exist, so just add a new one */
+	add_pin_to_irq_node(data, node, newapic, newpin);
+}
+
 /*
  * This code may look a bit paranoid, but it's supposed to cooperate with
  * a wide range of boards and BIOS bugs.  Fortunately only the timer IRQ

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ