Commit 7281c96f authored by Akinobu Mita's avatar Akinobu Mita Committed by Ingo Molnar

x86: use cpumask_of_cpu()

Use cpumask_of_cpu() rather than the pair of cpus_clear() and cpu_set().
Signed-off-by: default avatarAkinobu Mita <akinobu.mita@gmail.com>
Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
parent addfc66b
...@@ -138,12 +138,9 @@ static cpumask_t physflat_target_cpus(void) ...@@ -138,12 +138,9 @@ static cpumask_t physflat_target_cpus(void)
static cpumask_t physflat_vector_allocation_domain(int cpu) static cpumask_t physflat_vector_allocation_domain(int cpu)
{ {
cpumask_t domain = CPU_MASK_NONE; return cpumask_of_cpu(cpu);
cpu_set(cpu, domain);
return domain;
} }
static void physflat_send_IPI_mask(cpumask_t cpumask, int vector) static void physflat_send_IPI_mask(cpumask_t cpumask, int vector)
{ {
send_IPI_mask_sequence(cpumask, vector); send_IPI_mask_sequence(cpumask, vector);
......
...@@ -1362,9 +1362,7 @@ static int ioapic_retrigger_irq(unsigned int irq) ...@@ -1362,9 +1362,7 @@ static int ioapic_retrigger_irq(unsigned int irq)
unsigned long flags; unsigned long flags;
spin_lock_irqsave(&vector_lock, flags); spin_lock_irqsave(&vector_lock, flags);
cpus_clear(mask); mask = cpumask_of_cpu(first_cpu(cfg->domain));
cpu_set(first_cpu(cfg->domain), mask);
send_IPI_mask(mask, cfg->vector); send_IPI_mask(mask, cfg->vector);
spin_unlock_irqrestore(&vector_lock, flags); spin_unlock_irqrestore(&vector_lock, flags);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment