mirror of
https://github.com/torvalds/linux.git
synced 2024-11-10 22:21:40 +00:00
Merge git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux-2.6-cpumask
* git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux-2.6-cpumask: oprofile: Thou shalt not call __exit functions from __init functions cpumask: remove the now-obsoleted pcibus_to_cpumask(): generic cpumask: remove cpumask_t from core cpumask: convert rcutorture.c cpumask: use new cpumask_ functions in core code. cpumask: remove references to struct irqaction's mask field. cpumask: use mm_cpumask() wrapper: kernel/fork.c cpumask: use set_cpu_active in init/main.c cpumask: remove node_to_first_cpu cpumask: fix seq_bitmap_*() functions. cpumask: remove dangerous CPU_MASK_ALL_PTR, &CPU_MASK_ALL
This commit is contained in:
commit
d17abcd541
@ -261,7 +261,6 @@ timer_interrupt(int irq, void *dev_id)
|
|||||||
static struct irqaction irq2 = {
|
static struct irqaction irq2 = {
|
||||||
.handler = timer_interrupt,
|
.handler = timer_interrupt,
|
||||||
.flags = IRQF_SHARED | IRQF_DISABLED,
|
.flags = IRQF_SHARED | IRQF_DISABLED,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "timer",
|
.name = "timer",
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -65,7 +65,6 @@ static int send_ipi(int vector, int wait, cpumask_t cpu_mask);
|
|||||||
static struct irqaction irq_ipi = {
|
static struct irqaction irq_ipi = {
|
||||||
.handler = crisv32_ipi_interrupt,
|
.handler = crisv32_ipi_interrupt,
|
||||||
.flags = IRQF_DISABLED,
|
.flags = IRQF_DISABLED,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "ipi",
|
.name = "ipi",
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -267,7 +267,6 @@ timer_interrupt(int irq, void *dev_id)
|
|||||||
static struct irqaction irq_timer = {
|
static struct irqaction irq_timer = {
|
||||||
.handler = timer_interrupt,
|
.handler = timer_interrupt,
|
||||||
.flags = IRQF_SHARED | IRQF_DISABLED,
|
.flags = IRQF_SHARED | IRQF_DISABLED,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "timer"
|
.name = "timer"
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -109,28 +109,24 @@ static struct irqaction fpga_irq[4] = {
|
|||||||
[0] = {
|
[0] = {
|
||||||
.handler = fpga_interrupt,
|
.handler = fpga_interrupt,
|
||||||
.flags = IRQF_DISABLED | IRQF_SHARED,
|
.flags = IRQF_DISABLED | IRQF_SHARED,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "fpga.0",
|
.name = "fpga.0",
|
||||||
.dev_id = (void *) 0x0028UL,
|
.dev_id = (void *) 0x0028UL,
|
||||||
},
|
},
|
||||||
[1] = {
|
[1] = {
|
||||||
.handler = fpga_interrupt,
|
.handler = fpga_interrupt,
|
||||||
.flags = IRQF_DISABLED | IRQF_SHARED,
|
.flags = IRQF_DISABLED | IRQF_SHARED,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "fpga.1",
|
.name = "fpga.1",
|
||||||
.dev_id = (void *) 0x0050UL,
|
.dev_id = (void *) 0x0050UL,
|
||||||
},
|
},
|
||||||
[2] = {
|
[2] = {
|
||||||
.handler = fpga_interrupt,
|
.handler = fpga_interrupt,
|
||||||
.flags = IRQF_DISABLED | IRQF_SHARED,
|
.flags = IRQF_DISABLED | IRQF_SHARED,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "fpga.2",
|
.name = "fpga.2",
|
||||||
.dev_id = (void *) 0x1c00UL,
|
.dev_id = (void *) 0x1c00UL,
|
||||||
},
|
},
|
||||||
[3] = {
|
[3] = {
|
||||||
.handler = fpga_interrupt,
|
.handler = fpga_interrupt,
|
||||||
.flags = IRQF_DISABLED | IRQF_SHARED,
|
.flags = IRQF_DISABLED | IRQF_SHARED,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "fpga.3",
|
.name = "fpga.3",
|
||||||
.dev_id = (void *) 0x6386UL,
|
.dev_id = (void *) 0x6386UL,
|
||||||
}
|
}
|
||||||
|
@ -108,7 +108,6 @@ static struct irqaction fpga_irq[1] = {
|
|||||||
[0] = {
|
[0] = {
|
||||||
.handler = fpga_interrupt,
|
.handler = fpga_interrupt,
|
||||||
.flags = IRQF_DISABLED,
|
.flags = IRQF_DISABLED,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "fpga.0",
|
.name = "fpga.0",
|
||||||
.dev_id = (void *) 0x0700UL,
|
.dev_id = (void *) 0x0700UL,
|
||||||
}
|
}
|
||||||
|
@ -120,14 +120,12 @@ static struct irqaction mb93493_irq[2] = {
|
|||||||
[0] = {
|
[0] = {
|
||||||
.handler = mb93493_interrupt,
|
.handler = mb93493_interrupt,
|
||||||
.flags = IRQF_DISABLED | IRQF_SHARED,
|
.flags = IRQF_DISABLED | IRQF_SHARED,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "mb93493.0",
|
.name = "mb93493.0",
|
||||||
.dev_id = (void *) __addr_MB93493_IQSR(0),
|
.dev_id = (void *) __addr_MB93493_IQSR(0),
|
||||||
},
|
},
|
||||||
[1] = {
|
[1] = {
|
||||||
.handler = mb93493_interrupt,
|
.handler = mb93493_interrupt,
|
||||||
.flags = IRQF_DISABLED | IRQF_SHARED,
|
.flags = IRQF_DISABLED | IRQF_SHARED,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "mb93493.1",
|
.name = "mb93493.1",
|
||||||
.dev_id = (void *) __addr_MB93493_IQSR(1),
|
.dev_id = (void *) __addr_MB93493_IQSR(1),
|
||||||
}
|
}
|
||||||
|
@ -45,7 +45,6 @@ static irqreturn_t timer_interrupt(int irq, void *dummy);
|
|||||||
static struct irqaction timer_irq = {
|
static struct irqaction timer_irq = {
|
||||||
.handler = timer_interrupt,
|
.handler = timer_interrupt,
|
||||||
.flags = IRQF_DISABLED,
|
.flags = IRQF_DISABLED,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "timer",
|
.name = "timer",
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -60,7 +60,6 @@ static struct irqaction itu_irq = {
|
|||||||
.name = "itu",
|
.name = "itu",
|
||||||
.handler = timer_interrupt,
|
.handler = timer_interrupt,
|
||||||
.flags = IRQF_DISABLED | IRQF_TIMER,
|
.flags = IRQF_DISABLED | IRQF_TIMER,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
};
|
};
|
||||||
|
|
||||||
static const int __initdata divide_rate[] = {1, 2, 4, 8};
|
static const int __initdata divide_rate[] = {1, 2, 4, 8};
|
||||||
|
@ -55,7 +55,6 @@ static struct irqaction timer16_irq = {
|
|||||||
.name = "timer-16",
|
.name = "timer-16",
|
||||||
.handler = timer_interrupt,
|
.handler = timer_interrupt,
|
||||||
.flags = IRQF_DISABLED | IRQF_TIMER,
|
.flags = IRQF_DISABLED | IRQF_TIMER,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
};
|
};
|
||||||
|
|
||||||
static const int __initdata divide_rate[] = {1, 2, 4, 8};
|
static const int __initdata divide_rate[] = {1, 2, 4, 8};
|
||||||
|
@ -75,7 +75,6 @@ static struct irqaction timer8_irq = {
|
|||||||
.name = "timer-8",
|
.name = "timer-8",
|
||||||
.handler = timer_interrupt,
|
.handler = timer_interrupt,
|
||||||
.flags = IRQF_DISABLED | IRQF_TIMER,
|
.flags = IRQF_DISABLED | IRQF_TIMER,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
};
|
};
|
||||||
|
|
||||||
static const int __initdata divide_rate[] = {8, 64, 8192};
|
static const int __initdata divide_rate[] = {8, 64, 8192};
|
||||||
|
@ -65,7 +65,6 @@ static struct irqaction tpu_irq = {
|
|||||||
.name = "tpu",
|
.name = "tpu",
|
||||||
.handler = timer_interrupt,
|
.handler = timer_interrupt,
|
||||||
.flags = IRQF_DISABLED | IRQF_TIMER,
|
.flags = IRQF_DISABLED | IRQF_TIMER,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
};
|
};
|
||||||
|
|
||||||
const static int __initdata divide_rate[] = {
|
const static int __initdata divide_rate[] = {
|
||||||
|
@ -43,11 +43,6 @@
|
|||||||
*/
|
*/
|
||||||
#define parent_node(nid) (nid)
|
#define parent_node(nid) (nid)
|
||||||
|
|
||||||
/*
|
|
||||||
* Returns the number of the first CPU on Node 'node'.
|
|
||||||
*/
|
|
||||||
#define node_to_first_cpu(node) (cpumask_first(cpumask_of_node(node)))
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Determines the node for a given pci bus
|
* Determines the node for a given pci bus
|
||||||
*/
|
*/
|
||||||
|
@ -230,7 +230,6 @@ static irqreturn_t timer_interrupt(int irq, void *dev_id)
|
|||||||
static struct irqaction irq0 = {
|
static struct irqaction irq0 = {
|
||||||
.handler = timer_interrupt,
|
.handler = timer_interrupt,
|
||||||
.flags = IRQF_DISABLED,
|
.flags = IRQF_DISABLED,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "MFT2",
|
.name = "MFT2",
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -47,7 +47,6 @@ asmlinkage void plat_irq_dispatch(void)
|
|||||||
|
|
||||||
static struct irqaction cascade = {
|
static struct irqaction cascade = {
|
||||||
.handler = no_action,
|
.handler = no_action,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "cascade",
|
.name = "cascade",
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -186,7 +186,6 @@ void emma2rh_gpio_irq_init(void)
|
|||||||
static struct irqaction irq_cascade = {
|
static struct irqaction irq_cascade = {
|
||||||
.handler = no_action,
|
.handler = no_action,
|
||||||
.flags = 0,
|
.flags = 0,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "cascade",
|
.name = "cascade",
|
||||||
.dev_id = NULL,
|
.dev_id = NULL,
|
||||||
.next = NULL,
|
.next = NULL,
|
||||||
|
@ -26,7 +26,6 @@ extern struct cpuinfo_ip27 sn_cpu_info[NR_CPUS];
|
|||||||
#define parent_node(node) (node)
|
#define parent_node(node) (node)
|
||||||
#define node_to_cpumask(node) (hub_data(node)->h_cpus)
|
#define node_to_cpumask(node) (hub_data(node)->h_cpus)
|
||||||
#define cpumask_of_node(node) (&hub_data(node)->h_cpus)
|
#define cpumask_of_node(node) (&hub_data(node)->h_cpus)
|
||||||
#define node_to_first_cpu(node) (cpumask_first(cpumask_of_node(node)))
|
|
||||||
struct pci_bus;
|
struct pci_bus;
|
||||||
extern int pcibus_to_node(struct pci_bus *);
|
extern int pcibus_to_node(struct pci_bus *);
|
||||||
|
|
||||||
|
@ -134,7 +134,6 @@ static irqreturn_t r4030_timer_interrupt(int irq, void *dev_id)
|
|||||||
static struct irqaction r4030_timer_irqaction = {
|
static struct irqaction r4030_timer_irqaction = {
|
||||||
.handler = r4030_timer_interrupt,
|
.handler = r4030_timer_interrupt,
|
||||||
.flags = IRQF_DISABLED,
|
.flags = IRQF_DISABLED,
|
||||||
.mask = CPU_MASK_CPU0,
|
|
||||||
.name = "R4030 timer",
|
.name = "R4030 timer",
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -144,7 +144,6 @@ void __cpuinit sb1480_clockevent_init(void)
|
|||||||
|
|
||||||
action->handler = sibyte_counter_handler;
|
action->handler = sibyte_counter_handler;
|
||||||
action->flags = IRQF_DISABLED | IRQF_PERCPU;
|
action->flags = IRQF_DISABLED | IRQF_PERCPU;
|
||||||
action->mask = cpumask_of_cpu(cpu);
|
|
||||||
action->name = name;
|
action->name = name;
|
||||||
action->dev_id = cd;
|
action->dev_id = cd;
|
||||||
|
|
||||||
|
@ -143,7 +143,6 @@ void __cpuinit sb1250_clockevent_init(void)
|
|||||||
|
|
||||||
action->handler = sibyte_counter_handler;
|
action->handler = sibyte_counter_handler;
|
||||||
action->flags = IRQF_DISABLED | IRQF_PERCPU;
|
action->flags = IRQF_DISABLED | IRQF_PERCPU;
|
||||||
action->mask = cpumask_of_cpu(cpu);
|
|
||||||
action->name = name;
|
action->name = name;
|
||||||
action->dev_id = cd;
|
action->dev_id = cd;
|
||||||
|
|
||||||
|
@ -98,7 +98,6 @@ static irqreturn_t timer_interrupt(int irq, void *dev_id)
|
|||||||
static struct irqaction irq0 = {
|
static struct irqaction irq0 = {
|
||||||
.handler = timer_interrupt,
|
.handler = timer_interrupt,
|
||||||
.flags = IRQF_DISABLED | IRQF_NOBALANCING,
|
.flags = IRQF_DISABLED | IRQF_NOBALANCING,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "timer"
|
.name = "timer"
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -121,7 +120,6 @@ void __init setup_pit_timer(void)
|
|||||||
cd->min_delta_ns = clockevent_delta2ns(0xF, cd);
|
cd->min_delta_ns = clockevent_delta2ns(0xF, cd);
|
||||||
clockevents_register_device(cd);
|
clockevents_register_device(cd);
|
||||||
|
|
||||||
irq0.mask = cpumask_of_cpu(cpu);
|
|
||||||
setup_irq(0, &irq0);
|
setup_irq(0, &irq0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -306,7 +306,6 @@ static void init_8259A(int auto_eoi)
|
|||||||
*/
|
*/
|
||||||
static struct irqaction irq2 = {
|
static struct irqaction irq2 = {
|
||||||
.handler = no_action,
|
.handler = no_action,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "cascade",
|
.name = "cascade",
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -104,7 +104,6 @@ asmlinkage void plat_irq_dispatch(void)
|
|||||||
|
|
||||||
static struct irqaction cascade = {
|
static struct irqaction cascade = {
|
||||||
.handler = no_action,
|
.handler = no_action,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "cascade",
|
.name = "cascade",
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -92,7 +92,6 @@ asmlinkage void plat_irq_dispatch(void)
|
|||||||
|
|
||||||
static struct irqaction cascade_irqaction = {
|
static struct irqaction cascade_irqaction = {
|
||||||
.handler = no_action,
|
.handler = no_action,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "cascade",
|
.name = "cascade",
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -219,7 +219,7 @@ cont_nmi_dump(void)
|
|||||||
if (i == 1000) {
|
if (i == 1000) {
|
||||||
for_each_online_node(node)
|
for_each_online_node(node)
|
||||||
if (NODEPDA(node)->dump_count == 0) {
|
if (NODEPDA(node)->dump_count == 0) {
|
||||||
cpu = node_to_first_cpu(node);
|
cpu = cpumask_first(cpumask_of_node(node));
|
||||||
for (n=0; n < CNODE_NUM_CPUS(node); cpu++, n++) {
|
for (n=0; n < CNODE_NUM_CPUS(node); cpu++, n++) {
|
||||||
CPUMASK_SETB(nmied_cpus, cpu);
|
CPUMASK_SETB(nmied_cpus, cpu);
|
||||||
/*
|
/*
|
||||||
|
@ -115,14 +115,12 @@ extern irqreturn_t crime_cpuerr_intr(int irq, void *dev_id);
|
|||||||
struct irqaction memerr_irq = {
|
struct irqaction memerr_irq = {
|
||||||
.handler = crime_memerr_intr,
|
.handler = crime_memerr_intr,
|
||||||
.flags = IRQF_DISABLED,
|
.flags = IRQF_DISABLED,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "CRIME memory error",
|
.name = "CRIME memory error",
|
||||||
};
|
};
|
||||||
|
|
||||||
struct irqaction cpuerr_irq = {
|
struct irqaction cpuerr_irq = {
|
||||||
.handler = crime_cpuerr_intr,
|
.handler = crime_cpuerr_intr,
|
||||||
.flags = IRQF_DISABLED,
|
.flags = IRQF_DISABLED,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "CRIME CPU error",
|
.name = "CRIME CPU error",
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -359,7 +359,8 @@ void sni_rm200_init_8259A(void)
|
|||||||
* IRQ2 is cascade interrupt to second interrupt controller
|
* IRQ2 is cascade interrupt to second interrupt controller
|
||||||
*/
|
*/
|
||||||
static struct irqaction sni_rm200_irq2 = {
|
static struct irqaction sni_rm200_irq2 = {
|
||||||
no_action, 0, CPU_MASK_NONE, "cascade", NULL, NULL
|
.handler = no_action,
|
||||||
|
.name = "cascade",
|
||||||
};
|
};
|
||||||
|
|
||||||
static struct resource sni_rm200_pic1_resource = {
|
static struct resource sni_rm200_pic1_resource = {
|
||||||
|
@ -32,7 +32,6 @@ static irq_cascade_t irq_cascade[NR_IRQS] __cacheline_aligned;
|
|||||||
|
|
||||||
static struct irqaction cascade_irqaction = {
|
static struct irqaction cascade_irqaction = {
|
||||||
.handler = no_action,
|
.handler = no_action,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "cascade",
|
.name = "cascade",
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -37,7 +37,6 @@ static irqreturn_t timer_interrupt(int irq, void *dev_id);
|
|||||||
static struct irqaction timer_irq = {
|
static struct irqaction timer_irq = {
|
||||||
.handler = timer_interrupt,
|
.handler = timer_interrupt,
|
||||||
.flags = IRQF_DISABLED | IRQF_SHARED | IRQF_TIMER,
|
.flags = IRQF_DISABLED | IRQF_SHARED | IRQF_TIMER,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "timer",
|
.name = "timer",
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -24,11 +24,6 @@ static inline cpumask_t node_to_cpumask(int node)
|
|||||||
|
|
||||||
#define cpumask_of_node(node) (&numa_cpumask_lookup_table[node])
|
#define cpumask_of_node(node) (&numa_cpumask_lookup_table[node])
|
||||||
|
|
||||||
static inline int node_to_first_cpu(int node)
|
|
||||||
{
|
|
||||||
return cpumask_first(cpumask_of_node(node));
|
|
||||||
}
|
|
||||||
|
|
||||||
int of_node_to_nid(struct device_node *device);
|
int of_node_to_nid(struct device_node *device);
|
||||||
|
|
||||||
struct pci_bus;
|
struct pci_bus;
|
||||||
|
@ -179,7 +179,6 @@ static irqreturn_t mpc85xx_8259_cascade_action(int irq, void *dev_id)
|
|||||||
static struct irqaction mpc85xxcds_8259_irqaction = {
|
static struct irqaction mpc85xxcds_8259_irqaction = {
|
||||||
.handler = mpc85xx_8259_cascade_action,
|
.handler = mpc85xx_8259_cascade_action,
|
||||||
.flags = IRQF_SHARED,
|
.flags = IRQF_SHARED,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "8259 cascade",
|
.name = "8259 cascade",
|
||||||
};
|
};
|
||||||
#endif /* PPC_I8259 */
|
#endif /* PPC_I8259 */
|
||||||
|
@ -44,7 +44,6 @@ static irqreturn_t timebase_interrupt(int irq, void *dev)
|
|||||||
|
|
||||||
static struct irqaction tbint_irqaction = {
|
static struct irqaction tbint_irqaction = {
|
||||||
.handler = timebase_interrupt,
|
.handler = timebase_interrupt,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "tbint",
|
.name = "tbint",
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -472,7 +472,6 @@ static void __init chrp_find_openpic(void)
|
|||||||
#if defined(CONFIG_VT) && defined(CONFIG_INPUT_ADBHID) && defined(CONFIG_XMON)
|
#if defined(CONFIG_VT) && defined(CONFIG_INPUT_ADBHID) && defined(CONFIG_XMON)
|
||||||
static struct irqaction xmon_irqaction = {
|
static struct irqaction xmon_irqaction = {
|
||||||
.handler = xmon_irq,
|
.handler = xmon_irq,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "XMON break",
|
.name = "XMON break",
|
||||||
};
|
};
|
||||||
#endif
|
#endif
|
||||||
|
@ -266,7 +266,6 @@ static unsigned int pmac_pic_get_irq(void)
|
|||||||
static struct irqaction xmon_action = {
|
static struct irqaction xmon_action = {
|
||||||
.handler = xmon_irq,
|
.handler = xmon_irq,
|
||||||
.flags = 0,
|
.flags = 0,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "NMI - XMON"
|
.name = "NMI - XMON"
|
||||||
};
|
};
|
||||||
#endif
|
#endif
|
||||||
@ -274,7 +273,6 @@ static struct irqaction xmon_action = {
|
|||||||
static struct irqaction gatwick_cascade_action = {
|
static struct irqaction gatwick_cascade_action = {
|
||||||
.handler = gatwick_action,
|
.handler = gatwick_action,
|
||||||
.flags = IRQF_DISABLED,
|
.flags = IRQF_DISABLED,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "cascade",
|
.name = "cascade",
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -385,7 +385,6 @@ static void __init psurge_dual_sync_tb(int cpu_nr)
|
|||||||
static struct irqaction psurge_irqaction = {
|
static struct irqaction psurge_irqaction = {
|
||||||
.handler = psurge_primary_intr,
|
.handler = psurge_primary_intr,
|
||||||
.flags = IRQF_DISABLED,
|
.flags = IRQF_DISABLED,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "primary IPI",
|
.name = "primary IPI",
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -119,7 +119,6 @@ static irqreturn_t cpm_error_interrupt(int irq, void *dev)
|
|||||||
|
|
||||||
static struct irqaction cpm_error_irqaction = {
|
static struct irqaction cpm_error_irqaction = {
|
||||||
.handler = cpm_error_interrupt,
|
.handler = cpm_error_interrupt,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "error",
|
.name = "error",
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -33,7 +33,6 @@
|
|||||||
|
|
||||||
#define node_to_cpumask(node) ((void)node, cpu_online_map)
|
#define node_to_cpumask(node) ((void)node, cpu_online_map)
|
||||||
#define cpumask_of_node(node) ((void)node, cpu_online_mask)
|
#define cpumask_of_node(node) ((void)node, cpu_online_mask)
|
||||||
#define node_to_first_cpu(node) ((void)(node),0)
|
|
||||||
|
|
||||||
#define pcibus_to_node(bus) ((void)(bus), -1)
|
#define pcibus_to_node(bus) ((void)(bus), -1)
|
||||||
#define pcibus_to_cpumask(bus) (pcibus_to_node(bus) == -1 ? \
|
#define pcibus_to_cpumask(bus) (pcibus_to_node(bus) == -1 ? \
|
||||||
|
@ -284,7 +284,6 @@ static irqreturn_t timer_interrupt(int irq, void *dev_id)
|
|||||||
static struct irqaction irq0 = {
|
static struct irqaction irq0 = {
|
||||||
.handler = timer_interrupt,
|
.handler = timer_interrupt,
|
||||||
.flags = IRQF_DISABLED,
|
.flags = IRQF_DISABLED,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "timer",
|
.name = "timer",
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -109,7 +109,6 @@ static struct irqaction cmt_irq = {
|
|||||||
.name = "timer",
|
.name = "timer",
|
||||||
.handler = cmt_timer_interrupt,
|
.handler = cmt_timer_interrupt,
|
||||||
.flags = IRQF_DISABLED | IRQF_TIMER | IRQF_IRQPOLL,
|
.flags = IRQF_DISABLED | IRQF_TIMER | IRQF_IRQPOLL,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
};
|
};
|
||||||
|
|
||||||
static void cmt_clk_init(struct clk *clk)
|
static void cmt_clk_init(struct clk *clk)
|
||||||
|
@ -115,7 +115,6 @@ static struct irqaction mtu2_irq = {
|
|||||||
.name = "timer",
|
.name = "timer",
|
||||||
.handler = mtu2_timer_interrupt,
|
.handler = mtu2_timer_interrupt,
|
||||||
.flags = IRQF_DISABLED | IRQF_TIMER | IRQF_IRQPOLL,
|
.flags = IRQF_DISABLED | IRQF_TIMER | IRQF_IRQPOLL,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
};
|
};
|
||||||
|
|
||||||
static unsigned int divisors[] = { 1, 4, 16, 64, 1, 1, 256 };
|
static unsigned int divisors[] = { 1, 4, 16, 64, 1, 1, 256 };
|
||||||
|
@ -162,7 +162,6 @@ static struct irqaction tmu0_irq = {
|
|||||||
.name = "periodic/oneshot timer",
|
.name = "periodic/oneshot timer",
|
||||||
.handler = tmu_timer_interrupt,
|
.handler = tmu_timer_interrupt,
|
||||||
.flags = IRQF_DISABLED | IRQF_TIMER | IRQF_IRQPOLL,
|
.flags = IRQF_DISABLED | IRQF_TIMER | IRQF_IRQPOLL,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
};
|
};
|
||||||
|
|
||||||
static void __init tmu_clk_init(struct clk *clk)
|
static void __init tmu_clk_init(struct clk *clk)
|
||||||
|
@ -28,11 +28,6 @@ static inline cpumask_t node_to_cpumask(int node)
|
|||||||
#define node_to_cpumask_ptr_next(v, node) \
|
#define node_to_cpumask_ptr_next(v, node) \
|
||||||
v = &(numa_cpumask_lookup_table[node])
|
v = &(numa_cpumask_lookup_table[node])
|
||||||
|
|
||||||
static inline int node_to_first_cpu(int node)
|
|
||||||
{
|
|
||||||
return cpumask_first(cpumask_of_node(node));
|
|
||||||
}
|
|
||||||
|
|
||||||
struct pci_bus;
|
struct pci_bus;
|
||||||
#ifdef CONFIG_PCI
|
#ifdef CONFIG_PCI
|
||||||
extern int pcibus_to_node(struct pci_bus *pbus);
|
extern int pcibus_to_node(struct pci_bus *pbus);
|
||||||
|
@ -439,7 +439,6 @@ static int request_fast_irq(unsigned int irq,
|
|||||||
flush_cache_all();
|
flush_cache_all();
|
||||||
|
|
||||||
action->flags = irqflags;
|
action->flags = irqflags;
|
||||||
cpus_clear(action->mask);
|
|
||||||
action->name = devname;
|
action->name = devname;
|
||||||
action->dev_id = NULL;
|
action->dev_id = NULL;
|
||||||
action->next = NULL;
|
action->next = NULL;
|
||||||
@ -574,7 +573,6 @@ int request_irq(unsigned int irq,
|
|||||||
|
|
||||||
action->handler = handler;
|
action->handler = handler;
|
||||||
action->flags = irqflags;
|
action->flags = irqflags;
|
||||||
cpus_clear(action->mask);
|
|
||||||
action->name = devname;
|
action->name = devname;
|
||||||
action->next = NULL;
|
action->next = NULL;
|
||||||
action->dev_id = dev_id;
|
action->dev_id = dev_id;
|
||||||
|
@ -326,7 +326,6 @@ int sun4d_request_irq(unsigned int irq,
|
|||||||
|
|
||||||
action->handler = handler;
|
action->handler = handler;
|
||||||
action->flags = irqflags;
|
action->flags = irqflags;
|
||||||
cpus_clear(action->mask);
|
|
||||||
action->name = devname;
|
action->name = devname;
|
||||||
action->next = NULL;
|
action->next = NULL;
|
||||||
action->dev_id = dev_id;
|
action->dev_id = dev_id;
|
||||||
|
@ -217,10 +217,6 @@ static inline cpumask_t node_to_cpumask(int node)
|
|||||||
{
|
{
|
||||||
return cpu_online_map;
|
return cpu_online_map;
|
||||||
}
|
}
|
||||||
static inline int node_to_first_cpu(int node)
|
|
||||||
{
|
|
||||||
return first_cpu(cpu_online_map);
|
|
||||||
}
|
|
||||||
|
|
||||||
static inline void setup_node_to_cpumask_map(void) { }
|
static inline void setup_node_to_cpumask_map(void) { }
|
||||||
|
|
||||||
@ -237,14 +233,6 @@ static inline void setup_node_to_cpumask_map(void) { }
|
|||||||
|
|
||||||
#include <asm-generic/topology.h>
|
#include <asm-generic/topology.h>
|
||||||
|
|
||||||
#ifdef CONFIG_NUMA
|
|
||||||
/* Returns the number of the first CPU on Node 'node'. */
|
|
||||||
static inline int node_to_first_cpu(int node)
|
|
||||||
{
|
|
||||||
return cpumask_first(cpumask_of_node(node));
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
extern cpumask_t cpu_coregroup_map(int cpu);
|
extern cpumask_t cpu_coregroup_map(int cpu);
|
||||||
extern const struct cpumask *cpu_coregroup_mask(int cpu);
|
extern const struct cpumask *cpu_coregroup_mask(int cpu);
|
||||||
|
|
||||||
|
@ -50,7 +50,6 @@ static irqreturn_t math_error_irq(int cpl, void *dev_id)
|
|||||||
*/
|
*/
|
||||||
static struct irqaction fpu_irq = {
|
static struct irqaction fpu_irq = {
|
||||||
.handler = math_error_irq,
|
.handler = math_error_irq,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "fpu",
|
.name = "fpu",
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -83,7 +82,6 @@ void __init init_ISA_irqs(void)
|
|||||||
*/
|
*/
|
||||||
static struct irqaction irq2 = {
|
static struct irqaction irq2 = {
|
||||||
.handler = no_action,
|
.handler = no_action,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "cascade",
|
.name = "cascade",
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -45,7 +45,6 @@
|
|||||||
|
|
||||||
static struct irqaction irq2 = {
|
static struct irqaction irq2 = {
|
||||||
.handler = no_action,
|
.handler = no_action,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "cascade",
|
.name = "cascade",
|
||||||
};
|
};
|
||||||
DEFINE_PER_CPU(vector_irq_t, vector_irq) = {
|
DEFINE_PER_CPU(vector_irq_t, vector_irq) = {
|
||||||
|
@ -348,7 +348,6 @@ static irqreturn_t mfgpt_tick(int irq, void *dev_id)
|
|||||||
static struct irqaction mfgptirq = {
|
static struct irqaction mfgptirq = {
|
||||||
.handler = mfgpt_tick,
|
.handler = mfgpt_tick,
|
||||||
.flags = IRQF_DISABLED | IRQF_NOBALANCING,
|
.flags = IRQF_DISABLED | IRQF_NOBALANCING,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "mfgpt-timer"
|
.name = "mfgpt-timer"
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -1049,7 +1049,6 @@ void __init x86_quirk_trap_init(void)
|
|||||||
static struct irqaction irq0 = {
|
static struct irqaction irq0 = {
|
||||||
.handler = timer_interrupt,
|
.handler = timer_interrupt,
|
||||||
.flags = IRQF_DISABLED | IRQF_NOBALANCING | IRQF_IRQPOLL | IRQF_TIMER,
|
.flags = IRQF_DISABLED | IRQF_NOBALANCING | IRQF_IRQPOLL | IRQF_TIMER,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "timer"
|
.name = "timer"
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -116,7 +116,6 @@ unsigned long __init calibrate_cpu(void)
|
|||||||
static struct irqaction irq0 = {
|
static struct irqaction irq0 = {
|
||||||
.handler = timer_interrupt,
|
.handler = timer_interrupt,
|
||||||
.flags = IRQF_DISABLED | IRQF_IRQPOLL | IRQF_NOBALANCING | IRQF_TIMER,
|
.flags = IRQF_DISABLED | IRQF_IRQPOLL | IRQF_NOBALANCING | IRQF_TIMER,
|
||||||
.mask = CPU_MASK_NONE,
|
|
||||||
.name = "timer"
|
.name = "timer"
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -125,7 +124,6 @@ void __init hpet_time_init(void)
|
|||||||
if (!hpet_enable())
|
if (!hpet_enable())
|
||||||
setup_pit_timer();
|
setup_pit_timer();
|
||||||
|
|
||||||
irq0.mask = cpumask_of_cpu(0);
|
|
||||||
setup_irq(0, &irq0);
|
setup_irq(0, &irq0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -202,7 +202,6 @@ static struct irqaction vmi_clock_action = {
|
|||||||
.name = "vmi-timer",
|
.name = "vmi-timer",
|
||||||
.handler = vmi_timer_interrupt,
|
.handler = vmi_timer_interrupt,
|
||||||
.flags = IRQF_DISABLED | IRQF_NOBALANCING | IRQF_TIMER,
|
.flags = IRQF_DISABLED | IRQF_NOBALANCING | IRQF_TIMER,
|
||||||
.mask = CPU_MASK_ALL,
|
|
||||||
};
|
};
|
||||||
|
|
||||||
static void __devinit vmi_time_init_clockevent(void)
|
static void __devinit vmi_time_init_clockevent(void)
|
||||||
|
@ -119,7 +119,7 @@ static ssize_t print_cpus_map(char *buf, const struct cpumask *map)
|
|||||||
#define print_cpus_func(type) \
|
#define print_cpus_func(type) \
|
||||||
static ssize_t print_cpus_##type(struct sysdev_class *class, char *buf) \
|
static ssize_t print_cpus_##type(struct sysdev_class *class, char *buf) \
|
||||||
{ \
|
{ \
|
||||||
return print_cpus_map(buf, &cpu_##type##_map); \
|
return print_cpus_map(buf, cpu_##type##_mask); \
|
||||||
} \
|
} \
|
||||||
static struct sysdev_class_attribute attr_##type##_map = \
|
static struct sysdev_class_attribute attr_##type##_map = \
|
||||||
_SYSDEV_CLASS_ATTR(type, 0444, print_cpus_##type, NULL)
|
_SYSDEV_CLASS_ATTR(type, 0444, print_cpus_##type, NULL)
|
||||||
|
@ -574,7 +574,7 @@ int __init buffer_sync_init(void)
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
void __exit buffer_sync_cleanup(void)
|
void buffer_sync_cleanup(void)
|
||||||
{
|
{
|
||||||
free_cpumask_var(marked_cpus);
|
free_cpumask_var(marked_cpus);
|
||||||
}
|
}
|
||||||
|
@ -513,7 +513,7 @@ int seq_bitmap(struct seq_file *m, const unsigned long *bits,
|
|||||||
}
|
}
|
||||||
EXPORT_SYMBOL(seq_bitmap);
|
EXPORT_SYMBOL(seq_bitmap);
|
||||||
|
|
||||||
int seq_bitmap_list(struct seq_file *m, unsigned long *bits,
|
int seq_bitmap_list(struct seq_file *m, const unsigned long *bits,
|
||||||
unsigned int nr_bits)
|
unsigned int nr_bits)
|
||||||
{
|
{
|
||||||
if (m->count < m->size) {
|
if (m->count < m->size) {
|
||||||
|
@ -43,20 +43,10 @@
|
|||||||
#ifndef cpumask_of_node
|
#ifndef cpumask_of_node
|
||||||
#define cpumask_of_node(node) ((void)node, cpu_online_mask)
|
#define cpumask_of_node(node) ((void)node, cpu_online_mask)
|
||||||
#endif
|
#endif
|
||||||
#ifndef node_to_first_cpu
|
|
||||||
#define node_to_first_cpu(node) ((void)(node),0)
|
|
||||||
#endif
|
|
||||||
#ifndef pcibus_to_node
|
#ifndef pcibus_to_node
|
||||||
#define pcibus_to_node(bus) ((void)(bus), -1)
|
#define pcibus_to_node(bus) ((void)(bus), -1)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifndef pcibus_to_cpumask
|
|
||||||
#define pcibus_to_cpumask(bus) (pcibus_to_node(bus) == -1 ? \
|
|
||||||
CPU_MASK_ALL : \
|
|
||||||
node_to_cpumask(pcibus_to_node(bus)) \
|
|
||||||
)
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifndef cpumask_of_pcibus
|
#ifndef cpumask_of_pcibus
|
||||||
#define cpumask_of_pcibus(bus) (pcibus_to_node(bus) == -1 ? \
|
#define cpumask_of_pcibus(bus) (pcibus_to_node(bus) == -1 ? \
|
||||||
cpu_all_mask : \
|
cpu_all_mask : \
|
||||||
|
@ -90,12 +90,12 @@ static inline void cpuset_init_smp(void) {}
|
|||||||
static inline void cpuset_cpus_allowed(struct task_struct *p,
|
static inline void cpuset_cpus_allowed(struct task_struct *p,
|
||||||
struct cpumask *mask)
|
struct cpumask *mask)
|
||||||
{
|
{
|
||||||
*mask = cpu_possible_map;
|
cpumask_copy(mask, cpu_possible_mask);
|
||||||
}
|
}
|
||||||
static inline void cpuset_cpus_allowed_locked(struct task_struct *p,
|
static inline void cpuset_cpus_allowed_locked(struct task_struct *p,
|
||||||
struct cpumask *mask)
|
struct cpumask *mask)
|
||||||
{
|
{
|
||||||
*mask = cpu_possible_map;
|
cpumask_copy(mask, cpu_possible_mask);
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline nodemask_t cpuset_mems_allowed(struct task_struct *p)
|
static inline nodemask_t cpuset_mems_allowed(struct task_struct *p)
|
||||||
|
@ -55,7 +55,7 @@ int seq_bitmap(struct seq_file *m, const unsigned long *bits,
|
|||||||
unsigned int nr_bits);
|
unsigned int nr_bits);
|
||||||
static inline int seq_cpumask(struct seq_file *m, const struct cpumask *mask)
|
static inline int seq_cpumask(struct seq_file *m, const struct cpumask *mask)
|
||||||
{
|
{
|
||||||
return seq_bitmap(m, mask->bits, nr_cpu_ids);
|
return seq_bitmap(m, cpumask_bits(mask), nr_cpu_ids);
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline int seq_nodemask(struct seq_file *m, nodemask_t *mask)
|
static inline int seq_nodemask(struct seq_file *m, nodemask_t *mask)
|
||||||
@ -63,12 +63,13 @@ static inline int seq_nodemask(struct seq_file *m, nodemask_t *mask)
|
|||||||
return seq_bitmap(m, mask->bits, MAX_NUMNODES);
|
return seq_bitmap(m, mask->bits, MAX_NUMNODES);
|
||||||
}
|
}
|
||||||
|
|
||||||
int seq_bitmap_list(struct seq_file *m, unsigned long *bits,
|
int seq_bitmap_list(struct seq_file *m, const unsigned long *bits,
|
||||||
unsigned int nr_bits);
|
unsigned int nr_bits);
|
||||||
|
|
||||||
static inline int seq_cpumask_list(struct seq_file *m, cpumask_t *mask)
|
static inline int seq_cpumask_list(struct seq_file *m,
|
||||||
|
const struct cpumask *mask)
|
||||||
{
|
{
|
||||||
return seq_bitmap_list(m, mask->bits, NR_CPUS);
|
return seq_bitmap_list(m, cpumask_bits(mask), nr_cpu_ids);
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline int seq_nodemask_list(struct seq_file *m, nodemask_t *mask)
|
static inline int seq_nodemask_list(struct seq_file *m, nodemask_t *mask)
|
||||||
|
@ -407,8 +407,7 @@ static void __init smp_init(void)
|
|||||||
* Set up the current CPU as possible to migrate to.
|
* Set up the current CPU as possible to migrate to.
|
||||||
* The other ones will be done by cpu_up/cpu_down()
|
* The other ones will be done by cpu_up/cpu_down()
|
||||||
*/
|
*/
|
||||||
cpu = smp_processor_id();
|
set_cpu_active(smp_processor_id(), true);
|
||||||
cpu_set(cpu, cpu_active_map);
|
|
||||||
|
|
||||||
/* FIXME: This should be done in userspace --RR */
|
/* FIXME: This should be done in userspace --RR */
|
||||||
for_each_present_cpu(cpu) {
|
for_each_present_cpu(cpu) {
|
||||||
@ -842,7 +841,7 @@ static int __init kernel_init(void * unused)
|
|||||||
/*
|
/*
|
||||||
* init can run on any cpu.
|
* init can run on any cpu.
|
||||||
*/
|
*/
|
||||||
set_cpus_allowed_ptr(current, CPU_MASK_ALL_PTR);
|
set_cpus_allowed_ptr(current, cpu_all_mask);
|
||||||
/*
|
/*
|
||||||
* Tell the world that we're going to be the grim
|
* Tell the world that we're going to be the grim
|
||||||
* reaper of innocent orphaned children.
|
* reaper of innocent orphaned children.
|
||||||
|
@ -281,7 +281,7 @@ int __ref cpu_down(unsigned int cpu)
|
|||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
|
|
||||||
cpu_clear(cpu, cpu_active_map);
|
set_cpu_active(cpu, false);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Make sure the all cpus did the reschedule and are not
|
* Make sure the all cpus did the reschedule and are not
|
||||||
@ -296,7 +296,7 @@ int __ref cpu_down(unsigned int cpu)
|
|||||||
err = _cpu_down(cpu, 0);
|
err = _cpu_down(cpu, 0);
|
||||||
|
|
||||||
if (cpu_online(cpu))
|
if (cpu_online(cpu))
|
||||||
cpu_set(cpu, cpu_active_map);
|
set_cpu_active(cpu, true);
|
||||||
|
|
||||||
out:
|
out:
|
||||||
cpu_maps_update_done();
|
cpu_maps_update_done();
|
||||||
@ -333,7 +333,7 @@ static int __cpuinit _cpu_up(unsigned int cpu, int tasks_frozen)
|
|||||||
goto out_notify;
|
goto out_notify;
|
||||||
BUG_ON(!cpu_online(cpu));
|
BUG_ON(!cpu_online(cpu));
|
||||||
|
|
||||||
cpu_set(cpu, cpu_active_map);
|
set_cpu_active(cpu, true);
|
||||||
|
|
||||||
/* Now call notifier in preparation. */
|
/* Now call notifier in preparation. */
|
||||||
raw_notifier_call_chain(&cpu_chain, CPU_ONLINE | mod, hcpu);
|
raw_notifier_call_chain(&cpu_chain, CPU_ONLINE | mod, hcpu);
|
||||||
|
@ -284,7 +284,7 @@ static int dup_mmap(struct mm_struct *mm, struct mm_struct *oldmm)
|
|||||||
mm->free_area_cache = oldmm->mmap_base;
|
mm->free_area_cache = oldmm->mmap_base;
|
||||||
mm->cached_hole_size = ~0UL;
|
mm->cached_hole_size = ~0UL;
|
||||||
mm->map_count = 0;
|
mm->map_count = 0;
|
||||||
cpus_clear(mm->cpu_vm_mask);
|
cpumask_clear(mm_cpumask(mm));
|
||||||
mm->mm_rb = RB_ROOT;
|
mm->mm_rb = RB_ROOT;
|
||||||
rb_link = &mm->mm_rb.rb_node;
|
rb_link = &mm->mm_rb.rb_node;
|
||||||
rb_parent = NULL;
|
rb_parent = NULL;
|
||||||
|
@ -167,7 +167,7 @@ static int ____call_usermodehelper(void *data)
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* We can run anywhere, unlike our parent keventd(). */
|
/* We can run anywhere, unlike our parent keventd(). */
|
||||||
set_cpus_allowed_ptr(current, CPU_MASK_ALL_PTR);
|
set_cpus_allowed_ptr(current, cpu_all_mask);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Our parent is keventd, which runs with elevated scheduling priority.
|
* Our parent is keventd, which runs with elevated scheduling priority.
|
||||||
|
@ -110,7 +110,7 @@ static void create_kthread(struct kthread_create_info *create)
|
|||||||
*/
|
*/
|
||||||
sched_setscheduler(create->result, SCHED_NORMAL, ¶m);
|
sched_setscheduler(create->result, SCHED_NORMAL, ¶m);
|
||||||
set_user_nice(create->result, KTHREAD_NICE_LEVEL);
|
set_user_nice(create->result, KTHREAD_NICE_LEVEL);
|
||||||
set_cpus_allowed_ptr(create->result, CPU_MASK_ALL_PTR);
|
set_cpus_allowed_ptr(create->result, cpu_all_mask);
|
||||||
}
|
}
|
||||||
complete(&create->done);
|
complete(&create->done);
|
||||||
}
|
}
|
||||||
@ -240,7 +240,7 @@ int kthreadd(void *unused)
|
|||||||
set_task_comm(tsk, "kthreadd");
|
set_task_comm(tsk, "kthreadd");
|
||||||
ignore_signals(tsk);
|
ignore_signals(tsk);
|
||||||
set_user_nice(tsk, KTHREAD_NICE_LEVEL);
|
set_user_nice(tsk, KTHREAD_NICE_LEVEL);
|
||||||
set_cpus_allowed_ptr(tsk, CPU_MASK_ALL_PTR);
|
set_cpus_allowed_ptr(tsk, cpu_all_mask);
|
||||||
|
|
||||||
current->flags |= PF_NOFREEZE | PF_FREEZER_NOSIG;
|
current->flags |= PF_NOFREEZE | PF_FREEZER_NOSIG;
|
||||||
|
|
||||||
|
@ -126,6 +126,7 @@ static atomic_t n_rcu_torture_mberror;
|
|||||||
static atomic_t n_rcu_torture_error;
|
static atomic_t n_rcu_torture_error;
|
||||||
static long n_rcu_torture_timers = 0;
|
static long n_rcu_torture_timers = 0;
|
||||||
static struct list_head rcu_torture_removed;
|
static struct list_head rcu_torture_removed;
|
||||||
|
static cpumask_var_t shuffle_tmp_mask;
|
||||||
|
|
||||||
static int stutter_pause_test = 0;
|
static int stutter_pause_test = 0;
|
||||||
|
|
||||||
@ -889,10 +890,9 @@ static int rcu_idle_cpu; /* Force all torture tasks off this CPU */
|
|||||||
*/
|
*/
|
||||||
static void rcu_torture_shuffle_tasks(void)
|
static void rcu_torture_shuffle_tasks(void)
|
||||||
{
|
{
|
||||||
cpumask_t tmp_mask;
|
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
cpus_setall(tmp_mask);
|
cpumask_setall(shuffle_tmp_mask);
|
||||||
get_online_cpus();
|
get_online_cpus();
|
||||||
|
|
||||||
/* No point in shuffling if there is only one online CPU (ex: UP) */
|
/* No point in shuffling if there is only one online CPU (ex: UP) */
|
||||||
@ -902,29 +902,29 @@ static void rcu_torture_shuffle_tasks(void)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (rcu_idle_cpu != -1)
|
if (rcu_idle_cpu != -1)
|
||||||
cpu_clear(rcu_idle_cpu, tmp_mask);
|
cpumask_clear_cpu(rcu_idle_cpu, shuffle_tmp_mask);
|
||||||
|
|
||||||
set_cpus_allowed_ptr(current, &tmp_mask);
|
set_cpus_allowed_ptr(current, shuffle_tmp_mask);
|
||||||
|
|
||||||
if (reader_tasks) {
|
if (reader_tasks) {
|
||||||
for (i = 0; i < nrealreaders; i++)
|
for (i = 0; i < nrealreaders; i++)
|
||||||
if (reader_tasks[i])
|
if (reader_tasks[i])
|
||||||
set_cpus_allowed_ptr(reader_tasks[i],
|
set_cpus_allowed_ptr(reader_tasks[i],
|
||||||
&tmp_mask);
|
shuffle_tmp_mask);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (fakewriter_tasks) {
|
if (fakewriter_tasks) {
|
||||||
for (i = 0; i < nfakewriters; i++)
|
for (i = 0; i < nfakewriters; i++)
|
||||||
if (fakewriter_tasks[i])
|
if (fakewriter_tasks[i])
|
||||||
set_cpus_allowed_ptr(fakewriter_tasks[i],
|
set_cpus_allowed_ptr(fakewriter_tasks[i],
|
||||||
&tmp_mask);
|
shuffle_tmp_mask);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (writer_task)
|
if (writer_task)
|
||||||
set_cpus_allowed_ptr(writer_task, &tmp_mask);
|
set_cpus_allowed_ptr(writer_task, shuffle_tmp_mask);
|
||||||
|
|
||||||
if (stats_task)
|
if (stats_task)
|
||||||
set_cpus_allowed_ptr(stats_task, &tmp_mask);
|
set_cpus_allowed_ptr(stats_task, shuffle_tmp_mask);
|
||||||
|
|
||||||
if (rcu_idle_cpu == -1)
|
if (rcu_idle_cpu == -1)
|
||||||
rcu_idle_cpu = num_online_cpus() - 1;
|
rcu_idle_cpu = num_online_cpus() - 1;
|
||||||
@ -1012,6 +1012,7 @@ rcu_torture_cleanup(void)
|
|||||||
if (shuffler_task) {
|
if (shuffler_task) {
|
||||||
VERBOSE_PRINTK_STRING("Stopping rcu_torture_shuffle task");
|
VERBOSE_PRINTK_STRING("Stopping rcu_torture_shuffle task");
|
||||||
kthread_stop(shuffler_task);
|
kthread_stop(shuffler_task);
|
||||||
|
free_cpumask_var(shuffle_tmp_mask);
|
||||||
}
|
}
|
||||||
shuffler_task = NULL;
|
shuffler_task = NULL;
|
||||||
|
|
||||||
@ -1190,10 +1191,18 @@ rcu_torture_init(void)
|
|||||||
}
|
}
|
||||||
if (test_no_idle_hz) {
|
if (test_no_idle_hz) {
|
||||||
rcu_idle_cpu = num_online_cpus() - 1;
|
rcu_idle_cpu = num_online_cpus() - 1;
|
||||||
|
|
||||||
|
if (!alloc_cpumask_var(&shuffle_tmp_mask, GFP_KERNEL)) {
|
||||||
|
firsterr = -ENOMEM;
|
||||||
|
VERBOSE_PRINTK_ERRSTRING("Failed to alloc mask");
|
||||||
|
goto unwind;
|
||||||
|
}
|
||||||
|
|
||||||
/* Create the shuffler thread */
|
/* Create the shuffler thread */
|
||||||
shuffler_task = kthread_run(rcu_torture_shuffle, NULL,
|
shuffler_task = kthread_run(rcu_torture_shuffle, NULL,
|
||||||
"rcu_torture_shuffle");
|
"rcu_torture_shuffle");
|
||||||
if (IS_ERR(shuffler_task)) {
|
if (IS_ERR(shuffler_task)) {
|
||||||
|
free_cpumask_var(shuffle_tmp_mask);
|
||||||
firsterr = PTR_ERR(shuffler_task);
|
firsterr = PTR_ERR(shuffler_task);
|
||||||
VERBOSE_PRINTK_ERRSTRING("Failed to create shuffler");
|
VERBOSE_PRINTK_ERRSTRING("Failed to create shuffler");
|
||||||
shuffler_task = NULL;
|
shuffler_task = NULL;
|
||||||
|
@ -25,7 +25,7 @@ struct cpupri {
|
|||||||
|
|
||||||
#ifdef CONFIG_SMP
|
#ifdef CONFIG_SMP
|
||||||
int cpupri_find(struct cpupri *cp,
|
int cpupri_find(struct cpupri *cp,
|
||||||
struct task_struct *p, cpumask_t *lowest_mask);
|
struct task_struct *p, struct cpumask *lowest_mask);
|
||||||
void cpupri_set(struct cpupri *cp, int cpu, int pri);
|
void cpupri_set(struct cpupri *cp, int cpu, int pri);
|
||||||
int cpupri_init(struct cpupri *cp, bool bootmem);
|
int cpupri_init(struct cpupri *cp, bool bootmem);
|
||||||
void cpupri_cleanup(struct cpupri *cp);
|
void cpupri_cleanup(struct cpupri *cp);
|
||||||
|
@ -44,7 +44,7 @@ static DEFINE_MUTEX(setup_lock);
|
|||||||
static int refcount;
|
static int refcount;
|
||||||
static struct workqueue_struct *stop_machine_wq;
|
static struct workqueue_struct *stop_machine_wq;
|
||||||
static struct stop_machine_data active, idle;
|
static struct stop_machine_data active, idle;
|
||||||
static const cpumask_t *active_cpus;
|
static const struct cpumask *active_cpus;
|
||||||
static void *stop_machine_work;
|
static void *stop_machine_work;
|
||||||
|
|
||||||
static void set_state(enum stopmachine_state newstate)
|
static void set_state(enum stopmachine_state newstate)
|
||||||
|
@ -416,7 +416,7 @@ void flush_workqueue(struct workqueue_struct *wq)
|
|||||||
might_sleep();
|
might_sleep();
|
||||||
lock_map_acquire(&wq->lockdep_map);
|
lock_map_acquire(&wq->lockdep_map);
|
||||||
lock_map_release(&wq->lockdep_map);
|
lock_map_release(&wq->lockdep_map);
|
||||||
for_each_cpu_mask_nr(cpu, *cpu_map)
|
for_each_cpu(cpu, cpu_map)
|
||||||
flush_cpu_workqueue(per_cpu_ptr(wq->cpu_wq, cpu));
|
flush_cpu_workqueue(per_cpu_ptr(wq->cpu_wq, cpu));
|
||||||
}
|
}
|
||||||
EXPORT_SYMBOL_GPL(flush_workqueue);
|
EXPORT_SYMBOL_GPL(flush_workqueue);
|
||||||
@ -547,7 +547,7 @@ static void wait_on_work(struct work_struct *work)
|
|||||||
wq = cwq->wq;
|
wq = cwq->wq;
|
||||||
cpu_map = wq_cpu_map(wq);
|
cpu_map = wq_cpu_map(wq);
|
||||||
|
|
||||||
for_each_cpu_mask_nr(cpu, *cpu_map)
|
for_each_cpu(cpu, cpu_map)
|
||||||
wait_on_cpu_work(per_cpu_ptr(wq->cpu_wq, cpu), work);
|
wait_on_cpu_work(per_cpu_ptr(wq->cpu_wq, cpu), work);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -911,7 +911,7 @@ void destroy_workqueue(struct workqueue_struct *wq)
|
|||||||
list_del(&wq->list);
|
list_del(&wq->list);
|
||||||
spin_unlock(&workqueue_lock);
|
spin_unlock(&workqueue_lock);
|
||||||
|
|
||||||
for_each_cpu_mask_nr(cpu, *cpu_map)
|
for_each_cpu(cpu, cpu_map)
|
||||||
cleanup_workqueue_thread(per_cpu_ptr(wq->cpu_wq, cpu));
|
cleanup_workqueue_thread(per_cpu_ptr(wq->cpu_wq, cpu));
|
||||||
cpu_maps_update_done();
|
cpu_maps_update_done();
|
||||||
|
|
||||||
|
@ -143,7 +143,7 @@ void free_percpu(void *__pdata)
|
|||||||
{
|
{
|
||||||
if (unlikely(!__pdata))
|
if (unlikely(!__pdata))
|
||||||
return;
|
return;
|
||||||
__percpu_depopulate_mask(__pdata, &cpu_possible_map);
|
__percpu_depopulate_mask(__pdata, cpu_possible_mask);
|
||||||
kfree(__percpu_disguise(__pdata));
|
kfree(__percpu_disguise(__pdata));
|
||||||
}
|
}
|
||||||
EXPORT_SYMBOL_GPL(free_percpu);
|
EXPORT_SYMBOL_GPL(free_percpu);
|
||||||
|
@ -191,7 +191,7 @@ static int pdflush(void *dummy)
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
* Some configs put our parent kthread in a limited cpuset,
|
* Some configs put our parent kthread in a limited cpuset,
|
||||||
* which kthread() overrides, forcing cpus_allowed == CPU_MASK_ALL.
|
* which kthread() overrides, forcing cpus_allowed == cpu_all_mask.
|
||||||
* Our needs are more modest - cut back to our cpusets cpus_allowed.
|
* Our needs are more modest - cut back to our cpusets cpus_allowed.
|
||||||
* This is needed as pdflush's are dynamically created and destroyed.
|
* This is needed as pdflush's are dynamically created and destroyed.
|
||||||
* The boottime pdflush's are easily placed w/o these 2 lines.
|
* The boottime pdflush's are easily placed w/o these 2 lines.
|
||||||
|
@ -27,7 +27,7 @@ static void sum_vm_events(unsigned long *ret, const struct cpumask *cpumask)
|
|||||||
|
|
||||||
memset(ret, 0, NR_VM_EVENT_ITEMS * sizeof(unsigned long));
|
memset(ret, 0, NR_VM_EVENT_ITEMS * sizeof(unsigned long));
|
||||||
|
|
||||||
for_each_cpu_mask_nr(cpu, *cpumask) {
|
for_each_cpu(cpu, cpumask) {
|
||||||
struct vm_event_state *this = &per_cpu(vm_event_states, cpu);
|
struct vm_event_state *this = &per_cpu(vm_event_states, cpu);
|
||||||
|
|
||||||
for (i = 0; i < NR_VM_EVENT_ITEMS; i++)
|
for (i = 0; i < NR_VM_EVENT_ITEMS; i++)
|
||||||
|
@ -312,7 +312,7 @@ svc_pool_map_set_cpumask(struct task_struct *task, unsigned int pidx)
|
|||||||
switch (m->mode) {
|
switch (m->mode) {
|
||||||
case SVC_POOL_PERCPU:
|
case SVC_POOL_PERCPU:
|
||||||
{
|
{
|
||||||
set_cpus_allowed_ptr(task, &cpumask_of_cpu(node));
|
set_cpus_allowed_ptr(task, cpumask_of(node));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case SVC_POOL_PERNODE:
|
case SVC_POOL_PERNODE:
|
||||||
|
Loading…
Reference in New Issue
Block a user