"Physflat", nr_ioapics);
}
-static inline int apicid_to_node(int logical_apicid)
+static inline int bigsmp_apicid_to_node(int logical_apicid)
{
return apicid_2_node[hard_smp_processor_id()];
}
nr_ioapics, cpus_addr(*es7000_target_cpus())[0]);
}
-static inline int apicid_to_node(int logical_apicid)
+static inline int es7000_apicid_to_node(int logical_apicid)
{
return 0;
}
#endif
}
-static inline int apicid_to_node(int logical_apicid)
+static inline int default_apicid_to_node(int logical_apicid)
{
#ifdef CONFIG_SMP
return apicid_2_node[hard_smp_processor_id()];
#include <asm/genapic.h>
-#define apicid_to_node (apic->apicid_to_node)
#define cpu_to_logical_apicid (apic->cpu_to_logical_apicid)
#define cpu_present_to_apicid (apic->cpu_present_to_apicid)
#define apicid_to_cpu_present (apic->apicid_to_cpu_present)
return BAD_APICID;
}
-static inline int apicid_to_node(int logical_apicid)
+static inline int numaq_apicid_to_node(int logical_apicid)
{
return logical_apicid >> 4;
}
static inline physid_mask_t apicid_to_cpu_present(int logical_apicid)
{
- int node = apicid_to_node(logical_apicid);
+ int node = numaq_apicid_to_node(logical_apicid);
int cpu = __ffs(logical_apicid & 0xf);
return physid_mask_of_physid(cpu + 4*node);
nr_ioapics);
}
-static inline int apicid_to_node(int logical_apicid)
+static inline int summit_apicid_to_node(int logical_apicid)
{
#ifdef CONFIG_SMP
return apicid_2_node[hard_smp_processor_id()];
{
int cpu = smp_processor_id();
int apicid = logical_smp_processor_id();
- int node = apicid_to_node(apicid);
+ int node = apic->apicid_to_node(apicid);
if (!node_online(node))
node = first_online_node;
.ioapic_phys_id_map = bigsmp_ioapic_phys_id_map,
.setup_apic_routing = bigsmp_setup_apic_routing,
.multi_timer_check = NULL,
- .apicid_to_node = apicid_to_node,
+ .apicid_to_node = bigsmp_apicid_to_node,
.cpu_to_logical_apicid = cpu_to_logical_apicid,
.cpu_present_to_apicid = cpu_present_to_apicid,
.apicid_to_cpu_present = apicid_to_cpu_present,
.ioapic_phys_id_map = default_ioapic_phys_id_map,
.setup_apic_routing = default_setup_apic_routing,
.multi_timer_check = NULL,
- .apicid_to_node = apicid_to_node,
+ .apicid_to_node = default_apicid_to_node,
.cpu_to_logical_apicid = cpu_to_logical_apicid,
.cpu_present_to_apicid = cpu_present_to_apicid,
.apicid_to_cpu_present = apicid_to_cpu_present,
.ioapic_phys_id_map = es7000_ioapic_phys_id_map,
.setup_apic_routing = es7000_setup_apic_routing,
.multi_timer_check = NULL,
- .apicid_to_node = apicid_to_node,
+ .apicid_to_node = es7000_apicid_to_node,
.cpu_to_logical_apicid = cpu_to_logical_apicid,
.cpu_present_to_apicid = cpu_present_to_apicid,
.apicid_to_cpu_present = apicid_to_cpu_present,
.ioapic_phys_id_map = numaq_ioapic_phys_id_map,
.setup_apic_routing = numaq_setup_apic_routing,
.multi_timer_check = numaq_multi_timer_check,
- .apicid_to_node = apicid_to_node,
+ .apicid_to_node = numaq_apicid_to_node,
.cpu_to_logical_apicid = cpu_to_logical_apicid,
.cpu_present_to_apicid = cpu_present_to_apicid,
.apicid_to_cpu_present = apicid_to_cpu_present,
.ioapic_phys_id_map = summit_ioapic_phys_id_map,
.setup_apic_routing = summit_setup_apic_routing,
.multi_timer_check = NULL,
- .apicid_to_node = apicid_to_node,
+ .apicid_to_node = summit_apicid_to_node,
.cpu_to_logical_apicid = cpu_to_logical_apicid,
.cpu_present_to_apicid = cpu_present_to_apicid,
.apicid_to_cpu_present = apicid_to_cpu_present,