[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <171265368189.10875.5441043593179943891.tip-bot2@tip-bot2>
Date: Tue, 09 Apr 2024 09:08:01 -0000
From: "tip-bot2 for Tiezhu Yang" <tip-bot2@...utronix.de>
To: linux-tip-commits@...r.kernel.org
Cc: Tiezhu Yang <yangtiezhu@...ngson.cn>, Thomas Gleixner <tglx@...utronix.de>,
x86@...nel.org, linux-kernel@...r.kernel.org, maz@...nel.org
Subject: [tip: irq/core] irqchip/loongson-eiointc: Set CPU affinity only on
SMP machines for LoongArch
The following commit has been merged into the irq/core branch of tip:
Commit-ID: a64003da0ef8e135cda678eb2c8a6f0baf4a9f35
Gitweb: https://git.kernel.org/tip/a64003da0ef8e135cda678eb2c8a6f0baf4a9f35
Author: Tiezhu Yang <yangtiezhu@...ngson.cn>
AuthorDate: Tue, 26 Mar 2024 20:11:30 +08:00
Committer: Thomas Gleixner <tglx@...utronix.de>
CommitterDate: Tue, 09 Apr 2024 11:03:16 +02:00
irqchip/loongson-eiointc: Set CPU affinity only on SMP machines for LoongArch
According to the code comment of "struct irq_chip", the member
"irq_set_affinity" is to set the CPU affinity on SMP machines, so define
and call eiointc_set_irq_affinity() only under CONFIG_SMP.
Signed-off-by: Tiezhu Yang <yangtiezhu@...ngson.cn>
Signed-off-by: Thomas Gleixner <tglx@...utronix.de>
Link: https://lore.kernel.org/r/20240326121130.16622-4-yangtiezhu@loongson.cn
---
drivers/irqchip/irq-loongson-eiointc.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/drivers/irqchip/irq-loongson-eiointc.c b/drivers/irqchip/irq-loongson-eiointc.c
index b64cbe3..4f5e6d2 100644
--- a/drivers/irqchip/irq-loongson-eiointc.c
+++ b/drivers/irqchip/irq-loongson-eiointc.c
@@ -59,6 +59,7 @@ static int cpu_to_eio_node(int cpu)
return cpu_logical_map(cpu) / CORES_PER_EIO_NODE;
}
+#ifdef CONFIG_SMP
static void eiointc_set_irq_route(int pos, unsigned int cpu, unsigned int mnode, nodemask_t *node_map)
{
int i, node, cpu_node, route_node;
@@ -126,6 +127,7 @@ static int eiointc_set_irq_affinity(struct irq_data *d, const struct cpumask *af
return IRQ_SET_MASK_OK;
}
+#endif
static int eiointc_index(int node)
{
@@ -238,7 +240,9 @@ static struct irq_chip eiointc_irq_chip = {
.irq_ack = eiointc_ack_irq,
.irq_mask = eiointc_mask_irq,
.irq_unmask = eiointc_unmask_irq,
+#ifdef CONFIG_SMP
.irq_set_affinity = eiointc_set_irq_affinity,
+#endif
};
static int eiointc_domain_alloc(struct irq_domain *domain, unsigned int virq,
Powered by blists - more mailing lists