]> pilppa.org Git - linux-2.6-omap-h63xx.git/blob - arch/x86/mach-generic/summit.c
x86: clean up esr_disable() methods
[linux-2.6-omap-h63xx.git] / arch / x86 / mach-generic / summit.c
1 /*
2  * APIC driver for the IBM "Summit" chipset.
3  */
4 #define APIC_DEFINITION 1
5 #include <linux/threads.h>
6 #include <linux/cpumask.h>
7 #include <asm/mpspec.h>
8 #include <asm/genapic.h>
9 #include <asm/fixmap.h>
10 #include <asm/apicdef.h>
11 #include <linux/kernel.h>
12 #include <linux/string.h>
13 #include <linux/init.h>
14 #include <asm/summit/apicdef.h>
15 #include <linux/smp.h>
16 #include <asm/summit/apic.h>
17 #include <asm/summit/ipi.h>
18 #include <asm/summit/mpparse.h>
19 #include <asm/mach-default/mach_wakecpu.h>
20
21 static int probe_summit(void)
22 {
23         /* probed later in mptable/ACPI hooks */
24         return 0;
25 }
26
27 static void vector_allocation_domain(int cpu, cpumask_t *retmask)
28 {
29         /* Careful. Some cpus do not strictly honor the set of cpus
30          * specified in the interrupt destination when using lowest
31          * priority interrupt delivery mode.
32          *
33          * In particular there was a hyperthreading cpu observed to
34          * deliver interrupts to the wrong hyperthread when only one
35          * hyperthread was specified in the interrupt desitination.
36          */
37         *retmask = (cpumask_t){ { [0] = APIC_ALL_CPUS, } };
38 }
39
40 struct genapic apic_summit = {
41
42         .name                           = "summit",
43         .probe                          = probe_summit,
44         .acpi_madt_oem_check            = summit_acpi_madt_oem_check,
45         .apic_id_registered             = summit_apic_id_registered,
46
47         .irq_delivery_mode              = dest_LowestPrio,
48         /* logical delivery broadcast to all CPUs: */
49         .irq_dest_mode                  = 1,
50
51         .target_cpus                    = summit_target_cpus,
52         .ESR_DISABLE                    = 1,
53         .apic_destination_logical       = APIC_DEST_LOGICAL,
54         .check_apicid_used              = check_apicid_used,
55         .check_apicid_present           = check_apicid_present,
56
57         .no_balance_irq                 = NO_BALANCE_IRQ,
58         .no_ioapic_check                = 0,
59
60         .vector_allocation_domain       = vector_allocation_domain,
61         .init_apic_ldr                  = init_apic_ldr,
62
63         .ioapic_phys_id_map             = ioapic_phys_id_map,
64         .setup_apic_routing             = setup_apic_routing,
65         .multi_timer_check              = multi_timer_check,
66         .apicid_to_node                 = apicid_to_node,
67         .cpu_to_logical_apicid          = cpu_to_logical_apicid,
68         .cpu_present_to_apicid          = cpu_present_to_apicid,
69         .apicid_to_cpu_present          = apicid_to_cpu_present,
70         .setup_portio_remap             = setup_portio_remap,
71         .check_phys_apicid_present      = check_phys_apicid_present,
72         .enable_apic_mode               = enable_apic_mode,
73         .phys_pkg_id                    = phys_pkg_id,
74         .mps_oem_check                  = mps_oem_check,
75
76         .get_apic_id                    = get_apic_id,
77         .set_apic_id                    = NULL,
78         .apic_id_mask                   = APIC_ID_MASK,
79
80         .cpu_mask_to_apicid             = cpu_mask_to_apicid,
81         .cpu_mask_to_apicid_and         = cpu_mask_to_apicid_and,
82
83         .send_IPI_mask                  = send_IPI_mask,
84         .send_IPI_mask_allbutself       = NULL,
85         .send_IPI_allbutself            = send_IPI_allbutself,
86         .send_IPI_all                   = send_IPI_all,
87         .send_IPI_self                  = NULL,
88
89         .wakeup_cpu                     = NULL,
90         .trampoline_phys_low            = TRAMPOLINE_PHYS_LOW,
91         .trampoline_phys_high           = TRAMPOLINE_PHYS_HIGH,
92         .wait_for_init_deassert         = wait_for_init_deassert,
93         .smp_callin_clear_local_apic    = smp_callin_clear_local_apic,
94         .store_NMI_vector               = store_NMI_vector,
95         .restore_NMI_vector             = restore_NMI_vector,
96         .inquire_remote_apic            = inquire_remote_apic,
97 };