{
}
-static inline void enable_apic_mode(void)
+static inline int bigsmp_check_phys_apicid_present(int boot_cpu_physical_apicid)
{
+ return 1;
}
-static inline int check_phys_apicid_present(int boot_cpu_physical_apicid)
+static inline void enable_apic_mode(void)
{
- return (1);
}
/* As we are using single CPU as destination, pick only one CPU here */
return physids_promote(0xff);
}
-
extern unsigned int boot_cpu_physical_apicid;
-static inline int check_phys_apicid_present(int cpu_physical_apicid)
+
+static inline int es7000_check_phys_apicid_present(int cpu_physical_apicid)
{
boot_cpu_physical_apicid = read_apic_id();
return (1);
extern void default_setup_apic_routing(void);
extern int default_cpu_present_to_apicid(int mps_cpu);
+extern int default_check_phys_apicid_present(int boot_cpu_physical_apicid);
#endif
#endif /* _ASM_X86_GENAPIC_64_H */
return BAD_APICID;
}
+static inline int
+__default_check_phys_apicid_present(int boot_cpu_physical_apicid)
+{
+ return physid_isset(boot_cpu_physical_apicid, phys_cpu_present_map);
+}
+
#ifdef CONFIG_X86_32
static inline int default_cpu_present_to_apicid(int mps_cpu)
{
return __default_cpu_present_to_apicid(mps_cpu);
}
+
+static inline int
+default_check_phys_apicid_present(int boot_cpu_physical_apicid)
+{
+ return __default_check_phys_apicid_present(boot_cpu_physical_apicid);
+}
#else
extern int default_cpu_present_to_apicid(int mps_cpu);
+extern int default_check_phys_apicid_present(int boot_cpu_physical_apicid);
#endif
static inline physid_mask_t default_apicid_to_cpu_present(int phys_apicid)
return physid_mask_of_physid(phys_apicid);
}
-static inline int check_phys_apicid_present(int boot_cpu_physical_apicid)
-{
- return physid_isset(boot_cpu_physical_apicid, phys_cpu_present_map);
-}
-
static inline void enable_apic_mode(void)
{
}
#include <asm/genapic.h>
-#define check_phys_apicid_present (apic->check_phys_apicid_present)
#define cpu_mask_to_apicid (apic->cpu_mask_to_apicid)
#define cpu_mask_to_apicid_and (apic->cpu_mask_to_apicid_and)
#define enable_apic_mode (apic->enable_apic_mode)
extern void *xquad_portio;
-static inline int check_phys_apicid_present(int boot_cpu_physical_apicid)
+static inline int numaq_check_phys_apicid_present(int boot_cpu_physical_apicid)
{
- return (1);
+ return 1;
}
static inline void enable_apic_mode(void)
{
}
-static inline int check_phys_apicid_present(int boot_cpu_physical_apicid)
+static inline int summit_check_phys_apicid_present(int boot_cpu_physical_apicid)
{
return 1;
}
.cpu_present_to_apicid = default_cpu_present_to_apicid,
.apicid_to_cpu_present = NULL,
.setup_portio_remap = NULL,
- .check_phys_apicid_present = NULL,
+ .check_phys_apicid_present = default_check_phys_apicid_present,
.enable_apic_mode = NULL,
.phys_pkg_id = phys_pkg_id,
.mps_oem_check = NULL,
.cpu_present_to_apicid = default_cpu_present_to_apicid,
.apicid_to_cpu_present = NULL,
.setup_portio_remap = NULL,
- .check_phys_apicid_present = NULL,
+ .check_phys_apicid_present = default_check_phys_apicid_present,
.enable_apic_mode = NULL,
.phys_pkg_id = phys_pkg_id,
.mps_oem_check = NULL,
.cpu_present_to_apicid = default_cpu_present_to_apicid,
.apicid_to_cpu_present = NULL,
.setup_portio_remap = NULL,
- .check_phys_apicid_present = NULL,
+ .check_phys_apicid_present = default_check_phys_apicid_present,
.enable_apic_mode = NULL,
.phys_pkg_id = phys_pkg_id,
.mps_oem_check = NULL,
.cpu_present_to_apicid = default_cpu_present_to_apicid,
.apicid_to_cpu_present = NULL,
.setup_portio_remap = NULL,
- .check_phys_apicid_present = NULL,
+ .check_phys_apicid_present = default_check_phys_apicid_present,
.enable_apic_mode = NULL,
.phys_pkg_id = phys_pkg_id,
.mps_oem_check = NULL,
.cpu_present_to_apicid = default_cpu_present_to_apicid,
.apicid_to_cpu_present = NULL,
.setup_portio_remap = NULL,
- .check_phys_apicid_present = NULL,
+ .check_phys_apicid_present = default_check_phys_apicid_present,
.enable_apic_mode = NULL,
.phys_pkg_id = phys_pkg_id,
.mps_oem_check = NULL,
{
return __default_cpu_present_to_apicid(mps_cpu);
}
+
+int default_check_phys_apicid_present(int boot_cpu_physical_apicid)
+{
+ return __default_check_phys_apicid_present(boot_cpu_physical_apicid);
+}
#endif
int __cpuinit native_cpu_up(unsigned int cpu)
* Should not be necessary because the MP table should list the boot
* CPU too, but we do it for the sake of robustness anyway.
*/
- if (!check_phys_apicid_present(boot_cpu_physical_apicid)) {
+ if (!apic->check_phys_apicid_present(boot_cpu_physical_apicid)) {
printk(KERN_NOTICE
"weird, boot CPU (#%d) not listed by the BIOS.\n",
boot_cpu_physical_apicid);
.cpu_present_to_apicid = bigsmp_cpu_present_to_apicid,
.apicid_to_cpu_present = bigsmp_apicid_to_cpu_present,
.setup_portio_remap = NULL,
- .check_phys_apicid_present = check_phys_apicid_present,
+ .check_phys_apicid_present = bigsmp_check_phys_apicid_present,
.enable_apic_mode = enable_apic_mode,
.phys_pkg_id = phys_pkg_id,
.mps_oem_check = mps_oem_check,
.cpu_present_to_apicid = default_cpu_present_to_apicid,
.apicid_to_cpu_present = default_apicid_to_cpu_present,
.setup_portio_remap = NULL,
- .check_phys_apicid_present = check_phys_apicid_present,
+ .check_phys_apicid_present = default_check_phys_apicid_present,
.enable_apic_mode = enable_apic_mode,
.phys_pkg_id = phys_pkg_id,
.mps_oem_check = mps_oem_check,
.cpu_present_to_apicid = es7000_cpu_present_to_apicid,
.apicid_to_cpu_present = es7000_apicid_to_cpu_present,
.setup_portio_remap = NULL,
- .check_phys_apicid_present = check_phys_apicid_present,
+ .check_phys_apicid_present = es7000_check_phys_apicid_present,
.enable_apic_mode = enable_apic_mode,
.phys_pkg_id = phys_pkg_id,
.mps_oem_check = mps_oem_check,
.cpu_present_to_apicid = numaq_cpu_present_to_apicid,
.apicid_to_cpu_present = numaq_apicid_to_cpu_present,
.setup_portio_remap = numaq_setup_portio_remap,
- .check_phys_apicid_present = check_phys_apicid_present,
+ .check_phys_apicid_present = numaq_check_phys_apicid_present,
.enable_apic_mode = enable_apic_mode,
.phys_pkg_id = phys_pkg_id,
.mps_oem_check = mps_oem_check,
.cpu_present_to_apicid = summit_cpu_present_to_apicid,
.apicid_to_cpu_present = summit_apicid_to_cpu_present,
.setup_portio_remap = NULL,
- .check_phys_apicid_present = check_phys_apicid_present,
+ .check_phys_apicid_present = summit_check_phys_apicid_present,
.enable_apic_mode = enable_apic_mode,
.phys_pkg_id = phys_pkg_id,
.mps_oem_check = mps_oem_check,