Skip to content

Commit d2109a1

Browse files
Jiang LiuKAGA-KOKO
authored andcommitted
parisc/irq: Use access helper irq_data_get_affinity_mask()
Use access helper irq_data_get_affinity_mask() to hide implementation details of struct irq_desc. Signed-off-by: Jiang Liu <[email protected]> Cc: Konrad Rzeszutek Wilk <[email protected]> Cc: Tony Luck <[email protected]> Cc: Bjorn Helgaas <[email protected]> Cc: Benjamin Herrenschmidt <[email protected]> Cc: Randy Dunlap <[email protected]> Cc: Yinghai Lu <[email protected]> Cc: Borislav Petkov <[email protected]> Cc: James E.J. Bottomley <[email protected]> Cc: Helge Deller <[email protected]> Link: http://lkml.kernel.org/r/[email protected] Signed-off-by: Thomas Gleixner <[email protected]>
1 parent 9d03e78 commit d2109a1

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

arch/parisc/kernel/irq.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ static int cpu_set_affinity_irq(struct irq_data *d, const struct cpumask *dest,
131131
if (cpu_dest < 0)
132132
return -1;
133133

134-
cpumask_copy(d->affinity, dest);
134+
cpumask_copy(irq_data_get_affinity_mask(d), dest);
135135

136136
return 0;
137137
}
@@ -339,7 +339,7 @@ unsigned long txn_affinity_addr(unsigned int irq, int cpu)
339339
{
340340
#ifdef CONFIG_SMP
341341
struct irq_data *d = irq_get_irq_data(irq);
342-
cpumask_copy(d->affinity, cpumask_of(cpu));
342+
cpumask_copy(irq_data_get_affinity_mask(d), cpumask_of(cpu));
343343
#endif
344344

345345
return per_cpu(cpu_data, cpu).txn_addr;
@@ -508,7 +508,7 @@ void do_cpu_irq_mask(struct pt_regs *regs)
508508
unsigned long eirr_val;
509509
int irq, cpu = smp_processor_id();
510510
#ifdef CONFIG_SMP
511-
struct irq_desc *desc;
511+
struct irq_data *irq_data;
512512
cpumask_t dest;
513513
#endif
514514

@@ -522,9 +522,9 @@ void do_cpu_irq_mask(struct pt_regs *regs)
522522
irq = eirr_to_irq(eirr_val);
523523

524524
#ifdef CONFIG_SMP
525-
desc = irq_to_desc(irq);
526-
cpumask_copy(&dest, desc->irq_data.affinity);
527-
if (irqd_is_per_cpu(&desc->irq_data) &&
525+
irq_data = irq_get_irq_data(irq);
526+
cpumask_copy(&dest, irq_data_get_affinity_mask(irq_data));
527+
if (irqd_is_per_cpu(irq_data) &&
528528
!cpumask_test_cpu(smp_processor_id(), &dest)) {
529529
int cpu = cpumask_first(&dest);
530530

drivers/parisc/iosapic.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -691,7 +691,7 @@ static int iosapic_set_affinity_irq(struct irq_data *d,
691691
if (dest_cpu < 0)
692692
return -1;
693693

694-
cpumask_copy(d->affinity, cpumask_of(dest_cpu));
694+
cpumask_copy(irq_data_get_affinity_mask(d), cpumask_of(dest_cpu));
695695
vi->txn_addr = txn_affinity_addr(d->irq, dest_cpu);
696696

697697
spin_lock_irqsave(&iosapic_lock, flags);

0 commit comments

Comments
 (0)