aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/irq/manage.c
diff options
context:
space:
mode:
authorThomas Gleixner <tglx@linutronix.de>2011-02-10 16:37:41 -0500
committerThomas Gleixner <tglx@linutronix.de>2011-02-19 06:58:20 -0500
commitbce43032ad79fae0ce5b6174ce1321e643ceb54b (patch)
tree1a4725216ef2d008cbb6a23966785b58088ebf93 /kernel/irq/manage.c
parenta005677b3dd05decdd8880cf3044ae709856f58f (diff)
genirq: Reuse existing can set affinty check
Add a !desc check while at it. Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'kernel/irq/manage.c')
-rw-r--r--kernel/irq/manage.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/kernel/irq/manage.c b/kernel/irq/manage.c
index 84a0a9c22226..550ae97a0040 100644
--- a/kernel/irq/manage.c
+++ b/kernel/irq/manage.c
@@ -73,8 +73,8 @@ int irq_can_set_affinity(unsigned int irq)
73{ 73{
74 struct irq_desc *desc = irq_to_desc(irq); 74 struct irq_desc *desc = irq_to_desc(irq);
75 75
76 if (!irqd_can_balance(&desc->irq_data) || !desc->irq_data.chip || 76 if (!desc || !irqd_can_balance(&desc->irq_data) ||
77 !desc->irq_data.chip->irq_set_affinity) 77 !desc->irq_data.chip || !desc->irq_data.chip->irq_set_affinity)
78 return 0; 78 return 0;
79 79
80 return 1; 80 return 1;