lkml.org 
[lkml]   [2014]   [Sep]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH v2 09/16] irqchip: mips-gic: Fix gic_set_affinity() return value
Date
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>
---
No changes from v1.
---
drivers/irqchip/irq-mips-gic.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/irqchip/irq-mips-gic.c b/drivers/irqchip/irq-mips-gic.c
index 0549768..c0ff749 100644
--- a/drivers/irqchip/irq-mips-gic.c
+++ b/drivers/irqchip/irq-mips-gic.c
@@ -316,7 +316,7 @@ static int gic_set_affinity(struct irq_data *d, const struct cpumask *cpumask,

cpumask_and(&tmp, cpumask, cpu_online_mask);
if (cpus_empty(tmp))
- return -1;
+ return -EINVAL;

/* Assumption : cpumask refers to a single CPU */
spin_lock_irqsave(&gic_lock, flags);
--
2.1.0.rc2.206.gedb03e5


\
 
 \ /
  Last update: 2014-09-05 20:21    [W:0.151 / U:0.344 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site