diff options
Diffstat (limited to 'kernel/irq/manage.c')
-rw-r--r-- | kernel/irq/manage.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/kernel/irq/manage.c b/kernel/irq/manage.c index 550ae97a0040..8246afc81956 100644 --- a/kernel/irq/manage.c +++ b/kernel/irq/manage.c | |||
@@ -164,7 +164,8 @@ int irq_set_affinity(unsigned int irq, const struct cpumask *mask) | |||
164 | kref_get(&desc->affinity_notify->kref); | 164 | kref_get(&desc->affinity_notify->kref); |
165 | schedule_work(&desc->affinity_notify->work); | 165 | schedule_work(&desc->affinity_notify->work); |
166 | } | 166 | } |
167 | desc->status |= IRQ_AFFINITY_SET; | 167 | irq_compat_set_affinity(desc); |
168 | irqd_set(&desc->irq_data, IRQD_AFFINITY_SET); | ||
168 | raw_spin_unlock_irqrestore(&desc->lock, flags); | 169 | raw_spin_unlock_irqrestore(&desc->lock, flags); |
169 | return ret; | 170 | return ret; |
170 | } | 171 | } |
@@ -272,12 +273,14 @@ setup_affinity(unsigned int irq, struct irq_desc *desc, struct cpumask *mask) | |||
272 | * Preserve an userspace affinity setup, but make sure that | 273 | * Preserve an userspace affinity setup, but make sure that |
273 | * one of the targets is online. | 274 | * one of the targets is online. |
274 | */ | 275 | */ |
275 | if (desc->status & (IRQ_AFFINITY_SET)) { | 276 | if (irqd_has_set(&desc->irq_data, IRQD_AFFINITY_SET)) { |
276 | if (cpumask_intersects(desc->irq_data.affinity, | 277 | if (cpumask_intersects(desc->irq_data.affinity, |
277 | cpu_online_mask)) | 278 | cpu_online_mask)) |
278 | set = desc->irq_data.affinity; | 279 | set = desc->irq_data.affinity; |
279 | else | 280 | else { |
280 | desc->status &= ~IRQ_AFFINITY_SET; | 281 | irq_compat_clr_affinity(desc); |
282 | irqd_clear(&desc->irq_data, IRQD_AFFINITY_SET); | ||
283 | } | ||
281 | } | 284 | } |
282 | 285 | ||
283 | cpumask_and(mask, cpu_online_mask, set); | 286 | cpumask_and(mask, cpu_online_mask, set); |