mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-11-20 00:26:39 +08:00
cpumask: remove node_to_first_cpu
Everyone defines it, and only one person uses it (arch/mips/sgi-ip27/ip27-nmi.c). So just open code it there. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Cc: linux-mips@linux-mips.org
This commit is contained in:
parent
af76aba00f
commit
0451fb2ebc
@ -43,11 +43,6 @@
|
||||
*/
|
||||
#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
|
||||
*/
|
||||
|
@ -26,7 +26,6 @@ extern struct cpuinfo_ip27 sn_cpu_info[NR_CPUS];
|
||||
#define parent_node(node) (node)
|
||||
#define node_to_cpumask(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;
|
||||
extern int pcibus_to_node(struct pci_bus *);
|
||||
|
||||
|
@ -219,7 +219,7 @@ cont_nmi_dump(void)
|
||||
if (i == 1000) {
|
||||
for_each_online_node(node)
|
||||
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++) {
|
||||
CPUMASK_SETB(nmied_cpus, cpu);
|
||||
/*
|
||||
|
@ -24,11 +24,6 @@ static inline cpumask_t node_to_cpumask(int 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);
|
||||
|
||||
struct pci_bus;
|
||||
|
@ -33,7 +33,6 @@
|
||||
|
||||
#define node_to_cpumask(node) ((void)node, cpu_online_map)
|
||||
#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_cpumask(bus) (pcibus_to_node(bus) == -1 ? \
|
||||
|
@ -28,11 +28,6 @@ static inline cpumask_t node_to_cpumask(int node)
|
||||
#define node_to_cpumask_ptr_next(v, 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;
|
||||
#ifdef CONFIG_PCI
|
||||
extern int pcibus_to_node(struct pci_bus *pbus);
|
||||
|
@ -217,10 +217,6 @@ static inline cpumask_t node_to_cpumask(int node)
|
||||
{
|
||||
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) { }
|
||||
|
||||
@ -237,14 +233,6 @@ static inline void setup_node_to_cpumask_map(void) { }
|
||||
|
||||
#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 const struct cpumask *cpu_coregroup_mask(int cpu);
|
||||
|
||||
|
@ -43,9 +43,6 @@
|
||||
#ifndef cpumask_of_node
|
||||
#define cpumask_of_node(node) ((void)node, cpu_online_mask)
|
||||
#endif
|
||||
#ifndef node_to_first_cpu
|
||||
#define node_to_first_cpu(node) ((void)(node),0)
|
||||
#endif
|
||||
#ifndef pcibus_to_node
|
||||
#define pcibus_to_node(bus) ((void)(bus), -1)
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user