aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/irqchip
diff options
context:
space:
mode:
authorAndrew Bresticker <abrestic@chromium.org>2014-09-18 17:47:22 -0400
committerRalf Baechle <ralf@linux-mips.org>2014-11-24 01:44:55 -0500
commit14d160ab72aaa784219f733fbac6032d3494fc73 (patch)
treea292d101a0f65f3d5bf7a9e7ab5b9e25a91da856 /drivers/irqchip
parent95150ae8b330b26e93ed4a0d6e16cd597a12e13d (diff)
irqchip: mips-gic: Fix gic_set_affinity() return value
If the online CPU check in gic_set_affinity() fails, return a proper errno value instead of -1. Signed-off-by: Andrew Bresticker <abrestic@chromium.org> Acked-by: Jason Cooper <jason@lakedaemon.net> Reviewed-by: Qais Yousef <qais.yousef@imgtec.com> Tested-by: Qais Yousef <qais.yousef@imgtec.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Jeffrey Deans <jeffrey.deans@imgtec.com> Cc: Markos Chandras <markos.chandras@imgtec.com> Cc: Paul Burton <paul.burton@imgtec.com> Cc: Jonas Gorski <jogo@openwrt.org> Cc: John Crispin <blogic@openwrt.org> Cc: David Daney <ddaney.cavm@gmail.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/7814/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'drivers/irqchip')
-rw-r--r--drivers/irqchip/irq-mips-gic.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/irqchip/irq-mips-gic.c b/drivers/irqchip/irq-mips-gic.c
index 360b323a9862..f02cbf5cd8d6 100644
--- a/drivers/irqchip/irq-mips-gic.c
+++ b/drivers/irqchip/irq-mips-gic.c
@@ -309,7 +309,7 @@ static int gic_set_affinity(struct irq_data *d, const struct cpumask *cpumask,
309 309
310 cpumask_and(&tmp, cpumask, cpu_online_mask); 310 cpumask_and(&tmp, cpumask, cpu_online_mask);
311 if (cpus_empty(tmp)) 311 if (cpus_empty(tmp))
312 return -1; 312 return -EINVAL;
313 313
314 /* Assumption : cpumask refers to a single CPU */ 314 /* Assumption : cpumask refers to a single CPU */
315 spin_lock_irqsave(&gic_lock, flags); 315 spin_lock_irqsave(&gic_lock, flags);