diff options
Diffstat (limited to 'arch/x86/include')
34 files changed, 2028 insertions, 1155 deletions
diff --git a/arch/x86/include/asm/acpi.h b/arch/x86/include/asm/acpi.h index 0c44630d1789..b31bf97775fc 100644 --- a/arch/x86/include/asm/acpi.h +++ b/arch/x86/include/asm/acpi.h | |||
@@ -49,10 +49,6 @@ | |||
49 | 49 | ||
50 | /* Asm macros */ | 50 | /* Asm macros */ |
51 | 51 | ||
52 | #define ACPI_ASM_MACROS | ||
53 | #define BREAKPOINT3 | ||
54 | #define ACPI_DISABLE_IRQS() local_irq_disable() | ||
55 | #define ACPI_ENABLE_IRQS() local_irq_enable() | ||
56 | #define ACPI_FLUSH_CPU_CACHE() wbinvd() | 52 | #define ACPI_FLUSH_CPU_CACHE() wbinvd() |
57 | 53 | ||
58 | int __acpi_acquire_global_lock(unsigned int *lock); | 54 | int __acpi_acquire_global_lock(unsigned int *lock); |
diff --git a/arch/x86/include/asm/amd_nb.h b/arch/x86/include/asm/amd_nb.h index b3341e9cd8fd..a54ee1d054d9 100644 --- a/arch/x86/include/asm/amd_nb.h +++ b/arch/x86/include/asm/amd_nb.h | |||
@@ -81,6 +81,23 @@ static inline struct amd_northbridge *node_to_amd_nb(int node) | |||
81 | return (node < amd_northbridges.num) ? &amd_northbridges.nb[node] : NULL; | 81 | return (node < amd_northbridges.num) ? &amd_northbridges.nb[node] : NULL; |
82 | } | 82 | } |
83 | 83 | ||
84 | static inline u16 amd_get_node_id(struct pci_dev *pdev) | ||
85 | { | ||
86 | struct pci_dev *misc; | ||
87 | int i; | ||
88 | |||
89 | for (i = 0; i != amd_nb_num(); i++) { | ||
90 | misc = node_to_amd_nb(i)->misc; | ||
91 | |||
92 | if (pci_domain_nr(misc->bus) == pci_domain_nr(pdev->bus) && | ||
93 | PCI_SLOT(misc->devfn) == PCI_SLOT(pdev->devfn)) | ||
94 | return i; | ||
95 | } | ||
96 | |||
97 | WARN(1, "Unable to find AMD Northbridge id for %s\n", pci_name(pdev)); | ||
98 | return 0; | ||
99 | } | ||
100 | |||
84 | #else | 101 | #else |
85 | 102 | ||
86 | #define amd_nb_num(x) 0 | 103 | #define amd_nb_num(x) 0 |
diff --git a/arch/x86/include/asm/bootparam_utils.h b/arch/x86/include/asm/bootparam_utils.h new file mode 100644 index 000000000000..5b5e9cb774b5 --- /dev/null +++ b/arch/x86/include/asm/bootparam_utils.h | |||
@@ -0,0 +1,38 @@ | |||
1 | #ifndef _ASM_X86_BOOTPARAM_UTILS_H | ||
2 | #define _ASM_X86_BOOTPARAM_UTILS_H | ||
3 | |||
4 | #include <asm/bootparam.h> | ||
5 | |||
6 | /* | ||
7 | * This file is included from multiple environments. Do not | ||
8 | * add completing #includes to make it standalone. | ||
9 | */ | ||
10 | |||
11 | /* | ||
12 | * Deal with bootloaders which fail to initialize unknown fields in | ||
13 | * boot_params to zero. The list fields in this list are taken from | ||
14 | * analysis of kexec-tools; if other broken bootloaders initialize a | ||
15 | * different set of fields we will need to figure out how to disambiguate. | ||
16 | * | ||
17 | */ | ||
18 | static void sanitize_boot_params(struct boot_params *boot_params) | ||
19 | { | ||
20 | if (boot_params->sentinel) { | ||
21 | /*fields in boot_params are not valid, clear them */ | ||
22 | memset(&boot_params->olpc_ofw_header, 0, | ||
23 | (char *)&boot_params->alt_mem_k - | ||
24 | (char *)&boot_params->olpc_ofw_header); | ||
25 | memset(&boot_params->kbd_status, 0, | ||
26 | (char *)&boot_params->hdr - | ||
27 | (char *)&boot_params->kbd_status); | ||
28 | memset(&boot_params->_pad7[0], 0, | ||
29 | (char *)&boot_params->edd_mbr_sig_buffer[0] - | ||
30 | (char *)&boot_params->_pad7[0]); | ||
31 | memset(&boot_params->_pad8[0], 0, | ||
32 | (char *)&boot_params->eddbuf[0] - | ||
33 | (char *)&boot_params->_pad8[0]); | ||
34 | memset(&boot_params->_pad9[0], 0, sizeof(boot_params->_pad9)); | ||
35 | } | ||
36 | } | ||
37 | |||
38 | #endif /* _ASM_X86_BOOTPARAM_UTILS_H */ | ||
diff --git a/arch/x86/include/asm/cpufeature.h b/arch/x86/include/asm/cpufeature.h index 2d9075e863a0..93fe929d1cee 100644 --- a/arch/x86/include/asm/cpufeature.h +++ b/arch/x86/include/asm/cpufeature.h | |||
@@ -167,6 +167,7 @@ | |||
167 | #define X86_FEATURE_TBM (6*32+21) /* trailing bit manipulations */ | 167 | #define X86_FEATURE_TBM (6*32+21) /* trailing bit manipulations */ |
168 | #define X86_FEATURE_TOPOEXT (6*32+22) /* topology extensions CPUID leafs */ | 168 | #define X86_FEATURE_TOPOEXT (6*32+22) /* topology extensions CPUID leafs */ |
169 | #define X86_FEATURE_PERFCTR_CORE (6*32+23) /* core performance counter extensions */ | 169 | #define X86_FEATURE_PERFCTR_CORE (6*32+23) /* core performance counter extensions */ |
170 | #define X86_FEATURE_PERFCTR_NB (6*32+24) /* NB performance counter extensions */ | ||
170 | 171 | ||
171 | /* | 172 | /* |
172 | * Auxiliary flags: Linux defined - For features scattered in various | 173 | * Auxiliary flags: Linux defined - For features scattered in various |
@@ -309,6 +310,7 @@ extern const char * const x86_power_flags[32]; | |||
309 | #define cpu_has_hypervisor boot_cpu_has(X86_FEATURE_HYPERVISOR) | 310 | #define cpu_has_hypervisor boot_cpu_has(X86_FEATURE_HYPERVISOR) |
310 | #define cpu_has_pclmulqdq boot_cpu_has(X86_FEATURE_PCLMULQDQ) | 311 | #define cpu_has_pclmulqdq boot_cpu_has(X86_FEATURE_PCLMULQDQ) |
311 | #define cpu_has_perfctr_core boot_cpu_has(X86_FEATURE_PERFCTR_CORE) | 312 | #define cpu_has_perfctr_core boot_cpu_has(X86_FEATURE_PERFCTR_CORE) |
313 | #define cpu_has_perfctr_nb boot_cpu_has(X86_FEATURE_PERFCTR_NB) | ||
312 | #define cpu_has_cx8 boot_cpu_has(X86_FEATURE_CX8) | 314 | #define cpu_has_cx8 boot_cpu_has(X86_FEATURE_CX8) |
313 | #define cpu_has_cx16 boot_cpu_has(X86_FEATURE_CX16) | 315 | #define cpu_has_cx16 boot_cpu_has(X86_FEATURE_CX16) |
314 | #define cpu_has_eager_fpu boot_cpu_has(X86_FEATURE_EAGER_FPU) | 316 | #define cpu_has_eager_fpu boot_cpu_has(X86_FEATURE_EAGER_FPU) |
diff --git a/arch/x86/include/asm/efi.h b/arch/x86/include/asm/efi.h index 6e8fdf5ad113..28677c55113f 100644 --- a/arch/x86/include/asm/efi.h +++ b/arch/x86/include/asm/efi.h | |||
@@ -94,6 +94,7 @@ extern void __iomem *efi_ioremap(unsigned long addr, unsigned long size, | |||
94 | #endif /* CONFIG_X86_32 */ | 94 | #endif /* CONFIG_X86_32 */ |
95 | 95 | ||
96 | extern int add_efi_memmap; | 96 | extern int add_efi_memmap; |
97 | extern unsigned long x86_efi_facility; | ||
97 | extern void efi_set_executable(efi_memory_desc_t *md, bool executable); | 98 | extern void efi_set_executable(efi_memory_desc_t *md, bool executable); |
98 | extern int efi_memblock_x86_reserve_range(void); | 99 | extern int efi_memblock_x86_reserve_range(void); |
99 | extern void efi_call_phys_prelog(void); | 100 | extern void efi_call_phys_prelog(void); |
diff --git a/arch/x86/include/asm/ftrace.h b/arch/x86/include/asm/ftrace.h index 9a25b522d377..86cb51e1ca96 100644 --- a/arch/x86/include/asm/ftrace.h +++ b/arch/x86/include/asm/ftrace.h | |||
@@ -44,7 +44,6 @@ | |||
44 | 44 | ||
45 | #ifdef CONFIG_DYNAMIC_FTRACE | 45 | #ifdef CONFIG_DYNAMIC_FTRACE |
46 | #define ARCH_SUPPORTS_FTRACE_OPS 1 | 46 | #define ARCH_SUPPORTS_FTRACE_OPS 1 |
47 | #define ARCH_SUPPORTS_FTRACE_SAVE_REGS | ||
48 | #endif | 47 | #endif |
49 | 48 | ||
50 | #ifndef __ASSEMBLY__ | 49 | #ifndef __ASSEMBLY__ |
diff --git a/arch/x86/include/asm/hpet.h b/arch/x86/include/asm/hpet.h index 434e2106cc87..b18df579c0e9 100644 --- a/arch/x86/include/asm/hpet.h +++ b/arch/x86/include/asm/hpet.h | |||
@@ -80,9 +80,9 @@ extern void hpet_msi_write(struct hpet_dev *hdev, struct msi_msg *msg); | |||
80 | extern void hpet_msi_read(struct hpet_dev *hdev, struct msi_msg *msg); | 80 | extern void hpet_msi_read(struct hpet_dev *hdev, struct msi_msg *msg); |
81 | 81 | ||
82 | #ifdef CONFIG_PCI_MSI | 82 | #ifdef CONFIG_PCI_MSI |
83 | extern int arch_setup_hpet_msi(unsigned int irq, unsigned int id); | 83 | extern int default_setup_hpet_msi(unsigned int irq, unsigned int id); |
84 | #else | 84 | #else |
85 | static inline int arch_setup_hpet_msi(unsigned int irq, unsigned int id) | 85 | static inline int default_setup_hpet_msi(unsigned int irq, unsigned int id) |
86 | { | 86 | { |
87 | return -EINVAL; | 87 | return -EINVAL; |
88 | } | 88 | } |
@@ -111,6 +111,7 @@ extern void hpet_unregister_irq_handler(rtc_irq_handler handler); | |||
111 | static inline int hpet_enable(void) { return 0; } | 111 | static inline int hpet_enable(void) { return 0; } |
112 | static inline int is_hpet_enabled(void) { return 0; } | 112 | static inline int is_hpet_enabled(void) { return 0; } |
113 | #define hpet_readl(a) 0 | 113 | #define hpet_readl(a) 0 |
114 | #define default_setup_hpet_msi NULL | ||
114 | 115 | ||
115 | #endif | 116 | #endif |
116 | #endif /* _ASM_X86_HPET_H */ | 117 | #endif /* _ASM_X86_HPET_H */ |
diff --git a/arch/x86/include/asm/hw_irq.h b/arch/x86/include/asm/hw_irq.h index eb92a6ed2be7..10a78c3d3d5a 100644 --- a/arch/x86/include/asm/hw_irq.h +++ b/arch/x86/include/asm/hw_irq.h | |||
@@ -101,6 +101,7 @@ static inline void set_io_apic_irq_attr(struct io_apic_irq_attr *irq_attr, | |||
101 | irq_attr->polarity = polarity; | 101 | irq_attr->polarity = polarity; |
102 | } | 102 | } |
103 | 103 | ||
104 | /* Intel specific interrupt remapping information */ | ||
104 | struct irq_2_iommu { | 105 | struct irq_2_iommu { |
105 | struct intel_iommu *iommu; | 106 | struct intel_iommu *iommu; |
106 | u16 irte_index; | 107 | u16 irte_index; |
@@ -108,6 +109,12 @@ struct irq_2_iommu { | |||
108 | u8 irte_mask; | 109 | u8 irte_mask; |
109 | }; | 110 | }; |
110 | 111 | ||
112 | /* AMD specific interrupt remapping information */ | ||
113 | struct irq_2_irte { | ||
114 | u16 devid; /* Device ID for IRTE table */ | ||
115 | u16 index; /* Index into IRTE table*/ | ||
116 | }; | ||
117 | |||
111 | /* | 118 | /* |
112 | * This is performance-critical, we want to do it O(1) | 119 | * This is performance-critical, we want to do it O(1) |
113 | * | 120 | * |
@@ -120,7 +127,11 @@ struct irq_cfg { | |||
120 | u8 vector; | 127 | u8 vector; |
121 | u8 move_in_progress : 1; | 128 | u8 move_in_progress : 1; |
122 | #ifdef CONFIG_IRQ_REMAP | 129 | #ifdef CONFIG_IRQ_REMAP |
123 | struct irq_2_iommu irq_2_iommu; | 130 | u8 remapped : 1; |
131 | union { | ||
132 | struct irq_2_iommu irq_2_iommu; | ||
133 | struct irq_2_irte irq_2_irte; | ||
134 | }; | ||
124 | #endif | 135 | #endif |
125 | }; | 136 | }; |
126 | 137 | ||
diff --git a/arch/x86/include/asm/hypervisor.h b/arch/x86/include/asm/hypervisor.h index b518c7509933..86095ed14135 100644 --- a/arch/x86/include/asm/hypervisor.h +++ b/arch/x86/include/asm/hypervisor.h | |||
@@ -25,6 +25,7 @@ | |||
25 | 25 | ||
26 | extern void init_hypervisor(struct cpuinfo_x86 *c); | 26 | extern void init_hypervisor(struct cpuinfo_x86 *c); |
27 | extern void init_hypervisor_platform(void); | 27 | extern void init_hypervisor_platform(void); |
28 | extern bool hypervisor_x2apic_available(void); | ||
28 | 29 | ||
29 | /* | 30 | /* |
30 | * x86 hypervisor information | 31 | * x86 hypervisor information |
@@ -41,6 +42,9 @@ struct hypervisor_x86 { | |||
41 | 42 | ||
42 | /* Platform setup (run once per boot) */ | 43 | /* Platform setup (run once per boot) */ |
43 | void (*init_platform)(void); | 44 | void (*init_platform)(void); |
45 | |||
46 | /* X2APIC detection (run once per boot) */ | ||
47 | bool (*x2apic_available)(void); | ||
44 | }; | 48 | }; |
45 | 49 | ||
46 | extern const struct hypervisor_x86 *x86_hyper; | 50 | extern const struct hypervisor_x86 *x86_hyper; |
@@ -51,13 +55,4 @@ extern const struct hypervisor_x86 x86_hyper_ms_hyperv; | |||
51 | extern const struct hypervisor_x86 x86_hyper_xen_hvm; | 55 | extern const struct hypervisor_x86 x86_hyper_xen_hvm; |
52 | extern const struct hypervisor_x86 x86_hyper_kvm; | 56 | extern const struct hypervisor_x86 x86_hyper_kvm; |
53 | 57 | ||
54 | static inline bool hypervisor_x2apic_available(void) | ||
55 | { | ||
56 | if (kvm_para_available()) | ||
57 | return true; | ||
58 | if (xen_x2apic_para_available()) | ||
59 | return true; | ||
60 | return false; | ||
61 | } | ||
62 | |||
63 | #endif | 58 | #endif |
diff --git a/arch/x86/include/asm/io_apic.h b/arch/x86/include/asm/io_apic.h index 73d8c5398ea9..459e50a424d1 100644 --- a/arch/x86/include/asm/io_apic.h +++ b/arch/x86/include/asm/io_apic.h | |||
@@ -144,11 +144,24 @@ extern int timer_through_8259; | |||
144 | (mp_irq_entries && !skip_ioapic_setup && io_apic_irqs) | 144 | (mp_irq_entries && !skip_ioapic_setup && io_apic_irqs) |
145 | 145 | ||
146 | struct io_apic_irq_attr; | 146 | struct io_apic_irq_attr; |
147 | struct irq_cfg; | ||
147 | extern int io_apic_set_pci_routing(struct device *dev, int irq, | 148 | extern int io_apic_set_pci_routing(struct device *dev, int irq, |
148 | struct io_apic_irq_attr *irq_attr); | 149 | struct io_apic_irq_attr *irq_attr); |
149 | void setup_IO_APIC_irq_extra(u32 gsi); | 150 | void setup_IO_APIC_irq_extra(u32 gsi); |
150 | extern void ioapic_insert_resources(void); | 151 | extern void ioapic_insert_resources(void); |
151 | 152 | ||
153 | extern int native_setup_ioapic_entry(int, struct IO_APIC_route_entry *, | ||
154 | unsigned int, int, | ||
155 | struct io_apic_irq_attr *); | ||
156 | extern int native_setup_ioapic_entry(int, struct IO_APIC_route_entry *, | ||
157 | unsigned int, int, | ||
158 | struct io_apic_irq_attr *); | ||
159 | extern void eoi_ioapic_irq(unsigned int irq, struct irq_cfg *cfg); | ||
160 | |||
161 | extern void native_compose_msi_msg(struct pci_dev *pdev, | ||
162 | unsigned int irq, unsigned int dest, | ||
163 | struct msi_msg *msg, u8 hpet_id); | ||
164 | extern void native_eoi_ioapic_pin(int apic, int pin, int vector); | ||
152 | int io_apic_setup_irq_pin_once(unsigned int irq, int node, struct io_apic_irq_attr *attr); | 165 | int io_apic_setup_irq_pin_once(unsigned int irq, int node, struct io_apic_irq_attr *attr); |
153 | 166 | ||
154 | extern int save_ioapic_entries(void); | 167 | extern int save_ioapic_entries(void); |
@@ -179,6 +192,12 @@ extern void __init native_io_apic_init_mappings(void); | |||
179 | extern unsigned int native_io_apic_read(unsigned int apic, unsigned int reg); | 192 | extern unsigned int native_io_apic_read(unsigned int apic, unsigned int reg); |
180 | extern void native_io_apic_write(unsigned int apic, unsigned int reg, unsigned int val); | 193 | extern void native_io_apic_write(unsigned int apic, unsigned int reg, unsigned int val); |
181 | extern void native_io_apic_modify(unsigned int apic, unsigned int reg, unsigned int val); | 194 | extern void native_io_apic_modify(unsigned int apic, unsigned int reg, unsigned int val); |
195 | extern void native_disable_io_apic(void); | ||
196 | extern void native_io_apic_print_entries(unsigned int apic, unsigned int nr_entries); | ||
197 | extern void intel_ir_io_apic_print_entries(unsigned int apic, unsigned int nr_entries); | ||
198 | extern int native_ioapic_set_affinity(struct irq_data *, | ||
199 | const struct cpumask *, | ||
200 | bool); | ||
182 | 201 | ||
183 | static inline unsigned int io_apic_read(unsigned int apic, unsigned int reg) | 202 | static inline unsigned int io_apic_read(unsigned int apic, unsigned int reg) |
184 | { | 203 | { |
@@ -193,6 +212,9 @@ static inline void io_apic_modify(unsigned int apic, unsigned int reg, unsigned | |||
193 | { | 212 | { |
194 | x86_io_apic_ops.modify(apic, reg, value); | 213 | x86_io_apic_ops.modify(apic, reg, value); |
195 | } | 214 | } |
215 | |||
216 | extern void io_apic_eoi(unsigned int apic, unsigned int vector); | ||
217 | |||
196 | #else /* !CONFIG_X86_IO_APIC */ | 218 | #else /* !CONFIG_X86_IO_APIC */ |
197 | 219 | ||
198 | #define io_apic_assign_pci_irqs 0 | 220 | #define io_apic_assign_pci_irqs 0 |
@@ -223,6 +245,12 @@ static inline void disable_ioapic_support(void) { } | |||
223 | #define native_io_apic_read NULL | 245 | #define native_io_apic_read NULL |
224 | #define native_io_apic_write NULL | 246 | #define native_io_apic_write NULL |
225 | #define native_io_apic_modify NULL | 247 | #define native_io_apic_modify NULL |
248 | #define native_disable_io_apic NULL | ||
249 | #define native_io_apic_print_entries NULL | ||
250 | #define native_ioapic_set_affinity NULL | ||
251 | #define native_setup_ioapic_entry NULL | ||
252 | #define native_compose_msi_msg NULL | ||
253 | #define native_eoi_ioapic_pin NULL | ||
226 | #endif | 254 | #endif |
227 | 255 | ||
228 | #endif /* _ASM_X86_IO_APIC_H */ | 256 | #endif /* _ASM_X86_IO_APIC_H */ |
diff --git a/arch/x86/include/asm/irq_remapping.h b/arch/x86/include/asm/irq_remapping.h index 5fb9bbbd2f14..95fd3527f632 100644 --- a/arch/x86/include/asm/irq_remapping.h +++ b/arch/x86/include/asm/irq_remapping.h | |||
@@ -26,8 +26,6 @@ | |||
26 | 26 | ||
27 | #ifdef CONFIG_IRQ_REMAP | 27 | #ifdef CONFIG_IRQ_REMAP |
28 | 28 | ||
29 | extern int irq_remapping_enabled; | ||
30 | |||
31 | extern void setup_irq_remapping_ops(void); | 29 | extern void setup_irq_remapping_ops(void); |
32 | extern int irq_remapping_supported(void); | 30 | extern int irq_remapping_supported(void); |
33 | extern int irq_remapping_prepare(void); | 31 | extern int irq_remapping_prepare(void); |
@@ -40,21 +38,19 @@ extern int setup_ioapic_remapped_entry(int irq, | |||
40 | unsigned int destination, | 38 | unsigned int destination, |
41 | int vector, | 39 | int vector, |
42 | struct io_apic_irq_attr *attr); | 40 | struct io_apic_irq_attr *attr); |
43 | extern int set_remapped_irq_affinity(struct irq_data *data, | ||
44 | const struct cpumask *mask, | ||
45 | bool force); | ||
46 | extern void free_remapped_irq(int irq); | 41 | extern void free_remapped_irq(int irq); |
47 | extern void compose_remapped_msi_msg(struct pci_dev *pdev, | 42 | extern void compose_remapped_msi_msg(struct pci_dev *pdev, |
48 | unsigned int irq, unsigned int dest, | 43 | unsigned int irq, unsigned int dest, |
49 | struct msi_msg *msg, u8 hpet_id); | 44 | struct msi_msg *msg, u8 hpet_id); |
50 | extern int msi_alloc_remapped_irq(struct pci_dev *pdev, int irq, int nvec); | ||
51 | extern int msi_setup_remapped_irq(struct pci_dev *pdev, unsigned int irq, | ||
52 | int index, int sub_handle); | ||
53 | extern int setup_hpet_msi_remapped(unsigned int irq, unsigned int id); | 45 | extern int setup_hpet_msi_remapped(unsigned int irq, unsigned int id); |
46 | extern void panic_if_irq_remap(const char *msg); | ||
47 | extern bool setup_remapped_irq(int irq, | ||
48 | struct irq_cfg *cfg, | ||
49 | struct irq_chip *chip); | ||
54 | 50 | ||
55 | #else /* CONFIG_IRQ_REMAP */ | 51 | void irq_remap_modify_chip_defaults(struct irq_chip *chip); |
56 | 52 | ||
57 | #define irq_remapping_enabled 0 | 53 | #else /* CONFIG_IRQ_REMAP */ |
58 | 54 | ||
59 | static inline void setup_irq_remapping_ops(void) { } | 55 | static inline void setup_irq_remapping_ops(void) { } |
60 | static inline int irq_remapping_supported(void) { return 0; } | 56 | static inline int irq_remapping_supported(void) { return 0; } |
@@ -71,30 +67,30 @@ static inline int setup_ioapic_remapped_entry(int irq, | |||
71 | { | 67 | { |
72 | return -ENODEV; | 68 | return -ENODEV; |
73 | } | 69 | } |
74 | static inline int set_remapped_irq_affinity(struct irq_data *data, | ||
75 | const struct cpumask *mask, | ||
76 | bool force) | ||
77 | { | ||
78 | return 0; | ||
79 | } | ||
80 | static inline void free_remapped_irq(int irq) { } | 70 | static inline void free_remapped_irq(int irq) { } |
81 | static inline void compose_remapped_msi_msg(struct pci_dev *pdev, | 71 | static inline void compose_remapped_msi_msg(struct pci_dev *pdev, |
82 | unsigned int irq, unsigned int dest, | 72 | unsigned int irq, unsigned int dest, |
83 | struct msi_msg *msg, u8 hpet_id) | 73 | struct msi_msg *msg, u8 hpet_id) |
84 | { | 74 | { |
85 | } | 75 | } |
86 | static inline int msi_alloc_remapped_irq(struct pci_dev *pdev, int irq, int nvec) | 76 | static inline int setup_hpet_msi_remapped(unsigned int irq, unsigned int id) |
87 | { | 77 | { |
88 | return -ENODEV; | 78 | return -ENODEV; |
89 | } | 79 | } |
90 | static inline int msi_setup_remapped_irq(struct pci_dev *pdev, unsigned int irq, | 80 | |
91 | int index, int sub_handle) | 81 | static inline void panic_if_irq_remap(const char *msg) |
82 | { | ||
83 | } | ||
84 | |||
85 | static inline void irq_remap_modify_chip_defaults(struct irq_chip *chip) | ||
92 | { | 86 | { |
93 | return -ENODEV; | ||
94 | } | 87 | } |
95 | static inline int setup_hpet_msi_remapped(unsigned int irq, unsigned int id) | 88 | |
89 | static inline bool setup_remapped_irq(int irq, | ||
90 | struct irq_cfg *cfg, | ||
91 | struct irq_chip *chip) | ||
96 | { | 92 | { |
97 | return -ENODEV; | 93 | return false; |
98 | } | 94 | } |
99 | #endif /* CONFIG_IRQ_REMAP */ | 95 | #endif /* CONFIG_IRQ_REMAP */ |
100 | 96 | ||
diff --git a/arch/x86/include/asm/irq_vectors.h b/arch/x86/include/asm/irq_vectors.h index 1508e518c7e3..aac5fa62a86c 100644 --- a/arch/x86/include/asm/irq_vectors.h +++ b/arch/x86/include/asm/irq_vectors.h | |||
@@ -109,8 +109,8 @@ | |||
109 | 109 | ||
110 | #define UV_BAU_MESSAGE 0xf5 | 110 | #define UV_BAU_MESSAGE 0xf5 |
111 | 111 | ||
112 | /* Xen vector callback to receive events in a HVM domain */ | 112 | /* Vector on which hypervisor callbacks will be delivered */ |
113 | #define XEN_HVM_EVTCHN_CALLBACK 0xf3 | 113 | #define HYPERVISOR_CALLBACK_VECTOR 0xf3 |
114 | 114 | ||
115 | /* | 115 | /* |
116 | * Local APIC timer IRQ vector is on a different priority level, | 116 | * Local APIC timer IRQ vector is on a different priority level, |
diff --git a/arch/x86/include/asm/kvm_para.h b/arch/x86/include/asm/kvm_para.h index 5ed1f16187be..65231e173baf 100644 --- a/arch/x86/include/asm/kvm_para.h +++ b/arch/x86/include/asm/kvm_para.h | |||
@@ -85,13 +85,13 @@ static inline long kvm_hypercall4(unsigned int nr, unsigned long p1, | |||
85 | return ret; | 85 | return ret; |
86 | } | 86 | } |
87 | 87 | ||
88 | static inline int kvm_para_available(void) | 88 | static inline bool kvm_para_available(void) |
89 | { | 89 | { |
90 | unsigned int eax, ebx, ecx, edx; | 90 | unsigned int eax, ebx, ecx, edx; |
91 | char signature[13]; | 91 | char signature[13]; |
92 | 92 | ||
93 | if (boot_cpu_data.cpuid_level < 0) | 93 | if (boot_cpu_data.cpuid_level < 0) |
94 | return 0; /* So we don't blow up on old processors */ | 94 | return false; /* So we don't blow up on old processors */ |
95 | 95 | ||
96 | if (cpu_has_hypervisor) { | 96 | if (cpu_has_hypervisor) { |
97 | cpuid(KVM_CPUID_SIGNATURE, &eax, &ebx, &ecx, &edx); | 97 | cpuid(KVM_CPUID_SIGNATURE, &eax, &ebx, &ecx, &edx); |
@@ -101,10 +101,10 @@ static inline int kvm_para_available(void) | |||
101 | signature[12] = 0; | 101 | signature[12] = 0; |
102 | 102 | ||
103 | if (strcmp(signature, "KVMKVMKVM") == 0) | 103 | if (strcmp(signature, "KVMKVMKVM") == 0) |
104 | return 1; | 104 | return true; |
105 | } | 105 | } |
106 | 106 | ||
107 | return 0; | 107 | return false; |
108 | } | 108 | } |
109 | 109 | ||
110 | static inline unsigned int kvm_arch_para_features(void) | 110 | static inline unsigned int kvm_arch_para_features(void) |
diff --git a/arch/x86/include/asm/linkage.h b/arch/x86/include/asm/linkage.h index 48142971b25d..79327e9483a3 100644 --- a/arch/x86/include/asm/linkage.h +++ b/arch/x86/include/asm/linkage.h | |||
@@ -27,20 +27,20 @@ | |||
27 | #define __asmlinkage_protect0(ret) \ | 27 | #define __asmlinkage_protect0(ret) \ |
28 | __asmlinkage_protect_n(ret) | 28 | __asmlinkage_protect_n(ret) |
29 | #define __asmlinkage_protect1(ret, arg1) \ | 29 | #define __asmlinkage_protect1(ret, arg1) \ |
30 | __asmlinkage_protect_n(ret, "g" (arg1)) | 30 | __asmlinkage_protect_n(ret, "m" (arg1)) |
31 | #define __asmlinkage_protect2(ret, arg1, arg2) \ | 31 | #define __asmlinkage_protect2(ret, arg1, arg2) \ |
32 | __asmlinkage_protect_n(ret, "g" (arg1), "g" (arg2)) | 32 | __asmlinkage_protect_n(ret, "m" (arg1), "m" (arg2)) |
33 | #define __asmlinkage_protect3(ret, arg1, arg2, arg3) \ | 33 | #define __asmlinkage_protect3(ret, arg1, arg2, arg3) \ |
34 | __asmlinkage_protect_n(ret, "g" (arg1), "g" (arg2), "g" (arg3)) | 34 | __asmlinkage_protect_n(ret, "m" (arg1), "m" (arg2), "m" (arg3)) |
35 | #define __asmlinkage_protect4(ret, arg1, arg2, arg3, arg4) \ | 35 | #define __asmlinkage_protect4(ret, arg1, arg2, arg3, arg4) \ |
36 | __asmlinkage_protect_n(ret, "g" (arg1), "g" (arg2), "g" (arg3), \ | 36 | __asmlinkage_protect_n(ret, "m" (arg1), "m" (arg2), "m" (arg3), \ |
37 | "g" (arg4)) | 37 | "m" (arg4)) |
38 | #define __asmlinkage_protect5(ret, arg1, arg2, arg3, arg4, arg5) \ | 38 | #define __asmlinkage_protect5(ret, arg1, arg2, arg3, arg4, arg5) \ |
39 | __asmlinkage_protect_n(ret, "g" (arg1), "g" (arg2), "g" (arg3), \ | 39 | __asmlinkage_protect_n(ret, "m" (arg1), "m" (arg2), "m" (arg3), \ |
40 | "g" (arg4), "g" (arg5)) | 40 | "m" (arg4), "m" (arg5)) |
41 | #define __asmlinkage_protect6(ret, arg1, arg2, arg3, arg4, arg5, arg6) \ | 41 | #define __asmlinkage_protect6(ret, arg1, arg2, arg3, arg4, arg5, arg6) \ |
42 | __asmlinkage_protect_n(ret, "g" (arg1), "g" (arg2), "g" (arg3), \ | 42 | __asmlinkage_protect_n(ret, "m" (arg1), "m" (arg2), "m" (arg3), \ |
43 | "g" (arg4), "g" (arg5), "g" (arg6)) | 43 | "m" (arg4), "m" (arg5), "m" (arg6)) |
44 | 44 | ||
45 | #endif /* CONFIG_X86_32 */ | 45 | #endif /* CONFIG_X86_32 */ |
46 | 46 | ||
diff --git a/arch/x86/include/asm/mce.h b/arch/x86/include/asm/mce.h index ecdfee60ee4a..f4076af1f4ed 100644 --- a/arch/x86/include/asm/mce.h +++ b/arch/x86/include/asm/mce.h | |||
@@ -3,6 +3,90 @@ | |||
3 | 3 | ||
4 | #include <uapi/asm/mce.h> | 4 | #include <uapi/asm/mce.h> |
5 | 5 | ||
6 | /* | ||
7 | * Machine Check support for x86 | ||
8 | */ | ||
9 | |||
10 | /* MCG_CAP register defines */ | ||
11 | #define MCG_BANKCNT_MASK 0xff /* Number of Banks */ | ||
12 | #define MCG_CTL_P (1ULL<<8) /* MCG_CTL register available */ | ||
13 | #define MCG_EXT_P (1ULL<<9) /* Extended registers available */ | ||
14 | #define MCG_CMCI_P (1ULL<<10) /* CMCI supported */ | ||
15 | #define MCG_EXT_CNT_MASK 0xff0000 /* Number of Extended registers */ | ||
16 | #define MCG_EXT_CNT_SHIFT 16 | ||
17 | #define MCG_EXT_CNT(c) (((c) & MCG_EXT_CNT_MASK) >> MCG_EXT_CNT_SHIFT) | ||
18 | #define MCG_SER_P (1ULL<<24) /* MCA recovery/new status bits */ | ||
19 | |||
20 | /* MCG_STATUS register defines */ | ||
21 | #define MCG_STATUS_RIPV (1ULL<<0) /* restart ip valid */ | ||
22 | #define MCG_STATUS_EIPV (1ULL<<1) /* ip points to correct instruction */ | ||
23 | #define MCG_STATUS_MCIP (1ULL<<2) /* machine check in progress */ | ||
24 | |||
25 | /* MCi_STATUS register defines */ | ||
26 | #define MCI_STATUS_VAL (1ULL<<63) /* valid error */ | ||
27 | #define MCI_STATUS_OVER (1ULL<<62) /* previous errors lost */ | ||
28 | #define MCI_STATUS_UC (1ULL<<61) /* uncorrected error */ | ||
29 | #define MCI_STATUS_EN (1ULL<<60) /* error enabled */ | ||
30 | #define MCI_STATUS_MISCV (1ULL<<59) /* misc error reg. valid */ | ||
31 | #define MCI_STATUS_ADDRV (1ULL<<58) /* addr reg. valid */ | ||
32 | #define MCI_STATUS_PCC (1ULL<<57) /* processor context corrupt */ | ||
33 | #define MCI_STATUS_S (1ULL<<56) /* Signaled machine check */ | ||
34 | #define MCI_STATUS_AR (1ULL<<55) /* Action required */ | ||
35 | #define MCACOD 0xffff /* MCA Error Code */ | ||
36 | |||
37 | /* Architecturally defined codes from SDM Vol. 3B Chapter 15 */ | ||
38 | #define MCACOD_SCRUB 0x00C0 /* 0xC0-0xCF Memory Scrubbing */ | ||
39 | #define MCACOD_SCRUBMSK 0xfff0 | ||
40 | #define MCACOD_L3WB 0x017A /* L3 Explicit Writeback */ | ||
41 | #define MCACOD_DATA 0x0134 /* Data Load */ | ||
42 | #define MCACOD_INSTR 0x0150 /* Instruction Fetch */ | ||
43 | |||
44 | /* MCi_MISC register defines */ | ||
45 | #define MCI_MISC_ADDR_LSB(m) ((m) & 0x3f) | ||
46 | #define MCI_MISC_ADDR_MODE(m) (((m) >> 6) & 7) | ||
47 | #define MCI_MISC_ADDR_SEGOFF 0 /* segment offset */ | ||
48 | #define MCI_MISC_ADDR_LINEAR 1 /* linear address */ | ||
49 | #define MCI_MISC_ADDR_PHYS 2 /* physical address */ | ||
50 | #define MCI_MISC_ADDR_MEM 3 /* memory address */ | ||
51 | #define MCI_MISC_ADDR_GENERIC 7 /* generic */ | ||
52 | |||
53 | /* CTL2 register defines */ | ||
54 | #define MCI_CTL2_CMCI_EN (1ULL << 30) | ||
55 | #define MCI_CTL2_CMCI_THRESHOLD_MASK 0x7fffULL | ||
56 | |||
57 | #define MCJ_CTX_MASK 3 | ||
58 | #define MCJ_CTX(flags) ((flags) & MCJ_CTX_MASK) | ||
59 | #define MCJ_CTX_RANDOM 0 /* inject context: random */ | ||
60 | #define MCJ_CTX_PROCESS 0x1 /* inject context: process */ | ||
61 | #define MCJ_CTX_IRQ 0x2 /* inject context: IRQ */ | ||
62 | #define MCJ_NMI_BROADCAST 0x4 /* do NMI broadcasting */ | ||
63 | #define MCJ_EXCEPTION 0x8 /* raise as exception */ | ||
64 | #define MCJ_IRQ_BRAODCAST 0x10 /* do IRQ broadcasting */ | ||
65 | |||
66 | #define MCE_OVERFLOW 0 /* bit 0 in flags means overflow */ | ||
67 | |||
68 | /* Software defined banks */ | ||
69 | #define MCE_EXTENDED_BANK 128 | ||
70 | #define MCE_THERMAL_BANK (MCE_EXTENDED_BANK + 0) | ||
71 | #define K8_MCE_THRESHOLD_BASE (MCE_EXTENDED_BANK + 1) | ||
72 | |||
73 | #define MCE_LOG_LEN 32 | ||
74 | #define MCE_LOG_SIGNATURE "MACHINECHECK" | ||
75 | |||
76 | /* | ||
77 | * This structure contains all data related to the MCE log. Also | ||
78 | * carries a signature to make it easier to find from external | ||
79 | * debugging tools. Each entry is only valid when its finished flag | ||
80 | * is set. | ||
81 | */ | ||
82 | struct mce_log { | ||
83 | char signature[12]; /* "MACHINECHECK" */ | ||
84 | unsigned len; /* = MCE_LOG_LEN */ | ||
85 | unsigned next; | ||
86 | unsigned flags; | ||
87 | unsigned recordlen; /* length of struct mce */ | ||
88 | struct mce entry[MCE_LOG_LEN]; | ||
89 | }; | ||
6 | 90 | ||
7 | struct mca_config { | 91 | struct mca_config { |
8 | bool dont_log_ce; | 92 | bool dont_log_ce; |
diff --git a/arch/x86/include/asm/mshyperv.h b/arch/x86/include/asm/mshyperv.h index 79ce5685ab64..c2934be2446a 100644 --- a/arch/x86/include/asm/mshyperv.h +++ b/arch/x86/include/asm/mshyperv.h | |||
@@ -11,4 +11,8 @@ struct ms_hyperv_info { | |||
11 | 11 | ||
12 | extern struct ms_hyperv_info ms_hyperv; | 12 | extern struct ms_hyperv_info ms_hyperv; |
13 | 13 | ||
14 | void hyperv_callback_vector(void); | ||
15 | void hyperv_vector_handler(struct pt_regs *regs); | ||
16 | void hv_register_vmbus_handler(int irq, irq_handler_t handler); | ||
17 | |||
14 | #endif | 18 | #endif |
diff --git a/arch/x86/include/asm/mwait.h b/arch/x86/include/asm/mwait.h index bcdff997668c..2f366d0ac6b4 100644 --- a/arch/x86/include/asm/mwait.h +++ b/arch/x86/include/asm/mwait.h | |||
@@ -4,7 +4,8 @@ | |||
4 | #define MWAIT_SUBSTATE_MASK 0xf | 4 | #define MWAIT_SUBSTATE_MASK 0xf |
5 | #define MWAIT_CSTATE_MASK 0xf | 5 | #define MWAIT_CSTATE_MASK 0xf |
6 | #define MWAIT_SUBSTATE_SIZE 4 | 6 | #define MWAIT_SUBSTATE_SIZE 4 |
7 | #define MWAIT_MAX_NUM_CSTATES 8 | 7 | #define MWAIT_HINT2CSTATE(hint) (((hint) >> MWAIT_SUBSTATE_SIZE) & MWAIT_CSTATE_MASK) |
8 | #define MWAIT_HINT2SUBSTATE(hint) ((hint) & MWAIT_CSTATE_MASK) | ||
8 | 9 | ||
9 | #define CPUID_MWAIT_LEAF 5 | 10 | #define CPUID_MWAIT_LEAF 5 |
10 | #define CPUID5_ECX_EXTENSIONS_SUPPORTED 0x1 | 11 | #define CPUID5_ECX_EXTENSIONS_SUPPORTED 0x1 |
diff --git a/arch/x86/include/asm/pci.h b/arch/x86/include/asm/pci.h index dba7805176bf..c28fd02f4bf7 100644 --- a/arch/x86/include/asm/pci.h +++ b/arch/x86/include/asm/pci.h | |||
@@ -121,9 +121,12 @@ static inline void x86_restore_msi_irqs(struct pci_dev *dev, int irq) | |||
121 | #define arch_teardown_msi_irq x86_teardown_msi_irq | 121 | #define arch_teardown_msi_irq x86_teardown_msi_irq |
122 | #define arch_restore_msi_irqs x86_restore_msi_irqs | 122 | #define arch_restore_msi_irqs x86_restore_msi_irqs |
123 | /* implemented in arch/x86/kernel/apic/io_apic. */ | 123 | /* implemented in arch/x86/kernel/apic/io_apic. */ |
124 | struct msi_desc; | ||
124 | int native_setup_msi_irqs(struct pci_dev *dev, int nvec, int type); | 125 | int native_setup_msi_irqs(struct pci_dev *dev, int nvec, int type); |
125 | void native_teardown_msi_irq(unsigned int irq); | 126 | void native_teardown_msi_irq(unsigned int irq); |
126 | void native_restore_msi_irqs(struct pci_dev *dev, int irq); | 127 | void native_restore_msi_irqs(struct pci_dev *dev, int irq); |
128 | int setup_msi_irq(struct pci_dev *dev, struct msi_desc *msidesc, | ||
129 | unsigned int irq_base, unsigned int irq_offset); | ||
127 | /* default to the implementation in drivers/lib/msi.c */ | 130 | /* default to the implementation in drivers/lib/msi.c */ |
128 | #define HAVE_DEFAULT_MSI_TEARDOWN_IRQS | 131 | #define HAVE_DEFAULT_MSI_TEARDOWN_IRQS |
129 | #define HAVE_DEFAULT_MSI_RESTORE_IRQS | 132 | #define HAVE_DEFAULT_MSI_RESTORE_IRQS |
diff --git a/arch/x86/include/asm/perf_event.h b/arch/x86/include/asm/perf_event.h index 4fabcdf1cfa7..57cb63402213 100644 --- a/arch/x86/include/asm/perf_event.h +++ b/arch/x86/include/asm/perf_event.h | |||
@@ -29,8 +29,13 @@ | |||
29 | #define ARCH_PERFMON_EVENTSEL_INV (1ULL << 23) | 29 | #define ARCH_PERFMON_EVENTSEL_INV (1ULL << 23) |
30 | #define ARCH_PERFMON_EVENTSEL_CMASK 0xFF000000ULL | 30 | #define ARCH_PERFMON_EVENTSEL_CMASK 0xFF000000ULL |
31 | 31 | ||
32 | #define AMD_PERFMON_EVENTSEL_GUESTONLY (1ULL << 40) | 32 | #define AMD64_EVENTSEL_INT_CORE_ENABLE (1ULL << 36) |
33 | #define AMD_PERFMON_EVENTSEL_HOSTONLY (1ULL << 41) | 33 | #define AMD64_EVENTSEL_GUESTONLY (1ULL << 40) |
34 | #define AMD64_EVENTSEL_HOSTONLY (1ULL << 41) | ||
35 | |||
36 | #define AMD64_EVENTSEL_INT_CORE_SEL_SHIFT 37 | ||
37 | #define AMD64_EVENTSEL_INT_CORE_SEL_MASK \ | ||
38 | (0xFULL << AMD64_EVENTSEL_INT_CORE_SEL_SHIFT) | ||
34 | 39 | ||
35 | #define AMD64_EVENTSEL_EVENT \ | 40 | #define AMD64_EVENTSEL_EVENT \ |
36 | (ARCH_PERFMON_EVENTSEL_EVENT | (0x0FULL << 32)) | 41 | (ARCH_PERFMON_EVENTSEL_EVENT | (0x0FULL << 32)) |
@@ -46,8 +51,12 @@ | |||
46 | #define AMD64_RAW_EVENT_MASK \ | 51 | #define AMD64_RAW_EVENT_MASK \ |
47 | (X86_RAW_EVENT_MASK | \ | 52 | (X86_RAW_EVENT_MASK | \ |
48 | AMD64_EVENTSEL_EVENT) | 53 | AMD64_EVENTSEL_EVENT) |
54 | #define AMD64_RAW_EVENT_MASK_NB \ | ||
55 | (AMD64_EVENTSEL_EVENT | \ | ||
56 | ARCH_PERFMON_EVENTSEL_UMASK) | ||
49 | #define AMD64_NUM_COUNTERS 4 | 57 | #define AMD64_NUM_COUNTERS 4 |
50 | #define AMD64_NUM_COUNTERS_CORE 6 | 58 | #define AMD64_NUM_COUNTERS_CORE 6 |
59 | #define AMD64_NUM_COUNTERS_NB 4 | ||
51 | 60 | ||
52 | #define ARCH_PERFMON_UNHALTED_CORE_CYCLES_SEL 0x3c | 61 | #define ARCH_PERFMON_UNHALTED_CORE_CYCLES_SEL 0x3c |
53 | #define ARCH_PERFMON_UNHALTED_CORE_CYCLES_UMASK (0x00 << 8) | 62 | #define ARCH_PERFMON_UNHALTED_CORE_CYCLES_UMASK (0x00 << 8) |
diff --git a/arch/x86/include/asm/pgtable.h b/arch/x86/include/asm/pgtable.h index 5199db2923d3..fc304279b559 100644 --- a/arch/x86/include/asm/pgtable.h +++ b/arch/x86/include/asm/pgtable.h | |||
@@ -142,6 +142,11 @@ static inline unsigned long pmd_pfn(pmd_t pmd) | |||
142 | return (pmd_val(pmd) & PTE_PFN_MASK) >> PAGE_SHIFT; | 142 | return (pmd_val(pmd) & PTE_PFN_MASK) >> PAGE_SHIFT; |
143 | } | 143 | } |
144 | 144 | ||
145 | static inline unsigned long pud_pfn(pud_t pud) | ||
146 | { | ||
147 | return (pud_val(pud) & PTE_PFN_MASK) >> PAGE_SHIFT; | ||
148 | } | ||
149 | |||
145 | #define pte_page(pte) pfn_to_page(pte_pfn(pte)) | 150 | #define pte_page(pte) pfn_to_page(pte_pfn(pte)) |
146 | 151 | ||
147 | static inline int pmd_large(pmd_t pte) | 152 | static inline int pmd_large(pmd_t pte) |
@@ -781,6 +786,18 @@ static inline void clone_pgd_range(pgd_t *dst, pgd_t *src, int count) | |||
781 | memcpy(dst, src, count * sizeof(pgd_t)); | 786 | memcpy(dst, src, count * sizeof(pgd_t)); |
782 | } | 787 | } |
783 | 788 | ||
789 | /* | ||
790 | * The x86 doesn't have any external MMU info: the kernel page | ||
791 | * tables contain all the necessary information. | ||
792 | */ | ||
793 | static inline void update_mmu_cache(struct vm_area_struct *vma, | ||
794 | unsigned long addr, pte_t *ptep) | ||
795 | { | ||
796 | } | ||
797 | static inline void update_mmu_cache_pmd(struct vm_area_struct *vma, | ||
798 | unsigned long addr, pmd_t *pmd) | ||
799 | { | ||
800 | } | ||
784 | 801 | ||
785 | #include <asm-generic/pgtable.h> | 802 | #include <asm-generic/pgtable.h> |
786 | #endif /* __ASSEMBLY__ */ | 803 | #endif /* __ASSEMBLY__ */ |
diff --git a/arch/x86/include/asm/pgtable_32.h b/arch/x86/include/asm/pgtable_32.h index 8faa215a503e..9ee322103c6d 100644 --- a/arch/x86/include/asm/pgtable_32.h +++ b/arch/x86/include/asm/pgtable_32.h | |||
@@ -66,13 +66,6 @@ do { \ | |||
66 | __flush_tlb_one((vaddr)); \ | 66 | __flush_tlb_one((vaddr)); \ |
67 | } while (0) | 67 | } while (0) |
68 | 68 | ||
69 | /* | ||
70 | * The i386 doesn't have any external MMU info: the kernel page | ||
71 | * tables contain all the necessary information. | ||
72 | */ | ||
73 | #define update_mmu_cache(vma, address, ptep) do { } while (0) | ||
74 | #define update_mmu_cache_pmd(vma, address, pmd) do { } while (0) | ||
75 | |||
76 | #endif /* !__ASSEMBLY__ */ | 69 | #endif /* !__ASSEMBLY__ */ |
77 | 70 | ||
78 | /* | 71 | /* |
diff --git a/arch/x86/include/asm/pgtable_64.h b/arch/x86/include/asm/pgtable_64.h index 47356f9df82e..615b0c78449f 100644 --- a/arch/x86/include/asm/pgtable_64.h +++ b/arch/x86/include/asm/pgtable_64.h | |||
@@ -142,9 +142,6 @@ static inline int pgd_large(pgd_t pgd) { return 0; } | |||
142 | #define pte_offset_map(dir, address) pte_offset_kernel((dir), (address)) | 142 | #define pte_offset_map(dir, address) pte_offset_kernel((dir), (address)) |
143 | #define pte_unmap(pte) ((void)(pte))/* NOP */ | 143 | #define pte_unmap(pte) ((void)(pte))/* NOP */ |
144 | 144 | ||
145 | #define update_mmu_cache(vma, address, ptep) do { } while (0) | ||
146 | #define update_mmu_cache_pmd(vma, address, pmd) do { } while (0) | ||
147 | |||
148 | /* Encode and de-code a swap entry */ | 145 | /* Encode and de-code a swap entry */ |
149 | #if _PAGE_BIT_FILE < _PAGE_BIT_PROTNONE | 146 | #if _PAGE_BIT_FILE < _PAGE_BIT_PROTNONE |
150 | #define SWP_TYPE_BITS (_PAGE_BIT_FILE - _PAGE_BIT_PRESENT - 1) | 147 | #define SWP_TYPE_BITS (_PAGE_BIT_FILE - _PAGE_BIT_PRESENT - 1) |
diff --git a/arch/x86/include/asm/processor.h b/arch/x86/include/asm/processor.h index 888184b2fc85..d172588efae5 100644 --- a/arch/x86/include/asm/processor.h +++ b/arch/x86/include/asm/processor.h | |||
@@ -89,7 +89,6 @@ struct cpuinfo_x86 { | |||
89 | char wp_works_ok; /* It doesn't on 386's */ | 89 | char wp_works_ok; /* It doesn't on 386's */ |
90 | 90 | ||
91 | /* Problems on some 486Dx4's and old 386's: */ | 91 | /* Problems on some 486Dx4's and old 386's: */ |
92 | char hlt_works_ok; | ||
93 | char hard_math; | 92 | char hard_math; |
94 | char rfu; | 93 | char rfu; |
95 | char fdiv_bug; | 94 | char fdiv_bug; |
@@ -165,15 +164,6 @@ DECLARE_PER_CPU_SHARED_ALIGNED(struct cpuinfo_x86, cpu_info); | |||
165 | 164 | ||
166 | extern const struct seq_operations cpuinfo_op; | 165 | extern const struct seq_operations cpuinfo_op; |
167 | 166 | ||
168 | static inline int hlt_works(int cpu) | ||
169 | { | ||
170 | #ifdef CONFIG_X86_32 | ||
171 | return cpu_data(cpu).hlt_works_ok; | ||
172 | #else | ||
173 | return 1; | ||
174 | #endif | ||
175 | } | ||
176 | |||
177 | #define cache_line_size() (boot_cpu_data.x86_cache_alignment) | 167 | #define cache_line_size() (boot_cpu_data.x86_cache_alignment) |
178 | 168 | ||
179 | extern void cpu_detect(struct cpuinfo_x86 *c); | 169 | extern void cpu_detect(struct cpuinfo_x86 *c); |
@@ -725,7 +715,7 @@ extern unsigned long boot_option_idle_override; | |||
725 | extern bool amd_e400_c1e_detected; | 715 | extern bool amd_e400_c1e_detected; |
726 | 716 | ||
727 | enum idle_boot_override {IDLE_NO_OVERRIDE=0, IDLE_HALT, IDLE_NOMWAIT, | 717 | enum idle_boot_override {IDLE_NO_OVERRIDE=0, IDLE_HALT, IDLE_NOMWAIT, |
728 | IDLE_POLL, IDLE_FORCE_MWAIT}; | 718 | IDLE_POLL}; |
729 | 719 | ||
730 | extern void enable_sep_cpu(void); | 720 | extern void enable_sep_cpu(void); |
731 | extern int sysenter_setup(void); | 721 | extern int sysenter_setup(void); |
@@ -943,7 +933,7 @@ extern void start_thread(struct pt_regs *regs, unsigned long new_ip, | |||
943 | extern int get_tsc_mode(unsigned long adr); | 933 | extern int get_tsc_mode(unsigned long adr); |
944 | extern int set_tsc_mode(unsigned int val); | 934 | extern int set_tsc_mode(unsigned int val); |
945 | 935 | ||
946 | extern int amd_get_nb_id(int cpu); | 936 | extern u16 amd_get_nb_id(int cpu); |
947 | 937 | ||
948 | struct aperfmperf { | 938 | struct aperfmperf { |
949 | u64 aperf, mperf; | 939 | u64 aperf, mperf; |
@@ -998,7 +988,11 @@ extern unsigned long arch_align_stack(unsigned long sp); | |||
998 | extern void free_init_pages(char *what, unsigned long begin, unsigned long end); | 988 | extern void free_init_pages(char *what, unsigned long begin, unsigned long end); |
999 | 989 | ||
1000 | void default_idle(void); | 990 | void default_idle(void); |
1001 | bool set_pm_idle_to_default(void); | 991 | #ifdef CONFIG_XEN |
992 | bool xen_set_default_idle(void); | ||
993 | #else | ||
994 | #define xen_set_default_idle 0 | ||
995 | #endif | ||
1002 | 996 | ||
1003 | void stop_this_cpu(void *dummy); | 997 | void stop_this_cpu(void *dummy); |
1004 | 998 | ||
diff --git a/arch/x86/include/asm/required-features.h b/arch/x86/include/asm/required-features.h index 6c7fc25f2c34..5c6e4fb370f5 100644 --- a/arch/x86/include/asm/required-features.h +++ b/arch/x86/include/asm/required-features.h | |||
@@ -47,6 +47,12 @@ | |||
47 | # define NEED_NOPL 0 | 47 | # define NEED_NOPL 0 |
48 | #endif | 48 | #endif |
49 | 49 | ||
50 | #ifdef CONFIG_MATOM | ||
51 | # define NEED_MOVBE (1<<(X86_FEATURE_MOVBE & 31)) | ||
52 | #else | ||
53 | # define NEED_MOVBE 0 | ||
54 | #endif | ||
55 | |||
50 | #ifdef CONFIG_X86_64 | 56 | #ifdef CONFIG_X86_64 |
51 | #ifdef CONFIG_PARAVIRT | 57 | #ifdef CONFIG_PARAVIRT |
52 | /* Paravirtualized systems may not have PSE or PGE available */ | 58 | /* Paravirtualized systems may not have PSE or PGE available */ |
@@ -80,7 +86,7 @@ | |||
80 | 86 | ||
81 | #define REQUIRED_MASK2 0 | 87 | #define REQUIRED_MASK2 0 |
82 | #define REQUIRED_MASK3 (NEED_NOPL) | 88 | #define REQUIRED_MASK3 (NEED_NOPL) |
83 | #define REQUIRED_MASK4 0 | 89 | #define REQUIRED_MASK4 (NEED_MOVBE) |
84 | #define REQUIRED_MASK5 0 | 90 | #define REQUIRED_MASK5 0 |
85 | #define REQUIRED_MASK6 0 | 91 | #define REQUIRED_MASK6 0 |
86 | #define REQUIRED_MASK7 0 | 92 | #define REQUIRED_MASK7 0 |
diff --git a/arch/x86/include/asm/uv/uv.h b/arch/x86/include/asm/uv/uv.h index b47c2a82ff15..062921ef34e9 100644 --- a/arch/x86/include/asm/uv/uv.h +++ b/arch/x86/include/asm/uv/uv.h | |||
@@ -16,7 +16,7 @@ extern void uv_system_init(void); | |||
16 | extern const struct cpumask *uv_flush_tlb_others(const struct cpumask *cpumask, | 16 | extern const struct cpumask *uv_flush_tlb_others(const struct cpumask *cpumask, |
17 | struct mm_struct *mm, | 17 | struct mm_struct *mm, |
18 | unsigned long start, | 18 | unsigned long start, |
19 | unsigned end, | 19 | unsigned long end, |
20 | unsigned int cpu); | 20 | unsigned int cpu); |
21 | 21 | ||
22 | #else /* X86_UV */ | 22 | #else /* X86_UV */ |
diff --git a/arch/x86/include/asm/uv/uv_hub.h b/arch/x86/include/asm/uv/uv_hub.h index 21f7385badb8..2c32df95bb78 100644 --- a/arch/x86/include/asm/uv/uv_hub.h +++ b/arch/x86/include/asm/uv/uv_hub.h | |||
@@ -5,7 +5,7 @@ | |||
5 | * | 5 | * |
6 | * SGI UV architectural definitions | 6 | * SGI UV architectural definitions |
7 | * | 7 | * |
8 | * Copyright (C) 2007-2010 Silicon Graphics, Inc. All rights reserved. | 8 | * Copyright (C) 2007-2013 Silicon Graphics, Inc. All rights reserved. |
9 | */ | 9 | */ |
10 | 10 | ||
11 | #ifndef _ASM_X86_UV_UV_HUB_H | 11 | #ifndef _ASM_X86_UV_UV_HUB_H |
@@ -175,6 +175,7 @@ DECLARE_PER_CPU(struct uv_hub_info_s, __uv_hub_info); | |||
175 | */ | 175 | */ |
176 | #define UV1_HUB_REVISION_BASE 1 | 176 | #define UV1_HUB_REVISION_BASE 1 |
177 | #define UV2_HUB_REVISION_BASE 3 | 177 | #define UV2_HUB_REVISION_BASE 3 |
178 | #define UV3_HUB_REVISION_BASE 5 | ||
178 | 179 | ||
179 | static inline int is_uv1_hub(void) | 180 | static inline int is_uv1_hub(void) |
180 | { | 181 | { |
@@ -183,6 +184,23 @@ static inline int is_uv1_hub(void) | |||
183 | 184 | ||
184 | static inline int is_uv2_hub(void) | 185 | static inline int is_uv2_hub(void) |
185 | { | 186 | { |
187 | return ((uv_hub_info->hub_revision >= UV2_HUB_REVISION_BASE) && | ||
188 | (uv_hub_info->hub_revision < UV3_HUB_REVISION_BASE)); | ||
189 | } | ||
190 | |||
191 | static inline int is_uv3_hub(void) | ||
192 | { | ||
193 | return uv_hub_info->hub_revision >= UV3_HUB_REVISION_BASE; | ||
194 | } | ||
195 | |||
196 | static inline int is_uv_hub(void) | ||
197 | { | ||
198 | return uv_hub_info->hub_revision; | ||
199 | } | ||
200 | |||
201 | /* code common to uv2 and uv3 only */ | ||
202 | static inline int is_uvx_hub(void) | ||
203 | { | ||
186 | return uv_hub_info->hub_revision >= UV2_HUB_REVISION_BASE; | 204 | return uv_hub_info->hub_revision >= UV2_HUB_REVISION_BASE; |
187 | } | 205 | } |
188 | 206 | ||
@@ -230,14 +248,23 @@ union uvh_apicid { | |||
230 | #define UV2_LOCAL_MMR_SIZE (32UL * 1024 * 1024) | 248 | #define UV2_LOCAL_MMR_SIZE (32UL * 1024 * 1024) |
231 | #define UV2_GLOBAL_MMR32_SIZE (32UL * 1024 * 1024) | 249 | #define UV2_GLOBAL_MMR32_SIZE (32UL * 1024 * 1024) |
232 | 250 | ||
233 | #define UV_LOCAL_MMR_BASE (is_uv1_hub() ? UV1_LOCAL_MMR_BASE \ | 251 | #define UV3_LOCAL_MMR_BASE 0xfa000000UL |
234 | : UV2_LOCAL_MMR_BASE) | 252 | #define UV3_GLOBAL_MMR32_BASE 0xfc000000UL |
235 | #define UV_GLOBAL_MMR32_BASE (is_uv1_hub() ? UV1_GLOBAL_MMR32_BASE \ | 253 | #define UV3_LOCAL_MMR_SIZE (32UL * 1024 * 1024) |
236 | : UV2_GLOBAL_MMR32_BASE) | 254 | #define UV3_GLOBAL_MMR32_SIZE (32UL * 1024 * 1024) |
237 | #define UV_LOCAL_MMR_SIZE (is_uv1_hub() ? UV1_LOCAL_MMR_SIZE : \ | 255 | |
238 | UV2_LOCAL_MMR_SIZE) | 256 | #define UV_LOCAL_MMR_BASE (is_uv1_hub() ? UV1_LOCAL_MMR_BASE : \ |
257 | (is_uv2_hub() ? UV2_LOCAL_MMR_BASE : \ | ||
258 | UV3_LOCAL_MMR_BASE)) | ||
259 | #define UV_GLOBAL_MMR32_BASE (is_uv1_hub() ? UV1_GLOBAL_MMR32_BASE :\ | ||
260 | (is_uv2_hub() ? UV2_GLOBAL_MMR32_BASE :\ | ||
261 | UV3_GLOBAL_MMR32_BASE)) | ||
262 | #define UV_LOCAL_MMR_SIZE (is_uv1_hub() ? UV1_LOCAL_MMR_SIZE : \ | ||
263 | (is_uv2_hub() ? UV2_LOCAL_MMR_SIZE : \ | ||
264 | UV3_LOCAL_MMR_SIZE)) | ||
239 | #define UV_GLOBAL_MMR32_SIZE (is_uv1_hub() ? UV1_GLOBAL_MMR32_SIZE :\ | 265 | #define UV_GLOBAL_MMR32_SIZE (is_uv1_hub() ? UV1_GLOBAL_MMR32_SIZE :\ |
240 | UV2_GLOBAL_MMR32_SIZE) | 266 | (is_uv2_hub() ? UV2_GLOBAL_MMR32_SIZE :\ |
267 | UV3_GLOBAL_MMR32_SIZE)) | ||
241 | #define UV_GLOBAL_MMR64_BASE (uv_hub_info->global_mmr_base) | 268 | #define UV_GLOBAL_MMR64_BASE (uv_hub_info->global_mmr_base) |
242 | 269 | ||
243 | #define UV_GLOBAL_GRU_MMR_BASE 0x4000000 | 270 | #define UV_GLOBAL_GRU_MMR_BASE 0x4000000 |
@@ -599,6 +626,7 @@ static inline void uv_hub_send_ipi(int pnode, int apicid, int vector) | |||
599 | * 1 - UV1 rev 1.0 initial silicon | 626 | * 1 - UV1 rev 1.0 initial silicon |
600 | * 2 - UV1 rev 2.0 production silicon | 627 | * 2 - UV1 rev 2.0 production silicon |
601 | * 3 - UV2 rev 1.0 initial silicon | 628 | * 3 - UV2 rev 1.0 initial silicon |
629 | * 5 - UV3 rev 1.0 initial silicon | ||
602 | */ | 630 | */ |
603 | static inline int uv_get_min_hub_revision_id(void) | 631 | static inline int uv_get_min_hub_revision_id(void) |
604 | { | 632 | { |
diff --git a/arch/x86/include/asm/uv/uv_mmrs.h b/arch/x86/include/asm/uv/uv_mmrs.h index cf1d73643f60..bd5f80e58a23 100644 --- a/arch/x86/include/asm/uv/uv_mmrs.h +++ b/arch/x86/include/asm/uv/uv_mmrs.h | |||
@@ -5,16 +5,25 @@ | |||
5 | * | 5 | * |
6 | * SGI UV MMR definitions | 6 | * SGI UV MMR definitions |
7 | * | 7 | * |
8 | * Copyright (C) 2007-2011 Silicon Graphics, Inc. All rights reserved. | 8 | * Copyright (C) 2007-2013 Silicon Graphics, Inc. All rights reserved. |
9 | */ | 9 | */ |
10 | 10 | ||
11 | #ifndef _ASM_X86_UV_UV_MMRS_H | 11 | #ifndef _ASM_X86_UV_UV_MMRS_H |
12 | #define _ASM_X86_UV_UV_MMRS_H | 12 | #define _ASM_X86_UV_UV_MMRS_H |
13 | 13 | ||
14 | /* | 14 | /* |
15 | * This file contains MMR definitions for both UV1 & UV2 hubs. | 15 | * This file contains MMR definitions for all UV hubs types. |
16 | * | 16 | * |
17 | * In general, MMR addresses and structures are identical on both hubs. | 17 | * To minimize coding differences between hub types, the symbols are |
18 | * grouped by architecture types. | ||
19 | * | ||
20 | * UVH - definitions common to all UV hub types. | ||
21 | * UVXH - definitions common to all UV eXtended hub types (currently 2 & 3). | ||
22 | * UV1H - definitions specific to UV type 1 hub. | ||
23 | * UV2H - definitions specific to UV type 2 hub. | ||
24 | * UV3H - definitions specific to UV type 3 hub. | ||
25 | * | ||
26 | * So in general, MMR addresses and structures are identical on all hubs types. | ||
18 | * These MMRs are identified as: | 27 | * These MMRs are identified as: |
19 | * #define UVH_xxx <address> | 28 | * #define UVH_xxx <address> |
20 | * union uvh_xxx { | 29 | * union uvh_xxx { |
@@ -23,24 +32,36 @@ | |||
23 | * } s; | 32 | * } s; |
24 | * }; | 33 | * }; |
25 | * | 34 | * |
26 | * If the MMR exists on both hub type but has different addresses or | 35 | * If the MMR exists on all hub types but have different addresses: |
27 | * contents, the MMR definition is similar to: | 36 | * #define UV1Hxxx a |
28 | * #define UV1H_xxx <uv1 address> | 37 | * #define UV2Hxxx b |
29 | * #define UV2H_xxx <uv2address> | 38 | * #define UV3Hxxx c |
30 | * #define UVH_xxx (is_uv1_hub() ? UV1H_xxx : UV2H_xxx) | 39 | * #define UVHxxx (is_uv1_hub() ? UV1Hxxx : |
40 | * (is_uv2_hub() ? UV2Hxxx : | ||
41 | * UV3Hxxx)) | ||
42 | * | ||
43 | * If the MMR exists on all hub types > 1 but have different addresses: | ||
44 | * #define UV2Hxxx b | ||
45 | * #define UV3Hxxx c | ||
46 | * #define UVXHxxx (is_uv2_hub() ? UV2Hxxx : | ||
47 | * UV3Hxxx)) | ||
48 | * | ||
31 | * union uvh_xxx { | 49 | * union uvh_xxx { |
32 | * unsigned long v; | 50 | * unsigned long v; |
33 | * struct uv1h_int_cmpd_s { (Common fields only) | 51 | * struct uvh_xxx_s { # Common fields only |
34 | * } s; | 52 | * } s; |
35 | * struct uv1h_int_cmpd_s { (Full UV1 definition) | 53 | * struct uv1h_xxx_s { # Full UV1 definition (*) |
36 | * } s1; | 54 | * } s1; |
37 | * struct uv2h_int_cmpd_s { (Full UV2 definition) | 55 | * struct uv2h_xxx_s { # Full UV2 definition (*) |
38 | * } s2; | 56 | * } s2; |
57 | * struct uv3h_xxx_s { # Full UV3 definition (*) | ||
58 | * } s3; | ||
39 | * }; | 59 | * }; |
60 | * (* - if present and different than the common struct) | ||
40 | * | 61 | * |
41 | * Only essential difference are enumerated. For example, if the address is | 62 | * Only essential differences are enumerated. For example, if the address is |
42 | * the same for both UV1 & UV2, only a single #define is generated. Likewise, | 63 | * the same for all UV's, only a single #define is generated. Likewise, |
43 | * if the contents is the same for both hubs, only the "s" structure is | 64 | * if the contents is the same for all hubs, only the "s" structure is |
44 | * generated. | 65 | * generated. |
45 | * | 66 | * |
46 | * If the MMR exists on ONLY 1 type of hub, no generic definition is | 67 | * If the MMR exists on ONLY 1 type of hub, no generic definition is |
@@ -51,6 +72,8 @@ | |||
51 | * struct uvh_int_cmpd_s { | 72 | * struct uvh_int_cmpd_s { |
52 | * } sn; | 73 | * } sn; |
53 | * }; | 74 | * }; |
75 | * | ||
76 | * (GEN Flags: mflags_opt= undefs=0 UV23=UVXH) | ||
54 | */ | 77 | */ |
55 | 78 | ||
56 | #define UV_MMR_ENABLE (1UL << 63) | 79 | #define UV_MMR_ENABLE (1UL << 63) |
@@ -58,15 +81,18 @@ | |||
58 | #define UV1_HUB_PART_NUMBER 0x88a5 | 81 | #define UV1_HUB_PART_NUMBER 0x88a5 |
59 | #define UV2_HUB_PART_NUMBER 0x8eb8 | 82 | #define UV2_HUB_PART_NUMBER 0x8eb8 |
60 | #define UV2_HUB_PART_NUMBER_X 0x1111 | 83 | #define UV2_HUB_PART_NUMBER_X 0x1111 |
84 | #define UV3_HUB_PART_NUMBER 0x9578 | ||
85 | #define UV3_HUB_PART_NUMBER_X 0x4321 | ||
61 | 86 | ||
62 | /* Compat: if this #define is present, UV headers support UV2 */ | 87 | /* Compat: Indicate which UV Hubs are supported. */ |
63 | #define UV2_HUB_IS_SUPPORTED 1 | 88 | #define UV2_HUB_IS_SUPPORTED 1 |
89 | #define UV3_HUB_IS_SUPPORTED 1 | ||
64 | 90 | ||
65 | /* ========================================================================= */ | 91 | /* ========================================================================= */ |
66 | /* UVH_BAU_DATA_BROADCAST */ | 92 | /* UVH_BAU_DATA_BROADCAST */ |
67 | /* ========================================================================= */ | 93 | /* ========================================================================= */ |
68 | #define UVH_BAU_DATA_BROADCAST 0x61688UL | 94 | #define UVH_BAU_DATA_BROADCAST 0x61688UL |
69 | #define UVH_BAU_DATA_BROADCAST_32 0x440 | 95 | #define UVH_BAU_DATA_BROADCAST_32 0x440 |
70 | 96 | ||
71 | #define UVH_BAU_DATA_BROADCAST_ENABLE_SHFT 0 | 97 | #define UVH_BAU_DATA_BROADCAST_ENABLE_SHFT 0 |
72 | #define UVH_BAU_DATA_BROADCAST_ENABLE_MASK 0x0000000000000001UL | 98 | #define UVH_BAU_DATA_BROADCAST_ENABLE_MASK 0x0000000000000001UL |
@@ -82,8 +108,8 @@ union uvh_bau_data_broadcast_u { | |||
82 | /* ========================================================================= */ | 108 | /* ========================================================================= */ |
83 | /* UVH_BAU_DATA_CONFIG */ | 109 | /* UVH_BAU_DATA_CONFIG */ |
84 | /* ========================================================================= */ | 110 | /* ========================================================================= */ |
85 | #define UVH_BAU_DATA_CONFIG 0x61680UL | 111 | #define UVH_BAU_DATA_CONFIG 0x61680UL |
86 | #define UVH_BAU_DATA_CONFIG_32 0x438 | 112 | #define UVH_BAU_DATA_CONFIG_32 0x438 |
87 | 113 | ||
88 | #define UVH_BAU_DATA_CONFIG_VECTOR_SHFT 0 | 114 | #define UVH_BAU_DATA_CONFIG_VECTOR_SHFT 0 |
89 | #define UVH_BAU_DATA_CONFIG_DM_SHFT 8 | 115 | #define UVH_BAU_DATA_CONFIG_DM_SHFT 8 |
@@ -121,10 +147,14 @@ union uvh_bau_data_config_u { | |||
121 | /* ========================================================================= */ | 147 | /* ========================================================================= */ |
122 | /* UVH_EVENT_OCCURRED0 */ | 148 | /* UVH_EVENT_OCCURRED0 */ |
123 | /* ========================================================================= */ | 149 | /* ========================================================================= */ |
124 | #define UVH_EVENT_OCCURRED0 0x70000UL | 150 | #define UVH_EVENT_OCCURRED0 0x70000UL |
125 | #define UVH_EVENT_OCCURRED0_32 0x5e8 | 151 | #define UVH_EVENT_OCCURRED0_32 0x5e8 |
152 | |||
153 | #define UVH_EVENT_OCCURRED0_LB_HCERR_SHFT 0 | ||
154 | #define UVH_EVENT_OCCURRED0_RH_AOERR0_SHFT 11 | ||
155 | #define UVH_EVENT_OCCURRED0_LB_HCERR_MASK 0x0000000000000001UL | ||
156 | #define UVH_EVENT_OCCURRED0_RH_AOERR0_MASK 0x0000000000000800UL | ||
126 | 157 | ||
127 | #define UV1H_EVENT_OCCURRED0_LB_HCERR_SHFT 0 | ||
128 | #define UV1H_EVENT_OCCURRED0_GR0_HCERR_SHFT 1 | 158 | #define UV1H_EVENT_OCCURRED0_GR0_HCERR_SHFT 1 |
129 | #define UV1H_EVENT_OCCURRED0_GR1_HCERR_SHFT 2 | 159 | #define UV1H_EVENT_OCCURRED0_GR1_HCERR_SHFT 2 |
130 | #define UV1H_EVENT_OCCURRED0_LH_HCERR_SHFT 3 | 160 | #define UV1H_EVENT_OCCURRED0_LH_HCERR_SHFT 3 |
@@ -135,7 +165,6 @@ union uvh_bau_data_config_u { | |||
135 | #define UV1H_EVENT_OCCURRED0_GR0_AOERR0_SHFT 8 | 165 | #define UV1H_EVENT_OCCURRED0_GR0_AOERR0_SHFT 8 |
136 | #define UV1H_EVENT_OCCURRED0_GR1_AOERR0_SHFT 9 | 166 | #define UV1H_EVENT_OCCURRED0_GR1_AOERR0_SHFT 9 |
137 | #define UV1H_EVENT_OCCURRED0_LH_AOERR0_SHFT 10 | 167 | #define UV1H_EVENT_OCCURRED0_LH_AOERR0_SHFT 10 |
138 | #define UV1H_EVENT_OCCURRED0_RH_AOERR0_SHFT 11 | ||
139 | #define UV1H_EVENT_OCCURRED0_XN_AOERR0_SHFT 12 | 168 | #define UV1H_EVENT_OCCURRED0_XN_AOERR0_SHFT 12 |
140 | #define UV1H_EVENT_OCCURRED0_SI_AOERR0_SHFT 13 | 169 | #define UV1H_EVENT_OCCURRED0_SI_AOERR0_SHFT 13 |
141 | #define UV1H_EVENT_OCCURRED0_LB_AOERR1_SHFT 14 | 170 | #define UV1H_EVENT_OCCURRED0_LB_AOERR1_SHFT 14 |
@@ -181,7 +210,6 @@ union uvh_bau_data_config_u { | |||
181 | #define UV1H_EVENT_OCCURRED0_RTC3_SHFT 54 | 210 | #define UV1H_EVENT_OCCURRED0_RTC3_SHFT 54 |
182 | #define UV1H_EVENT_OCCURRED0_BAU_DATA_SHFT 55 | 211 | #define UV1H_EVENT_OCCURRED0_BAU_DATA_SHFT 55 |
183 | #define UV1H_EVENT_OCCURRED0_POWER_MANAGEMENT_REQ_SHFT 56 | 212 | #define UV1H_EVENT_OCCURRED0_POWER_MANAGEMENT_REQ_SHFT 56 |
184 | #define UV1H_EVENT_OCCURRED0_LB_HCERR_MASK 0x0000000000000001UL | ||
185 | #define UV1H_EVENT_OCCURRED0_GR0_HCERR_MASK 0x0000000000000002UL | 213 | #define UV1H_EVENT_OCCURRED0_GR0_HCERR_MASK 0x0000000000000002UL |
186 | #define UV1H_EVENT_OCCURRED0_GR1_HCERR_MASK 0x0000000000000004UL | 214 | #define UV1H_EVENT_OCCURRED0_GR1_HCERR_MASK 0x0000000000000004UL |
187 | #define UV1H_EVENT_OCCURRED0_LH_HCERR_MASK 0x0000000000000008UL | 215 | #define UV1H_EVENT_OCCURRED0_LH_HCERR_MASK 0x0000000000000008UL |
@@ -192,7 +220,6 @@ union uvh_bau_data_config_u { | |||
192 | #define UV1H_EVENT_OCCURRED0_GR0_AOERR0_MASK 0x0000000000000100UL | 220 | #define UV1H_EVENT_OCCURRED0_GR0_AOERR0_MASK 0x0000000000000100UL |
193 | #define UV1H_EVENT_OCCURRED0_GR1_AOERR0_MASK 0x0000000000000200UL | 221 | #define UV1H_EVENT_OCCURRED0_GR1_AOERR0_MASK 0x0000000000000200UL |
194 | #define UV1H_EVENT_OCCURRED0_LH_AOERR0_MASK 0x0000000000000400UL | 222 | #define UV1H_EVENT_OCCURRED0_LH_AOERR0_MASK 0x0000000000000400UL |
195 | #define UV1H_EVENT_OCCURRED0_RH_AOERR0_MASK 0x0000000000000800UL | ||
196 | #define UV1H_EVENT_OCCURRED0_XN_AOERR0_MASK 0x0000000000001000UL | 223 | #define UV1H_EVENT_OCCURRED0_XN_AOERR0_MASK 0x0000000000001000UL |
197 | #define UV1H_EVENT_OCCURRED0_SI_AOERR0_MASK 0x0000000000002000UL | 224 | #define UV1H_EVENT_OCCURRED0_SI_AOERR0_MASK 0x0000000000002000UL |
198 | #define UV1H_EVENT_OCCURRED0_LB_AOERR1_MASK 0x0000000000004000UL | 225 | #define UV1H_EVENT_OCCURRED0_LB_AOERR1_MASK 0x0000000000004000UL |
@@ -239,188 +266,130 @@ union uvh_bau_data_config_u { | |||
239 | #define UV1H_EVENT_OCCURRED0_BAU_DATA_MASK 0x0080000000000000UL | 266 | #define UV1H_EVENT_OCCURRED0_BAU_DATA_MASK 0x0080000000000000UL |
240 | #define UV1H_EVENT_OCCURRED0_POWER_MANAGEMENT_REQ_MASK 0x0100000000000000UL | 267 | #define UV1H_EVENT_OCCURRED0_POWER_MANAGEMENT_REQ_MASK 0x0100000000000000UL |
241 | 268 | ||
242 | #define UV2H_EVENT_OCCURRED0_LB_HCERR_SHFT 0 | 269 | #define UVXH_EVENT_OCCURRED0_QP_HCERR_SHFT 1 |
243 | #define UV2H_EVENT_OCCURRED0_QP_HCERR_SHFT 1 | 270 | #define UVXH_EVENT_OCCURRED0_RH_HCERR_SHFT 2 |
244 | #define UV2H_EVENT_OCCURRED0_RH_HCERR_SHFT 2 | 271 | #define UVXH_EVENT_OCCURRED0_LH0_HCERR_SHFT 3 |
245 | #define UV2H_EVENT_OCCURRED0_LH0_HCERR_SHFT 3 | 272 | #define UVXH_EVENT_OCCURRED0_LH1_HCERR_SHFT 4 |
246 | #define UV2H_EVENT_OCCURRED0_LH1_HCERR_SHFT 4 | 273 | #define UVXH_EVENT_OCCURRED0_GR0_HCERR_SHFT 5 |
247 | #define UV2H_EVENT_OCCURRED0_GR0_HCERR_SHFT 5 | 274 | #define UVXH_EVENT_OCCURRED0_GR1_HCERR_SHFT 6 |
248 | #define UV2H_EVENT_OCCURRED0_GR1_HCERR_SHFT 6 | 275 | #define UVXH_EVENT_OCCURRED0_NI0_HCERR_SHFT 7 |
249 | #define UV2H_EVENT_OCCURRED0_NI0_HCERR_SHFT 7 | 276 | #define UVXH_EVENT_OCCURRED0_NI1_HCERR_SHFT 8 |
250 | #define UV2H_EVENT_OCCURRED0_NI1_HCERR_SHFT 8 | 277 | #define UVXH_EVENT_OCCURRED0_LB_AOERR0_SHFT 9 |
251 | #define UV2H_EVENT_OCCURRED0_LB_AOERR0_SHFT 9 | 278 | #define UVXH_EVENT_OCCURRED0_QP_AOERR0_SHFT 10 |
252 | #define UV2H_EVENT_OCCURRED0_QP_AOERR0_SHFT 10 | 279 | #define UVXH_EVENT_OCCURRED0_LH0_AOERR0_SHFT 12 |
253 | #define UV2H_EVENT_OCCURRED0_RH_AOERR0_SHFT 11 | 280 | #define UVXH_EVENT_OCCURRED0_LH1_AOERR0_SHFT 13 |
254 | #define UV2H_EVENT_OCCURRED0_LH0_AOERR0_SHFT 12 | 281 | #define UVXH_EVENT_OCCURRED0_GR0_AOERR0_SHFT 14 |
255 | #define UV2H_EVENT_OCCURRED0_LH1_AOERR0_SHFT 13 | 282 | #define UVXH_EVENT_OCCURRED0_GR1_AOERR0_SHFT 15 |
256 | #define UV2H_EVENT_OCCURRED0_GR0_AOERR0_SHFT 14 | 283 | #define UVXH_EVENT_OCCURRED0_XB_AOERR0_SHFT 16 |
257 | #define UV2H_EVENT_OCCURRED0_GR1_AOERR0_SHFT 15 | 284 | #define UVXH_EVENT_OCCURRED0_RT_AOERR0_SHFT 17 |
258 | #define UV2H_EVENT_OCCURRED0_XB_AOERR0_SHFT 16 | 285 | #define UVXH_EVENT_OCCURRED0_NI0_AOERR0_SHFT 18 |
259 | #define UV2H_EVENT_OCCURRED0_RT_AOERR0_SHFT 17 | 286 | #define UVXH_EVENT_OCCURRED0_NI1_AOERR0_SHFT 19 |
260 | #define UV2H_EVENT_OCCURRED0_NI0_AOERR0_SHFT 18 | 287 | #define UVXH_EVENT_OCCURRED0_LB_AOERR1_SHFT 20 |
261 | #define UV2H_EVENT_OCCURRED0_NI1_AOERR0_SHFT 19 | 288 | #define UVXH_EVENT_OCCURRED0_QP_AOERR1_SHFT 21 |
262 | #define UV2H_EVENT_OCCURRED0_LB_AOERR1_SHFT 20 | 289 | #define UVXH_EVENT_OCCURRED0_RH_AOERR1_SHFT 22 |
263 | #define UV2H_EVENT_OCCURRED0_QP_AOERR1_SHFT 21 | 290 | #define UVXH_EVENT_OCCURRED0_LH0_AOERR1_SHFT 23 |
264 | #define UV2H_EVENT_OCCURRED0_RH_AOERR1_SHFT 22 | 291 | #define UVXH_EVENT_OCCURRED0_LH1_AOERR1_SHFT 24 |
265 | #define UV2H_EVENT_OCCURRED0_LH0_AOERR1_SHFT 23 | 292 | #define UVXH_EVENT_OCCURRED0_GR0_AOERR1_SHFT 25 |
266 | #define UV2H_EVENT_OCCURRED0_LH1_AOERR1_SHFT 24 | 293 | #define UVXH_EVENT_OCCURRED0_GR1_AOERR1_SHFT 26 |
267 | #define UV2H_EVENT_OCCURRED0_GR0_AOERR1_SHFT 25 | 294 | #define UVXH_EVENT_OCCURRED0_XB_AOERR1_SHFT 27 |
268 | #define UV2H_EVENT_OCCURRED0_GR1_AOERR1_SHFT 26 | 295 | #define UVXH_EVENT_OCCURRED0_RT_AOERR1_SHFT 28 |
269 | #define UV2H_EVENT_OCCURRED0_XB_AOERR1_SHFT 27 | 296 | #define UVXH_EVENT_OCCURRED0_NI0_AOERR1_SHFT 29 |
270 | #define UV2H_EVENT_OCCURRED0_RT_AOERR1_SHFT 28 | 297 | #define UVXH_EVENT_OCCURRED0_NI1_AOERR1_SHFT 30 |
271 | #define UV2H_EVENT_OCCURRED0_NI0_AOERR1_SHFT 29 | 298 | #define UVXH_EVENT_OCCURRED0_SYSTEM_SHUTDOWN_INT_SHFT 31 |
272 | #define UV2H_EVENT_OCCURRED0_NI1_AOERR1_SHFT 30 | 299 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_0_SHFT 32 |
273 | #define UV2H_EVENT_OCCURRED0_SYSTEM_SHUTDOWN_INT_SHFT 31 | 300 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_1_SHFT 33 |
274 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_0_SHFT 32 | 301 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_2_SHFT 34 |
275 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_1_SHFT 33 | 302 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_3_SHFT 35 |
276 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_2_SHFT 34 | 303 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_4_SHFT 36 |
277 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_3_SHFT 35 | 304 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_5_SHFT 37 |
278 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_4_SHFT 36 | 305 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_6_SHFT 38 |
279 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_5_SHFT 37 | 306 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_7_SHFT 39 |
280 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_6_SHFT 38 | 307 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_8_SHFT 40 |
281 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_7_SHFT 39 | 308 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_9_SHFT 41 |
282 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_8_SHFT 40 | 309 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_10_SHFT 42 |
283 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_9_SHFT 41 | 310 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_11_SHFT 43 |
284 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_10_SHFT 42 | 311 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_12_SHFT 44 |
285 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_11_SHFT 43 | 312 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_13_SHFT 45 |
286 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_12_SHFT 44 | 313 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_14_SHFT 46 |
287 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_13_SHFT 45 | 314 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_15_SHFT 47 |
288 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_14_SHFT 46 | 315 | #define UVXH_EVENT_OCCURRED0_L1_NMI_INT_SHFT 48 |
289 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_15_SHFT 47 | 316 | #define UVXH_EVENT_OCCURRED0_STOP_CLOCK_SHFT 49 |
290 | #define UV2H_EVENT_OCCURRED0_L1_NMI_INT_SHFT 48 | 317 | #define UVXH_EVENT_OCCURRED0_ASIC_TO_L1_SHFT 50 |
291 | #define UV2H_EVENT_OCCURRED0_STOP_CLOCK_SHFT 49 | 318 | #define UVXH_EVENT_OCCURRED0_L1_TO_ASIC_SHFT 51 |
292 | #define UV2H_EVENT_OCCURRED0_ASIC_TO_L1_SHFT 50 | 319 | #define UVXH_EVENT_OCCURRED0_LA_SEQ_TRIGGER_SHFT 52 |
293 | #define UV2H_EVENT_OCCURRED0_L1_TO_ASIC_SHFT 51 | 320 | #define UVXH_EVENT_OCCURRED0_IPI_INT_SHFT 53 |
294 | #define UV2H_EVENT_OCCURRED0_LA_SEQ_TRIGGER_SHFT 52 | 321 | #define UVXH_EVENT_OCCURRED0_EXTIO_INT0_SHFT 54 |
295 | #define UV2H_EVENT_OCCURRED0_IPI_INT_SHFT 53 | 322 | #define UVXH_EVENT_OCCURRED0_EXTIO_INT1_SHFT 55 |
296 | #define UV2H_EVENT_OCCURRED0_EXTIO_INT0_SHFT 54 | 323 | #define UVXH_EVENT_OCCURRED0_EXTIO_INT2_SHFT 56 |
297 | #define UV2H_EVENT_OCCURRED0_EXTIO_INT1_SHFT 55 | 324 | #define UVXH_EVENT_OCCURRED0_EXTIO_INT3_SHFT 57 |
298 | #define UV2H_EVENT_OCCURRED0_EXTIO_INT2_SHFT 56 | 325 | #define UVXH_EVENT_OCCURRED0_PROFILE_INT_SHFT 58 |
299 | #define UV2H_EVENT_OCCURRED0_EXTIO_INT3_SHFT 57 | 326 | #define UVXH_EVENT_OCCURRED0_QP_HCERR_MASK 0x0000000000000002UL |
300 | #define UV2H_EVENT_OCCURRED0_PROFILE_INT_SHFT 58 | 327 | #define UVXH_EVENT_OCCURRED0_RH_HCERR_MASK 0x0000000000000004UL |
301 | #define UV2H_EVENT_OCCURRED0_LB_HCERR_MASK 0x0000000000000001UL | 328 | #define UVXH_EVENT_OCCURRED0_LH0_HCERR_MASK 0x0000000000000008UL |
302 | #define UV2H_EVENT_OCCURRED0_QP_HCERR_MASK 0x0000000000000002UL | 329 | #define UVXH_EVENT_OCCURRED0_LH1_HCERR_MASK 0x0000000000000010UL |
303 | #define UV2H_EVENT_OCCURRED0_RH_HCERR_MASK 0x0000000000000004UL | 330 | #define UVXH_EVENT_OCCURRED0_GR0_HCERR_MASK 0x0000000000000020UL |
304 | #define UV2H_EVENT_OCCURRED0_LH0_HCERR_MASK 0x0000000000000008UL | 331 | #define UVXH_EVENT_OCCURRED0_GR1_HCERR_MASK 0x0000000000000040UL |
305 | #define UV2H_EVENT_OCCURRED0_LH1_HCERR_MASK 0x0000000000000010UL | 332 | #define UVXH_EVENT_OCCURRED0_NI0_HCERR_MASK 0x0000000000000080UL |
306 | #define UV2H_EVENT_OCCURRED0_GR0_HCERR_MASK 0x0000000000000020UL | 333 | #define UVXH_EVENT_OCCURRED0_NI1_HCERR_MASK 0x0000000000000100UL |
307 | #define UV2H_EVENT_OCCURRED0_GR1_HCERR_MASK 0x0000000000000040UL | 334 | #define UVXH_EVENT_OCCURRED0_LB_AOERR0_MASK 0x0000000000000200UL |
308 | #define UV2H_EVENT_OCCURRED0_NI0_HCERR_MASK 0x0000000000000080UL | 335 | #define UVXH_EVENT_OCCURRED0_QP_AOERR0_MASK 0x0000000000000400UL |
309 | #define UV2H_EVENT_OCCURRED0_NI1_HCERR_MASK 0x0000000000000100UL | 336 | #define UVXH_EVENT_OCCURRED0_LH0_AOERR0_MASK 0x0000000000001000UL |
310 | #define UV2H_EVENT_OCCURRED0_LB_AOERR0_MASK 0x0000000000000200UL | 337 | #define UVXH_EVENT_OCCURRED0_LH1_AOERR0_MASK 0x0000000000002000UL |
311 | #define UV2H_EVENT_OCCURRED0_QP_AOERR0_MASK 0x0000000000000400UL | 338 | #define UVXH_EVENT_OCCURRED0_GR0_AOERR0_MASK 0x0000000000004000UL |
312 | #define UV2H_EVENT_OCCURRED0_RH_AOERR0_MASK 0x0000000000000800UL | 339 | #define UVXH_EVENT_OCCURRED0_GR1_AOERR0_MASK 0x0000000000008000UL |
313 | #define UV2H_EVENT_OCCURRED0_LH0_AOERR0_MASK 0x0000000000001000UL | 340 | #define UVXH_EVENT_OCCURRED0_XB_AOERR0_MASK 0x0000000000010000UL |
314 | #define UV2H_EVENT_OCCURRED0_LH1_AOERR0_MASK 0x0000000000002000UL | 341 | #define UVXH_EVENT_OCCURRED0_RT_AOERR0_MASK 0x0000000000020000UL |
315 | #define UV2H_EVENT_OCCURRED0_GR0_AOERR0_MASK 0x0000000000004000UL | 342 | #define UVXH_EVENT_OCCURRED0_NI0_AOERR0_MASK 0x0000000000040000UL |
316 | #define UV2H_EVENT_OCCURRED0_GR1_AOERR0_MASK 0x0000000000008000UL | 343 | #define UVXH_EVENT_OCCURRED0_NI1_AOERR0_MASK 0x0000000000080000UL |
317 | #define UV2H_EVENT_OCCURRED0_XB_AOERR0_MASK 0x0000000000010000UL | 344 | #define UVXH_EVENT_OCCURRED0_LB_AOERR1_MASK 0x0000000000100000UL |
318 | #define UV2H_EVENT_OCCURRED0_RT_AOERR0_MASK 0x0000000000020000UL | 345 | #define UVXH_EVENT_OCCURRED0_QP_AOERR1_MASK 0x0000000000200000UL |
319 | #define UV2H_EVENT_OCCURRED0_NI0_AOERR0_MASK 0x0000000000040000UL | 346 | #define UVXH_EVENT_OCCURRED0_RH_AOERR1_MASK 0x0000000000400000UL |
320 | #define UV2H_EVENT_OCCURRED0_NI1_AOERR0_MASK 0x0000000000080000UL | 347 | #define UVXH_EVENT_OCCURRED0_LH0_AOERR1_MASK 0x0000000000800000UL |
321 | #define UV2H_EVENT_OCCURRED0_LB_AOERR1_MASK 0x0000000000100000UL | 348 | #define UVXH_EVENT_OCCURRED0_LH1_AOERR1_MASK 0x0000000001000000UL |
322 | #define UV2H_EVENT_OCCURRED0_QP_AOERR1_MASK 0x0000000000200000UL | 349 | #define UVXH_EVENT_OCCURRED0_GR0_AOERR1_MASK 0x0000000002000000UL |
323 | #define UV2H_EVENT_OCCURRED0_RH_AOERR1_MASK 0x0000000000400000UL | 350 | #define UVXH_EVENT_OCCURRED0_GR1_AOERR1_MASK 0x0000000004000000UL |
324 | #define UV2H_EVENT_OCCURRED0_LH0_AOERR1_MASK 0x0000000000800000UL | 351 | #define UVXH_EVENT_OCCURRED0_XB_AOERR1_MASK 0x0000000008000000UL |
325 | #define UV2H_EVENT_OCCURRED0_LH1_AOERR1_MASK 0x0000000001000000UL | 352 | #define UVXH_EVENT_OCCURRED0_RT_AOERR1_MASK 0x0000000010000000UL |
326 | #define UV2H_EVENT_OCCURRED0_GR0_AOERR1_MASK 0x0000000002000000UL | 353 | #define UVXH_EVENT_OCCURRED0_NI0_AOERR1_MASK 0x0000000020000000UL |
327 | #define UV2H_EVENT_OCCURRED0_GR1_AOERR1_MASK 0x0000000004000000UL | 354 | #define UVXH_EVENT_OCCURRED0_NI1_AOERR1_MASK 0x0000000040000000UL |
328 | #define UV2H_EVENT_OCCURRED0_XB_AOERR1_MASK 0x0000000008000000UL | 355 | #define UVXH_EVENT_OCCURRED0_SYSTEM_SHUTDOWN_INT_MASK 0x0000000080000000UL |
329 | #define UV2H_EVENT_OCCURRED0_RT_AOERR1_MASK 0x0000000010000000UL | 356 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_0_MASK 0x0000000100000000UL |
330 | #define UV2H_EVENT_OCCURRED0_NI0_AOERR1_MASK 0x0000000020000000UL | 357 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_1_MASK 0x0000000200000000UL |
331 | #define UV2H_EVENT_OCCURRED0_NI1_AOERR1_MASK 0x0000000040000000UL | 358 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_2_MASK 0x0000000400000000UL |
332 | #define UV2H_EVENT_OCCURRED0_SYSTEM_SHUTDOWN_INT_MASK 0x0000000080000000UL | 359 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_3_MASK 0x0000000800000000UL |
333 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_0_MASK 0x0000000100000000UL | 360 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_4_MASK 0x0000001000000000UL |
334 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_1_MASK 0x0000000200000000UL | 361 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_5_MASK 0x0000002000000000UL |
335 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_2_MASK 0x0000000400000000UL | 362 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_6_MASK 0x0000004000000000UL |
336 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_3_MASK 0x0000000800000000UL | 363 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_7_MASK 0x0000008000000000UL |
337 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_4_MASK 0x0000001000000000UL | 364 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_8_MASK 0x0000010000000000UL |
338 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_5_MASK 0x0000002000000000UL | 365 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_9_MASK 0x0000020000000000UL |
339 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_6_MASK 0x0000004000000000UL | 366 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_10_MASK 0x0000040000000000UL |
340 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_7_MASK 0x0000008000000000UL | 367 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_11_MASK 0x0000080000000000UL |
341 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_8_MASK 0x0000010000000000UL | 368 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_12_MASK 0x0000100000000000UL |
342 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_9_MASK 0x0000020000000000UL | 369 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_13_MASK 0x0000200000000000UL |
343 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_10_MASK 0x0000040000000000UL | 370 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_14_MASK 0x0000400000000000UL |
344 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_11_MASK 0x0000080000000000UL | 371 | #define UVXH_EVENT_OCCURRED0_LB_IRQ_INT_15_MASK 0x0000800000000000UL |
345 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_12_MASK 0x0000100000000000UL | 372 | #define UVXH_EVENT_OCCURRED0_L1_NMI_INT_MASK 0x0001000000000000UL |
346 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_13_MASK 0x0000200000000000UL | 373 | #define UVXH_EVENT_OCCURRED0_STOP_CLOCK_MASK 0x0002000000000000UL |
347 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_14_MASK 0x0000400000000000UL | 374 | #define UVXH_EVENT_OCCURRED0_ASIC_TO_L1_MASK 0x0004000000000000UL |
348 | #define UV2H_EVENT_OCCURRED0_LB_IRQ_INT_15_MASK 0x0000800000000000UL | 375 | #define UVXH_EVENT_OCCURRED0_L1_TO_ASIC_MASK 0x0008000000000000UL |
349 | #define UV2H_EVENT_OCCURRED0_L1_NMI_INT_MASK 0x0001000000000000UL | 376 | #define UVXH_EVENT_OCCURRED0_LA_SEQ_TRIGGER_MASK 0x0010000000000000UL |
350 | #define UV2H_EVENT_OCCURRED0_STOP_CLOCK_MASK 0x0002000000000000UL | 377 | #define UVXH_EVENT_OCCURRED0_IPI_INT_MASK 0x0020000000000000UL |
351 | #define UV2H_EVENT_OCCURRED0_ASIC_TO_L1_MASK 0x0004000000000000UL | 378 | #define UVXH_EVENT_OCCURRED0_EXTIO_INT0_MASK 0x0040000000000000UL |
352 | #define UV2H_EVENT_OCCURRED0_L1_TO_ASIC_MASK 0x0008000000000000UL | 379 | #define UVXH_EVENT_OCCURRED0_EXTIO_INT1_MASK 0x0080000000000000UL |
353 | #define UV2H_EVENT_OCCURRED0_LA_SEQ_TRIGGER_MASK 0x0010000000000000UL | 380 | #define UVXH_EVENT_OCCURRED0_EXTIO_INT2_MASK 0x0100000000000000UL |
354 | #define UV2H_EVENT_OCCURRED0_IPI_INT_MASK 0x0020000000000000UL | 381 | #define UVXH_EVENT_OCCURRED0_EXTIO_INT3_MASK 0x0200000000000000UL |
355 | #define UV2H_EVENT_OCCURRED0_EXTIO_INT0_MASK 0x0040000000000000UL | 382 | #define UVXH_EVENT_OCCURRED0_PROFILE_INT_MASK 0x0400000000000000UL |
356 | #define UV2H_EVENT_OCCURRED0_EXTIO_INT1_MASK 0x0080000000000000UL | ||
357 | #define UV2H_EVENT_OCCURRED0_EXTIO_INT2_MASK 0x0100000000000000UL | ||
358 | #define UV2H_EVENT_OCCURRED0_EXTIO_INT3_MASK 0x0200000000000000UL | ||
359 | #define UV2H_EVENT_OCCURRED0_PROFILE_INT_MASK 0x0400000000000000UL | ||
360 | 383 | ||
361 | union uvh_event_occurred0_u { | 384 | union uvh_event_occurred0_u { |
362 | unsigned long v; | 385 | unsigned long v; |
363 | struct uv1h_event_occurred0_s { | 386 | struct uvh_event_occurred0_s { |
364 | unsigned long lb_hcerr:1; /* RW, W1C */ | 387 | unsigned long lb_hcerr:1; /* RW, W1C */ |
365 | unsigned long gr0_hcerr:1; /* RW, W1C */ | 388 | unsigned long rsvd_1_10:10; |
366 | unsigned long gr1_hcerr:1; /* RW, W1C */ | ||
367 | unsigned long lh_hcerr:1; /* RW, W1C */ | ||
368 | unsigned long rh_hcerr:1; /* RW, W1C */ | ||
369 | unsigned long xn_hcerr:1; /* RW, W1C */ | ||
370 | unsigned long si_hcerr:1; /* RW, W1C */ | ||
371 | unsigned long lb_aoerr0:1; /* RW, W1C */ | ||
372 | unsigned long gr0_aoerr0:1; /* RW, W1C */ | ||
373 | unsigned long gr1_aoerr0:1; /* RW, W1C */ | ||
374 | unsigned long lh_aoerr0:1; /* RW, W1C */ | ||
375 | unsigned long rh_aoerr0:1; /* RW, W1C */ | 389 | unsigned long rh_aoerr0:1; /* RW, W1C */ |
376 | unsigned long xn_aoerr0:1; /* RW, W1C */ | 390 | unsigned long rsvd_12_63:52; |
377 | unsigned long si_aoerr0:1; /* RW, W1C */ | 391 | } s; |
378 | unsigned long lb_aoerr1:1; /* RW, W1C */ | 392 | struct uvxh_event_occurred0_s { |
379 | unsigned long gr0_aoerr1:1; /* RW, W1C */ | ||
380 | unsigned long gr1_aoerr1:1; /* RW, W1C */ | ||
381 | unsigned long lh_aoerr1:1; /* RW, W1C */ | ||
382 | unsigned long rh_aoerr1:1; /* RW, W1C */ | ||
383 | unsigned long xn_aoerr1:1; /* RW, W1C */ | ||
384 | unsigned long si_aoerr1:1; /* RW, W1C */ | ||
385 | unsigned long rh_vpi_int:1; /* RW, W1C */ | ||
386 | unsigned long system_shutdown_int:1; /* RW, W1C */ | ||
387 | unsigned long lb_irq_int_0:1; /* RW, W1C */ | ||
388 | unsigned long lb_irq_int_1:1; /* RW, W1C */ | ||
389 | unsigned long lb_irq_int_2:1; /* RW, W1C */ | ||
390 | unsigned long lb_irq_int_3:1; /* RW, W1C */ | ||
391 | unsigned long lb_irq_int_4:1; /* RW, W1C */ | ||
392 | unsigned long lb_irq_int_5:1; /* RW, W1C */ | ||
393 | unsigned long lb_irq_int_6:1; /* RW, W1C */ | ||
394 | unsigned long lb_irq_int_7:1; /* RW, W1C */ | ||
395 | unsigned long lb_irq_int_8:1; /* RW, W1C */ | ||
396 | unsigned long lb_irq_int_9:1; /* RW, W1C */ | ||
397 | unsigned long lb_irq_int_10:1; /* RW, W1C */ | ||
398 | unsigned long lb_irq_int_11:1; /* RW, W1C */ | ||
399 | unsigned long lb_irq_int_12:1; /* RW, W1C */ | ||
400 | unsigned long lb_irq_int_13:1; /* RW, W1C */ | ||
401 | unsigned long lb_irq_int_14:1; /* RW, W1C */ | ||
402 | unsigned long lb_irq_int_15:1; /* RW, W1C */ | ||
403 | unsigned long l1_nmi_int:1; /* RW, W1C */ | ||
404 | unsigned long stop_clock:1; /* RW, W1C */ | ||
405 | unsigned long asic_to_l1:1; /* RW, W1C */ | ||
406 | unsigned long l1_to_asic:1; /* RW, W1C */ | ||
407 | unsigned long ltc_int:1; /* RW, W1C */ | ||
408 | unsigned long la_seq_trigger:1; /* RW, W1C */ | ||
409 | unsigned long ipi_int:1; /* RW, W1C */ | ||
410 | unsigned long extio_int0:1; /* RW, W1C */ | ||
411 | unsigned long extio_int1:1; /* RW, W1C */ | ||
412 | unsigned long extio_int2:1; /* RW, W1C */ | ||
413 | unsigned long extio_int3:1; /* RW, W1C */ | ||
414 | unsigned long profile_int:1; /* RW, W1C */ | ||
415 | unsigned long rtc0:1; /* RW, W1C */ | ||
416 | unsigned long rtc1:1; /* RW, W1C */ | ||
417 | unsigned long rtc2:1; /* RW, W1C */ | ||
418 | unsigned long rtc3:1; /* RW, W1C */ | ||
419 | unsigned long bau_data:1; /* RW, W1C */ | ||
420 | unsigned long power_management_req:1; /* RW, W1C */ | ||
421 | unsigned long rsvd_57_63:7; | ||
422 | } s1; | ||
423 | struct uv2h_event_occurred0_s { | ||
424 | unsigned long lb_hcerr:1; /* RW */ | 393 | unsigned long lb_hcerr:1; /* RW */ |
425 | unsigned long qp_hcerr:1; /* RW */ | 394 | unsigned long qp_hcerr:1; /* RW */ |
426 | unsigned long rh_hcerr:1; /* RW */ | 395 | unsigned long rh_hcerr:1; /* RW */ |
@@ -481,19 +450,20 @@ union uvh_event_occurred0_u { | |||
481 | unsigned long extio_int3:1; /* RW */ | 450 | unsigned long extio_int3:1; /* RW */ |
482 | unsigned long profile_int:1; /* RW */ | 451 | unsigned long profile_int:1; /* RW */ |
483 | unsigned long rsvd_59_63:5; | 452 | unsigned long rsvd_59_63:5; |
484 | } s2; | 453 | } sx; |
485 | }; | 454 | }; |
486 | 455 | ||
487 | /* ========================================================================= */ | 456 | /* ========================================================================= */ |
488 | /* UVH_EVENT_OCCURRED0_ALIAS */ | 457 | /* UVH_EVENT_OCCURRED0_ALIAS */ |
489 | /* ========================================================================= */ | 458 | /* ========================================================================= */ |
490 | #define UVH_EVENT_OCCURRED0_ALIAS 0x0000000000070008UL | 459 | #define UVH_EVENT_OCCURRED0_ALIAS 0x70008UL |
491 | #define UVH_EVENT_OCCURRED0_ALIAS_32 0x5f0 | 460 | #define UVH_EVENT_OCCURRED0_ALIAS_32 0x5f0 |
461 | |||
492 | 462 | ||
493 | /* ========================================================================= */ | 463 | /* ========================================================================= */ |
494 | /* UVH_GR0_TLB_INT0_CONFIG */ | 464 | /* UVH_GR0_TLB_INT0_CONFIG */ |
495 | /* ========================================================================= */ | 465 | /* ========================================================================= */ |
496 | #define UVH_GR0_TLB_INT0_CONFIG 0x61b00UL | 466 | #define UVH_GR0_TLB_INT0_CONFIG 0x61b00UL |
497 | 467 | ||
498 | #define UVH_GR0_TLB_INT0_CONFIG_VECTOR_SHFT 0 | 468 | #define UVH_GR0_TLB_INT0_CONFIG_VECTOR_SHFT 0 |
499 | #define UVH_GR0_TLB_INT0_CONFIG_DM_SHFT 8 | 469 | #define UVH_GR0_TLB_INT0_CONFIG_DM_SHFT 8 |
@@ -531,7 +501,7 @@ union uvh_gr0_tlb_int0_config_u { | |||
531 | /* ========================================================================= */ | 501 | /* ========================================================================= */ |
532 | /* UVH_GR0_TLB_INT1_CONFIG */ | 502 | /* UVH_GR0_TLB_INT1_CONFIG */ |
533 | /* ========================================================================= */ | 503 | /* ========================================================================= */ |
534 | #define UVH_GR0_TLB_INT1_CONFIG 0x61b40UL | 504 | #define UVH_GR0_TLB_INT1_CONFIG 0x61b40UL |
535 | 505 | ||
536 | #define UVH_GR0_TLB_INT1_CONFIG_VECTOR_SHFT 0 | 506 | #define UVH_GR0_TLB_INT1_CONFIG_VECTOR_SHFT 0 |
537 | #define UVH_GR0_TLB_INT1_CONFIG_DM_SHFT 8 | 507 | #define UVH_GR0_TLB_INT1_CONFIG_DM_SHFT 8 |
@@ -571,9 +541,11 @@ union uvh_gr0_tlb_int1_config_u { | |||
571 | /* ========================================================================= */ | 541 | /* ========================================================================= */ |
572 | #define UV1H_GR0_TLB_MMR_CONTROL 0x401080UL | 542 | #define UV1H_GR0_TLB_MMR_CONTROL 0x401080UL |
573 | #define UV2H_GR0_TLB_MMR_CONTROL 0xc01080UL | 543 | #define UV2H_GR0_TLB_MMR_CONTROL 0xc01080UL |
574 | #define UVH_GR0_TLB_MMR_CONTROL (is_uv1_hub() ? \ | 544 | #define UV3H_GR0_TLB_MMR_CONTROL 0xc01080UL |
575 | UV1H_GR0_TLB_MMR_CONTROL : \ | 545 | #define UVH_GR0_TLB_MMR_CONTROL \ |
576 | UV2H_GR0_TLB_MMR_CONTROL) | 546 | (is_uv1_hub() ? UV1H_GR0_TLB_MMR_CONTROL : \ |
547 | (is_uv2_hub() ? UV2H_GR0_TLB_MMR_CONTROL : \ | ||
548 | UV3H_GR0_TLB_MMR_CONTROL)) | ||
577 | 549 | ||
578 | #define UVH_GR0_TLB_MMR_CONTROL_INDEX_SHFT 0 | 550 | #define UVH_GR0_TLB_MMR_CONTROL_INDEX_SHFT 0 |
579 | #define UVH_GR0_TLB_MMR_CONTROL_MEM_SEL_SHFT 12 | 551 | #define UVH_GR0_TLB_MMR_CONTROL_MEM_SEL_SHFT 12 |
@@ -611,6 +583,21 @@ union uvh_gr0_tlb_int1_config_u { | |||
611 | #define UV1H_GR0_TLB_MMR_CONTROL_MMR_INJ_TLBRREG_MASK 0x0100000000000000UL | 583 | #define UV1H_GR0_TLB_MMR_CONTROL_MMR_INJ_TLBRREG_MASK 0x0100000000000000UL |
612 | #define UV1H_GR0_TLB_MMR_CONTROL_MMR_INJ_TLBLRUV_MASK 0x1000000000000000UL | 584 | #define UV1H_GR0_TLB_MMR_CONTROL_MMR_INJ_TLBLRUV_MASK 0x1000000000000000UL |
613 | 585 | ||
586 | #define UVXH_GR0_TLB_MMR_CONTROL_INDEX_SHFT 0 | ||
587 | #define UVXH_GR0_TLB_MMR_CONTROL_MEM_SEL_SHFT 12 | ||
588 | #define UVXH_GR0_TLB_MMR_CONTROL_AUTO_VALID_EN_SHFT 16 | ||
589 | #define UVXH_GR0_TLB_MMR_CONTROL_MMR_HASH_INDEX_EN_SHFT 20 | ||
590 | #define UVXH_GR0_TLB_MMR_CONTROL_MMR_WRITE_SHFT 30 | ||
591 | #define UVXH_GR0_TLB_MMR_CONTROL_MMR_READ_SHFT 31 | ||
592 | #define UVXH_GR0_TLB_MMR_CONTROL_MMR_OP_DONE_SHFT 32 | ||
593 | #define UVXH_GR0_TLB_MMR_CONTROL_INDEX_MASK 0x0000000000000fffUL | ||
594 | #define UVXH_GR0_TLB_MMR_CONTROL_MEM_SEL_MASK 0x0000000000003000UL | ||
595 | #define UVXH_GR0_TLB_MMR_CONTROL_AUTO_VALID_EN_MASK 0x0000000000010000UL | ||
596 | #define UVXH_GR0_TLB_MMR_CONTROL_MMR_HASH_INDEX_EN_MASK 0x0000000000100000UL | ||
597 | #define UVXH_GR0_TLB_MMR_CONTROL_MMR_WRITE_MASK 0x0000000040000000UL | ||
598 | #define UVXH_GR0_TLB_MMR_CONTROL_MMR_READ_MASK 0x0000000080000000UL | ||
599 | #define UVXH_GR0_TLB_MMR_CONTROL_MMR_OP_DONE_MASK 0x0000000100000000UL | ||
600 | |||
614 | #define UV2H_GR0_TLB_MMR_CONTROL_INDEX_SHFT 0 | 601 | #define UV2H_GR0_TLB_MMR_CONTROL_INDEX_SHFT 0 |
615 | #define UV2H_GR0_TLB_MMR_CONTROL_MEM_SEL_SHFT 12 | 602 | #define UV2H_GR0_TLB_MMR_CONTROL_MEM_SEL_SHFT 12 |
616 | #define UV2H_GR0_TLB_MMR_CONTROL_AUTO_VALID_EN_SHFT 16 | 603 | #define UV2H_GR0_TLB_MMR_CONTROL_AUTO_VALID_EN_SHFT 16 |
@@ -630,6 +617,23 @@ union uvh_gr0_tlb_int1_config_u { | |||
630 | #define UV2H_GR0_TLB_MMR_CONTROL_MMR_INJ_CON_MASK 0x0001000000000000UL | 617 | #define UV2H_GR0_TLB_MMR_CONTROL_MMR_INJ_CON_MASK 0x0001000000000000UL |
631 | #define UV2H_GR0_TLB_MMR_CONTROL_MMR_INJ_TLBRAM_MASK 0x0010000000000000UL | 618 | #define UV2H_GR0_TLB_MMR_CONTROL_MMR_INJ_TLBRAM_MASK 0x0010000000000000UL |
632 | 619 | ||
620 | #define UV3H_GR0_TLB_MMR_CONTROL_INDEX_SHFT 0 | ||
621 | #define UV3H_GR0_TLB_MMR_CONTROL_MEM_SEL_SHFT 12 | ||
622 | #define UV3H_GR0_TLB_MMR_CONTROL_AUTO_VALID_EN_SHFT 16 | ||
623 | #define UV3H_GR0_TLB_MMR_CONTROL_MMR_HASH_INDEX_EN_SHFT 20 | ||
624 | #define UV3H_GR0_TLB_MMR_CONTROL_ECC_SEL_SHFT 21 | ||
625 | #define UV3H_GR0_TLB_MMR_CONTROL_MMR_WRITE_SHFT 30 | ||
626 | #define UV3H_GR0_TLB_MMR_CONTROL_MMR_READ_SHFT 31 | ||
627 | #define UV3H_GR0_TLB_MMR_CONTROL_MMR_OP_DONE_SHFT 32 | ||
628 | #define UV3H_GR0_TLB_MMR_CONTROL_INDEX_MASK 0x0000000000000fffUL | ||
629 | #define UV3H_GR0_TLB_MMR_CONTROL_MEM_SEL_MASK 0x0000000000003000UL | ||
630 | #define UV3H_GR0_TLB_MMR_CONTROL_AUTO_VALID_EN_MASK 0x0000000000010000UL | ||
631 | #define UV3H_GR0_TLB_MMR_CONTROL_MMR_HASH_INDEX_EN_MASK 0x0000000000100000UL | ||
632 | #define UV3H_GR0_TLB_MMR_CONTROL_ECC_SEL_MASK 0x0000000000200000UL | ||
633 | #define UV3H_GR0_TLB_MMR_CONTROL_MMR_WRITE_MASK 0x0000000040000000UL | ||
634 | #define UV3H_GR0_TLB_MMR_CONTROL_MMR_READ_MASK 0x0000000080000000UL | ||
635 | #define UV3H_GR0_TLB_MMR_CONTROL_MMR_OP_DONE_MASK 0x0000000100000000UL | ||
636 | |||
633 | union uvh_gr0_tlb_mmr_control_u { | 637 | union uvh_gr0_tlb_mmr_control_u { |
634 | unsigned long v; | 638 | unsigned long v; |
635 | struct uvh_gr0_tlb_mmr_control_s { | 639 | struct uvh_gr0_tlb_mmr_control_s { |
@@ -642,7 +646,9 @@ union uvh_gr0_tlb_mmr_control_u { | |||
642 | unsigned long rsvd_21_29:9; | 646 | unsigned long rsvd_21_29:9; |
643 | unsigned long mmr_write:1; /* WP */ | 647 | unsigned long mmr_write:1; /* WP */ |
644 | unsigned long mmr_read:1; /* WP */ | 648 | unsigned long mmr_read:1; /* WP */ |
645 | unsigned long rsvd_32_63:32; | 649 | unsigned long rsvd_32_48:17; |
650 | unsigned long rsvd_49_51:3; | ||
651 | unsigned long rsvd_52_63:12; | ||
646 | } s; | 652 | } s; |
647 | struct uv1h_gr0_tlb_mmr_control_s { | 653 | struct uv1h_gr0_tlb_mmr_control_s { |
648 | unsigned long index:12; /* RW */ | 654 | unsigned long index:12; /* RW */ |
@@ -666,6 +672,23 @@ union uvh_gr0_tlb_mmr_control_u { | |||
666 | unsigned long mmr_inj_tlblruv:1; /* RW */ | 672 | unsigned long mmr_inj_tlblruv:1; /* RW */ |
667 | unsigned long rsvd_61_63:3; | 673 | unsigned long rsvd_61_63:3; |
668 | } s1; | 674 | } s1; |
675 | struct uvxh_gr0_tlb_mmr_control_s { | ||
676 | unsigned long index:12; /* RW */ | ||
677 | unsigned long mem_sel:2; /* RW */ | ||
678 | unsigned long rsvd_14_15:2; | ||
679 | unsigned long auto_valid_en:1; /* RW */ | ||
680 | unsigned long rsvd_17_19:3; | ||
681 | unsigned long mmr_hash_index_en:1; /* RW */ | ||
682 | unsigned long rsvd_21_29:9; | ||
683 | unsigned long mmr_write:1; /* WP */ | ||
684 | unsigned long mmr_read:1; /* WP */ | ||
685 | unsigned long mmr_op_done:1; /* RW */ | ||
686 | unsigned long rsvd_33_47:15; | ||
687 | unsigned long rsvd_48:1; | ||
688 | unsigned long rsvd_49_51:3; | ||
689 | unsigned long rsvd_52:1; | ||
690 | unsigned long rsvd_53_63:11; | ||
691 | } sx; | ||
669 | struct uv2h_gr0_tlb_mmr_control_s { | 692 | struct uv2h_gr0_tlb_mmr_control_s { |
670 | unsigned long index:12; /* RW */ | 693 | unsigned long index:12; /* RW */ |
671 | unsigned long mem_sel:2; /* RW */ | 694 | unsigned long mem_sel:2; /* RW */ |
@@ -683,6 +706,24 @@ union uvh_gr0_tlb_mmr_control_u { | |||
683 | unsigned long mmr_inj_tlbram:1; /* RW */ | 706 | unsigned long mmr_inj_tlbram:1; /* RW */ |
684 | unsigned long rsvd_53_63:11; | 707 | unsigned long rsvd_53_63:11; |
685 | } s2; | 708 | } s2; |
709 | struct uv3h_gr0_tlb_mmr_control_s { | ||
710 | unsigned long index:12; /* RW */ | ||
711 | unsigned long mem_sel:2; /* RW */ | ||
712 | unsigned long rsvd_14_15:2; | ||
713 | unsigned long auto_valid_en:1; /* RW */ | ||
714 | unsigned long rsvd_17_19:3; | ||
715 | unsigned long mmr_hash_index_en:1; /* RW */ | ||
716 | unsigned long ecc_sel:1; /* RW */ | ||
717 | unsigned long rsvd_22_29:8; | ||
718 | unsigned long mmr_write:1; /* WP */ | ||
719 | unsigned long mmr_read:1; /* WP */ | ||
720 | unsigned long mmr_op_done:1; /* RW */ | ||
721 | unsigned long rsvd_33_47:15; | ||
722 | unsigned long undef_48:1; /* Undefined */ | ||
723 | unsigned long rsvd_49_51:3; | ||
724 | unsigned long undef_52:1; /* Undefined */ | ||
725 | unsigned long rsvd_53_63:11; | ||
726 | } s3; | ||
686 | }; | 727 | }; |
687 | 728 | ||
688 | /* ========================================================================= */ | 729 | /* ========================================================================= */ |
@@ -690,9 +731,11 @@ union uvh_gr0_tlb_mmr_control_u { | |||
690 | /* ========================================================================= */ | 731 | /* ========================================================================= */ |
691 | #define UV1H_GR0_TLB_MMR_READ_DATA_HI 0x4010a0UL | 732 | #define UV1H_GR0_TLB_MMR_READ_DATA_HI 0x4010a0UL |
692 | #define UV2H_GR0_TLB_MMR_READ_DATA_HI 0xc010a0UL | 733 | #define UV2H_GR0_TLB_MMR_READ_DATA_HI 0xc010a0UL |
693 | #define UVH_GR0_TLB_MMR_READ_DATA_HI (is_uv1_hub() ? \ | 734 | #define UV3H_GR0_TLB_MMR_READ_DATA_HI 0xc010a0UL |
694 | UV1H_GR0_TLB_MMR_READ_DATA_HI : \ | 735 | #define UVH_GR0_TLB_MMR_READ_DATA_HI \ |
695 | UV2H_GR0_TLB_MMR_READ_DATA_HI) | 736 | (is_uv1_hub() ? UV1H_GR0_TLB_MMR_READ_DATA_HI : \ |
737 | (is_uv2_hub() ? UV2H_GR0_TLB_MMR_READ_DATA_HI : \ | ||
738 | UV3H_GR0_TLB_MMR_READ_DATA_HI)) | ||
696 | 739 | ||
697 | #define UVH_GR0_TLB_MMR_READ_DATA_HI_PFN_SHFT 0 | 740 | #define UVH_GR0_TLB_MMR_READ_DATA_HI_PFN_SHFT 0 |
698 | #define UVH_GR0_TLB_MMR_READ_DATA_HI_GAA_SHFT 41 | 741 | #define UVH_GR0_TLB_MMR_READ_DATA_HI_GAA_SHFT 41 |
@@ -703,6 +746,46 @@ union uvh_gr0_tlb_mmr_control_u { | |||
703 | #define UVH_GR0_TLB_MMR_READ_DATA_HI_DIRTY_MASK 0x0000080000000000UL | 746 | #define UVH_GR0_TLB_MMR_READ_DATA_HI_DIRTY_MASK 0x0000080000000000UL |
704 | #define UVH_GR0_TLB_MMR_READ_DATA_HI_LARGER_MASK 0x0000100000000000UL | 747 | #define UVH_GR0_TLB_MMR_READ_DATA_HI_LARGER_MASK 0x0000100000000000UL |
705 | 748 | ||
749 | #define UV1H_GR0_TLB_MMR_READ_DATA_HI_PFN_SHFT 0 | ||
750 | #define UV1H_GR0_TLB_MMR_READ_DATA_HI_GAA_SHFT 41 | ||
751 | #define UV1H_GR0_TLB_MMR_READ_DATA_HI_DIRTY_SHFT 43 | ||
752 | #define UV1H_GR0_TLB_MMR_READ_DATA_HI_LARGER_SHFT 44 | ||
753 | #define UV1H_GR0_TLB_MMR_READ_DATA_HI_PFN_MASK 0x000001ffffffffffUL | ||
754 | #define UV1H_GR0_TLB_MMR_READ_DATA_HI_GAA_MASK 0x0000060000000000UL | ||
755 | #define UV1H_GR0_TLB_MMR_READ_DATA_HI_DIRTY_MASK 0x0000080000000000UL | ||
756 | #define UV1H_GR0_TLB_MMR_READ_DATA_HI_LARGER_MASK 0x0000100000000000UL | ||
757 | |||
758 | #define UVXH_GR0_TLB_MMR_READ_DATA_HI_PFN_SHFT 0 | ||
759 | #define UVXH_GR0_TLB_MMR_READ_DATA_HI_GAA_SHFT 41 | ||
760 | #define UVXH_GR0_TLB_MMR_READ_DATA_HI_DIRTY_SHFT 43 | ||
761 | #define UVXH_GR0_TLB_MMR_READ_DATA_HI_LARGER_SHFT 44 | ||
762 | #define UVXH_GR0_TLB_MMR_READ_DATA_HI_PFN_MASK 0x000001ffffffffffUL | ||
763 | #define UVXH_GR0_TLB_MMR_READ_DATA_HI_GAA_MASK 0x0000060000000000UL | ||
764 | #define UVXH_GR0_TLB_MMR_READ_DATA_HI_DIRTY_MASK 0x0000080000000000UL | ||
765 | #define UVXH_GR0_TLB_MMR_READ_DATA_HI_LARGER_MASK 0x0000100000000000UL | ||
766 | |||
767 | #define UV2H_GR0_TLB_MMR_READ_DATA_HI_PFN_SHFT 0 | ||
768 | #define UV2H_GR0_TLB_MMR_READ_DATA_HI_GAA_SHFT 41 | ||
769 | #define UV2H_GR0_TLB_MMR_READ_DATA_HI_DIRTY_SHFT 43 | ||
770 | #define UV2H_GR0_TLB_MMR_READ_DATA_HI_LARGER_SHFT 44 | ||
771 | #define UV2H_GR0_TLB_MMR_READ_DATA_HI_PFN_MASK 0x000001ffffffffffUL | ||
772 | #define UV2H_GR0_TLB_MMR_READ_DATA_HI_GAA_MASK 0x0000060000000000UL | ||
773 | #define UV2H_GR0_TLB_MMR_READ_DATA_HI_DIRTY_MASK 0x0000080000000000UL | ||
774 | #define UV2H_GR0_TLB_MMR_READ_DATA_HI_LARGER_MASK 0x0000100000000000UL | ||
775 | |||
776 | #define UV3H_GR0_TLB_MMR_READ_DATA_HI_PFN_SHFT 0 | ||
777 | #define UV3H_GR0_TLB_MMR_READ_DATA_HI_GAA_SHFT 41 | ||
778 | #define UV3H_GR0_TLB_MMR_READ_DATA_HI_DIRTY_SHFT 43 | ||
779 | #define UV3H_GR0_TLB_MMR_READ_DATA_HI_LARGER_SHFT 44 | ||
780 | #define UV3H_GR0_TLB_MMR_READ_DATA_HI_AA_EXT_SHFT 45 | ||
781 | #define UV3H_GR0_TLB_MMR_READ_DATA_HI_WAY_ECC_SHFT 55 | ||
782 | #define UV3H_GR0_TLB_MMR_READ_DATA_HI_PFN_MASK 0x000001ffffffffffUL | ||
783 | #define UV3H_GR0_TLB_MMR_READ_DATA_HI_GAA_MASK 0x0000060000000000UL | ||
784 | #define UV3H_GR0_TLB_MMR_READ_DATA_HI_DIRTY_MASK 0x0000080000000000UL | ||
785 | #define UV3H_GR0_TLB_MMR_READ_DATA_HI_LARGER_MASK 0x0000100000000000UL | ||
786 | #define UV3H_GR0_TLB_MMR_READ_DATA_HI_AA_EXT_MASK 0x0000200000000000UL | ||
787 | #define UV3H_GR0_TLB_MMR_READ_DATA_HI_WAY_ECC_MASK 0xff80000000000000UL | ||
788 | |||
706 | union uvh_gr0_tlb_mmr_read_data_hi_u { | 789 | union uvh_gr0_tlb_mmr_read_data_hi_u { |
707 | unsigned long v; | 790 | unsigned long v; |
708 | struct uvh_gr0_tlb_mmr_read_data_hi_s { | 791 | struct uvh_gr0_tlb_mmr_read_data_hi_s { |
@@ -712,6 +795,36 @@ union uvh_gr0_tlb_mmr_read_data_hi_u { | |||
712 | unsigned long larger:1; /* RO */ | 795 | unsigned long larger:1; /* RO */ |
713 | unsigned long rsvd_45_63:19; | 796 | unsigned long rsvd_45_63:19; |
714 | } s; | 797 | } s; |
798 | struct uv1h_gr0_tlb_mmr_read_data_hi_s { | ||
799 | unsigned long pfn:41; /* RO */ | ||
800 | unsigned long gaa:2; /* RO */ | ||
801 | unsigned long dirty:1; /* RO */ | ||
802 | unsigned long larger:1; /* RO */ | ||
803 | unsigned long rsvd_45_63:19; | ||
804 | } s1; | ||
805 | struct uvxh_gr0_tlb_mmr_read_data_hi_s { | ||
806 | unsigned long pfn:41; /* RO */ | ||
807 | unsigned long gaa:2; /* RO */ | ||
808 | unsigned long dirty:1; /* RO */ | ||
809 | unsigned long larger:1; /* RO */ | ||
810 | unsigned long rsvd_45_63:19; | ||
811 | } sx; | ||
812 | struct uv2h_gr0_tlb_mmr_read_data_hi_s { | ||
813 | unsigned long pfn:41; /* RO */ | ||
814 | unsigned long gaa:2; /* RO */ | ||
815 | unsigned long dirty:1; /* RO */ | ||
816 | unsigned long larger:1; /* RO */ | ||
817 | unsigned long rsvd_45_63:19; | ||
818 | } s2; | ||
819 | struct uv3h_gr0_tlb_mmr_read_data_hi_s { | ||
820 | unsigned long pfn:41; /* RO */ | ||
821 | unsigned long gaa:2; /* RO */ | ||
822 | unsigned long dirty:1; /* RO */ | ||
823 | unsigned long larger:1; /* RO */ | ||
824 | unsigned long aa_ext:1; /* RO */ | ||
825 | unsigned long undef_46_54:9; /* Undefined */ | ||
826 | unsigned long way_ecc:9; /* RO */ | ||
827 | } s3; | ||
715 | }; | 828 | }; |
716 | 829 | ||
717 | /* ========================================================================= */ | 830 | /* ========================================================================= */ |
@@ -719,9 +832,11 @@ union uvh_gr0_tlb_mmr_read_data_hi_u { | |||
719 | /* ========================================================================= */ | 832 | /* ========================================================================= */ |
720 | #define UV1H_GR0_TLB_MMR_READ_DATA_LO 0x4010a8UL | 833 | #define UV1H_GR0_TLB_MMR_READ_DATA_LO 0x4010a8UL |
721 | #define UV2H_GR0_TLB_MMR_READ_DATA_LO 0xc010a8UL | 834 | #define UV2H_GR0_TLB_MMR_READ_DATA_LO 0xc010a8UL |
722 | #define UVH_GR0_TLB_MMR_READ_DATA_LO (is_uv1_hub() ? \ | 835 | #define UV3H_GR0_TLB_MMR_READ_DATA_LO 0xc010a8UL |
723 | UV1H_GR0_TLB_MMR_READ_DATA_LO : \ | 836 | #define UVH_GR0_TLB_MMR_READ_DATA_LO \ |
724 | UV2H_GR0_TLB_MMR_READ_DATA_LO) | 837 | (is_uv1_hub() ? UV1H_GR0_TLB_MMR_READ_DATA_LO : \ |
838 | (is_uv2_hub() ? UV2H_GR0_TLB_MMR_READ_DATA_LO : \ | ||
839 | UV3H_GR0_TLB_MMR_READ_DATA_LO)) | ||
725 | 840 | ||
726 | #define UVH_GR0_TLB_MMR_READ_DATA_LO_VPN_SHFT 0 | 841 | #define UVH_GR0_TLB_MMR_READ_DATA_LO_VPN_SHFT 0 |
727 | #define UVH_GR0_TLB_MMR_READ_DATA_LO_ASID_SHFT 39 | 842 | #define UVH_GR0_TLB_MMR_READ_DATA_LO_ASID_SHFT 39 |
@@ -730,6 +845,34 @@ union uvh_gr0_tlb_mmr_read_data_hi_u { | |||
730 | #define UVH_GR0_TLB_MMR_READ_DATA_LO_ASID_MASK 0x7fffff8000000000UL | 845 | #define UVH_GR0_TLB_MMR_READ_DATA_LO_ASID_MASK 0x7fffff8000000000UL |
731 | #define UVH_GR0_TLB_MMR_READ_DATA_LO_VALID_MASK 0x8000000000000000UL | 846 | #define UVH_GR0_TLB_MMR_READ_DATA_LO_VALID_MASK 0x8000000000000000UL |
732 | 847 | ||
848 | #define UV1H_GR0_TLB_MMR_READ_DATA_LO_VPN_SHFT 0 | ||
849 | #define UV1H_GR0_TLB_MMR_READ_DATA_LO_ASID_SHFT 39 | ||
850 | #define UV1H_GR0_TLB_MMR_READ_DATA_LO_VALID_SHFT 63 | ||
851 | #define UV1H_GR0_TLB_MMR_READ_DATA_LO_VPN_MASK 0x0000007fffffffffUL | ||
852 | #define UV1H_GR0_TLB_MMR_READ_DATA_LO_ASID_MASK 0x7fffff8000000000UL | ||
853 | #define UV1H_GR0_TLB_MMR_READ_DATA_LO_VALID_MASK 0x8000000000000000UL | ||
854 | |||
855 | #define UVXH_GR0_TLB_MMR_READ_DATA_LO_VPN_SHFT 0 | ||
856 | #define UVXH_GR0_TLB_MMR_READ_DATA_LO_ASID_SHFT 39 | ||
857 | #define UVXH_GR0_TLB_MMR_READ_DATA_LO_VALID_SHFT 63 | ||
858 | #define UVXH_GR0_TLB_MMR_READ_DATA_LO_VPN_MASK 0x0000007fffffffffUL | ||
859 | #define UVXH_GR0_TLB_MMR_READ_DATA_LO_ASID_MASK 0x7fffff8000000000UL | ||
860 | #define UVXH_GR0_TLB_MMR_READ_DATA_LO_VALID_MASK 0x8000000000000000UL | ||
861 | |||
862 | #define UV2H_GR0_TLB_MMR_READ_DATA_LO_VPN_SHFT 0 | ||
863 | #define UV2H_GR0_TLB_MMR_READ_DATA_LO_ASID_SHFT 39 | ||
864 | #define UV2H_GR0_TLB_MMR_READ_DATA_LO_VALID_SHFT 63 | ||
865 | #define UV2H_GR0_TLB_MMR_READ_DATA_LO_VPN_MASK 0x0000007fffffffffUL | ||
866 | #define UV2H_GR0_TLB_MMR_READ_DATA_LO_ASID_MASK 0x7fffff8000000000UL | ||
867 | #define UV2H_GR0_TLB_MMR_READ_DATA_LO_VALID_MASK 0x8000000000000000UL | ||
868 | |||
869 | #define UV3H_GR0_TLB_MMR_READ_DATA_LO_VPN_SHFT 0 | ||
870 | #define UV3H_GR0_TLB_MMR_READ_DATA_LO_ASID_SHFT 39 | ||
871 | #define UV3H_GR0_TLB_MMR_READ_DATA_LO_VALID_SHFT 63 | ||
872 | #define UV3H_GR0_TLB_MMR_READ_DATA_LO_VPN_MASK 0x0000007fffffffffUL | ||
873 | #define UV3H_GR0_TLB_MMR_READ_DATA_LO_ASID_MASK 0x7fffff8000000000UL | ||
874 | #define UV3H_GR0_TLB_MMR_READ_DATA_LO_VALID_MASK 0x8000000000000000UL | ||
875 | |||
733 | union uvh_gr0_tlb_mmr_read_data_lo_u { | 876 | union uvh_gr0_tlb_mmr_read_data_lo_u { |
734 | unsigned long v; | 877 | unsigned long v; |
735 | struct uvh_gr0_tlb_mmr_read_data_lo_s { | 878 | struct uvh_gr0_tlb_mmr_read_data_lo_s { |
@@ -737,12 +880,32 @@ union uvh_gr0_tlb_mmr_read_data_lo_u { | |||
737 | unsigned long asid:24; /* RO */ | 880 | unsigned long asid:24; /* RO */ |
738 | unsigned long valid:1; /* RO */ | 881 | unsigned long valid:1; /* RO */ |
739 | } s; | 882 | } s; |
883 | struct uv1h_gr0_tlb_mmr_read_data_lo_s { | ||
884 | unsigned long vpn:39; /* RO */ | ||
885 | unsigned long asid:24; /* RO */ | ||
886 | unsigned long valid:1; /* RO */ | ||
887 | } s1; | ||
888 | struct uvxh_gr0_tlb_mmr_read_data_lo_s { | ||
889 | unsigned long vpn:39; /* RO */ | ||
890 | unsigned long asid:24; /* RO */ | ||
891 | unsigned long valid:1; /* RO */ | ||
892 | } sx; | ||
893 | struct uv2h_gr0_tlb_mmr_read_data_lo_s { | ||
894 | unsigned long vpn:39; /* RO */ | ||
895 | unsigned long asid:24; /* RO */ | ||
896 | unsigned long valid:1; /* RO */ | ||
897 | } s2; | ||
898 | struct uv3h_gr0_tlb_mmr_read_data_lo_s { | ||
899 | unsigned long vpn:39; /* RO */ | ||
900 | unsigned long asid:24; /* RO */ | ||
901 | unsigned long valid:1; /* RO */ | ||
902 | } s3; | ||
740 | }; | 903 | }; |
741 | 904 | ||
742 | /* ========================================================================= */ | 905 | /* ========================================================================= */ |
743 | /* UVH_GR1_TLB_INT0_CONFIG */ | 906 | /* UVH_GR1_TLB_INT0_CONFIG */ |
744 | /* ========================================================================= */ | 907 | /* ========================================================================= */ |
745 | #define UVH_GR1_TLB_INT0_CONFIG 0x61f00UL | 908 | #define UVH_GR1_TLB_INT0_CONFIG 0x61f00UL |
746 | 909 | ||
747 | #define UVH_GR1_TLB_INT0_CONFIG_VECTOR_SHFT 0 | 910 | #define UVH_GR1_TLB_INT0_CONFIG_VECTOR_SHFT 0 |
748 | #define UVH_GR1_TLB_INT0_CONFIG_DM_SHFT 8 | 911 | #define UVH_GR1_TLB_INT0_CONFIG_DM_SHFT 8 |
@@ -780,7 +943,7 @@ union uvh_gr1_tlb_int0_config_u { | |||
780 | /* ========================================================================= */ | 943 | /* ========================================================================= */ |
781 | /* UVH_GR1_TLB_INT1_CONFIG */ | 944 | /* UVH_GR1_TLB_INT1_CONFIG */ |
782 | /* ========================================================================= */ | 945 | /* ========================================================================= */ |
783 | #define UVH_GR1_TLB_INT1_CONFIG 0x61f40UL | 946 | #define UVH_GR1_TLB_INT1_CONFIG 0x61f40UL |
784 | 947 | ||
785 | #define UVH_GR1_TLB_INT1_CONFIG_VECTOR_SHFT 0 | 948 | #define UVH_GR1_TLB_INT1_CONFIG_VECTOR_SHFT 0 |
786 | #define UVH_GR1_TLB_INT1_CONFIG_DM_SHFT 8 | 949 | #define UVH_GR1_TLB_INT1_CONFIG_DM_SHFT 8 |
@@ -820,9 +983,11 @@ union uvh_gr1_tlb_int1_config_u { | |||
820 | /* ========================================================================= */ | 983 | /* ========================================================================= */ |
821 | #define UV1H_GR1_TLB_MMR_CONTROL 0x801080UL | 984 | #define UV1H_GR1_TLB_MMR_CONTROL 0x801080UL |
822 | #define UV2H_GR1_TLB_MMR_CONTROL 0x1001080UL | 985 | #define UV2H_GR1_TLB_MMR_CONTROL 0x1001080UL |
823 | #define UVH_GR1_TLB_MMR_CONTROL (is_uv1_hub() ? \ | 986 | #define UV3H_GR1_TLB_MMR_CONTROL 0x1001080UL |
824 | UV1H_GR1_TLB_MMR_CONTROL : \ | 987 | #define UVH_GR1_TLB_MMR_CONTROL \ |
825 | UV2H_GR1_TLB_MMR_CONTROL) | 988 | (is_uv1_hub() ? UV1H_GR1_TLB_MMR_CONTROL : \ |
989 | (is_uv2_hub() ? UV2H_GR1_TLB_MMR_CONTROL : \ | ||
990 | UV3H_GR1_TLB_MMR_CONTROL)) | ||
826 | 991 | ||
827 | #define UVH_GR1_TLB_MMR_CONTROL_INDEX_SHFT 0 | 992 | #define UVH_GR1_TLB_MMR_CONTROL_INDEX_SHFT 0 |
828 | #define UVH_GR1_TLB_MMR_CONTROL_MEM_SEL_SHFT 12 | 993 | #define UVH_GR1_TLB_MMR_CONTROL_MEM_SEL_SHFT 12 |
@@ -860,6 +1025,21 @@ union uvh_gr1_tlb_int1_config_u { | |||
860 | #define UV1H_GR1_TLB_MMR_CONTROL_MMR_INJ_TLBRREG_MASK 0x0100000000000000UL | 1025 | #define UV1H_GR1_TLB_MMR_CONTROL_MMR_INJ_TLBRREG_MASK 0x0100000000000000UL |
861 | #define UV1H_GR1_TLB_MMR_CONTROL_MMR_INJ_TLBLRUV_MASK 0x1000000000000000UL | 1026 | #define UV1H_GR1_TLB_MMR_CONTROL_MMR_INJ_TLBLRUV_MASK 0x1000000000000000UL |
862 | 1027 | ||
1028 | #define UVXH_GR1_TLB_MMR_CONTROL_INDEX_SHFT 0 | ||
1029 | #define UVXH_GR1_TLB_MMR_CONTROL_MEM_SEL_SHFT 12 | ||
1030 | #define UVXH_GR1_TLB_MMR_CONTROL_AUTO_VALID_EN_SHFT 16 | ||
1031 | #define UVXH_GR1_TLB_MMR_CONTROL_MMR_HASH_INDEX_EN_SHFT 20 | ||
1032 | #define UVXH_GR1_TLB_MMR_CONTROL_MMR_WRITE_SHFT 30 | ||
1033 | #define UVXH_GR1_TLB_MMR_CONTROL_MMR_READ_SHFT 31 | ||
1034 | #define UVXH_GR1_TLB_MMR_CONTROL_MMR_OP_DONE_SHFT 32 | ||
1035 | #define UVXH_GR1_TLB_MMR_CONTROL_INDEX_MASK 0x0000000000000fffUL | ||
1036 | #define UVXH_GR1_TLB_MMR_CONTROL_MEM_SEL_MASK 0x0000000000003000UL | ||
1037 | #define UVXH_GR1_TLB_MMR_CONTROL_AUTO_VALID_EN_MASK 0x0000000000010000UL | ||
1038 | #define UVXH_GR1_TLB_MMR_CONTROL_MMR_HASH_INDEX_EN_MASK 0x0000000000100000UL | ||
1039 | #define UVXH_GR1_TLB_MMR_CONTROL_MMR_WRITE_MASK 0x0000000040000000UL | ||
1040 | #define UVXH_GR1_TLB_MMR_CONTROL_MMR_READ_MASK 0x0000000080000000UL | ||
1041 | #define UVXH_GR1_TLB_MMR_CONTROL_MMR_OP_DONE_MASK 0x0000000100000000UL | ||
1042 | |||
863 | #define UV2H_GR1_TLB_MMR_CONTROL_INDEX_SHFT 0 | 1043 | #define UV2H_GR1_TLB_MMR_CONTROL_INDEX_SHFT 0 |
864 | #define UV2H_GR1_TLB_MMR_CONTROL_MEM_SEL_SHFT 12 | 1044 | #define UV2H_GR1_TLB_MMR_CONTROL_MEM_SEL_SHFT 12 |
865 | #define UV2H_GR1_TLB_MMR_CONTROL_AUTO_VALID_EN_SHFT 16 | 1045 | #define UV2H_GR1_TLB_MMR_CONTROL_AUTO_VALID_EN_SHFT 16 |
@@ -879,6 +1059,23 @@ union uvh_gr1_tlb_int1_config_u { | |||
879 | #define UV2H_GR1_TLB_MMR_CONTROL_MMR_INJ_CON_MASK 0x0001000000000000UL | 1059 | #define UV2H_GR1_TLB_MMR_CONTROL_MMR_INJ_CON_MASK 0x0001000000000000UL |
880 | #define UV2H_GR1_TLB_MMR_CONTROL_MMR_INJ_TLBRAM_MASK 0x0010000000000000UL | 1060 | #define UV2H_GR1_TLB_MMR_CONTROL_MMR_INJ_TLBRAM_MASK 0x0010000000000000UL |
881 | 1061 | ||
1062 | #define UV3H_GR1_TLB_MMR_CONTROL_INDEX_SHFT 0 | ||
1063 | #define UV3H_GR1_TLB_MMR_CONTROL_MEM_SEL_SHFT 12 | ||
1064 | #define UV3H_GR1_TLB_MMR_CONTROL_AUTO_VALID_EN_SHFT 16 | ||
1065 | #define UV3H_GR1_TLB_MMR_CONTROL_MMR_HASH_INDEX_EN_SHFT 20 | ||
1066 | #define UV3H_GR1_TLB_MMR_CONTROL_ECC_SEL_SHFT 21 | ||
1067 | #define UV3H_GR1_TLB_MMR_CONTROL_MMR_WRITE_SHFT 30 | ||
1068 | #define UV3H_GR1_TLB_MMR_CONTROL_MMR_READ_SHFT 31 | ||
1069 | #define UV3H_GR1_TLB_MMR_CONTROL_MMR_OP_DONE_SHFT 32 | ||
1070 | #define UV3H_GR1_TLB_MMR_CONTROL_INDEX_MASK 0x0000000000000fffUL | ||
1071 | #define UV3H_GR1_TLB_MMR_CONTROL_MEM_SEL_MASK 0x0000000000003000UL | ||
1072 | #define UV3H_GR1_TLB_MMR_CONTROL_AUTO_VALID_EN_MASK 0x0000000000010000UL | ||
1073 | #define UV3H_GR1_TLB_MMR_CONTROL_MMR_HASH_INDEX_EN_MASK 0x0000000000100000UL | ||
1074 | #define UV3H_GR1_TLB_MMR_CONTROL_ECC_SEL_MASK 0x0000000000200000UL | ||
1075 | #define UV3H_GR1_TLB_MMR_CONTROL_MMR_WRITE_MASK 0x0000000040000000UL | ||
1076 | #define UV3H_GR1_TLB_MMR_CONTROL_MMR_READ_MASK 0x0000000080000000UL | ||
1077 | #define UV3H_GR1_TLB_MMR_CONTROL_MMR_OP_DONE_MASK 0x0000000100000000UL | ||
1078 | |||
882 | union uvh_gr1_tlb_mmr_control_u { | 1079 | union uvh_gr1_tlb_mmr_control_u { |
883 | unsigned long v; | 1080 | unsigned long v; |
884 | struct uvh_gr1_tlb_mmr_control_s { | 1081 | struct uvh_gr1_tlb_mmr_control_s { |
@@ -891,7 +1088,9 @@ union uvh_gr1_tlb_mmr_control_u { | |||
891 | unsigned long rsvd_21_29:9; | 1088 | unsigned long rsvd_21_29:9; |
892 | unsigned long mmr_write:1; /* WP */ | 1089 | unsigned long mmr_write:1; /* WP */ |
893 | unsigned long mmr_read:1; /* WP */ | 1090 | unsigned long mmr_read:1; /* WP */ |
894 | unsigned long rsvd_32_63:32; | 1091 | unsigned long rsvd_32_48:17; |
1092 | unsigned long rsvd_49_51:3; | ||
1093 | unsigned long rsvd_52_63:12; | ||
895 | } s; | 1094 | } s; |
896 | struct uv1h_gr1_tlb_mmr_control_s { | 1095 | struct uv1h_gr1_tlb_mmr_control_s { |
897 | unsigned long index:12; /* RW */ | 1096 | unsigned long index:12; /* RW */ |
@@ -915,6 +1114,23 @@ union uvh_gr1_tlb_mmr_control_u { | |||
915 | unsigned long mmr_inj_tlblruv:1; /* RW */ | 1114 | unsigned long mmr_inj_tlblruv:1; /* RW */ |
916 | unsigned long rsvd_61_63:3; | 1115 | unsigned long rsvd_61_63:3; |
917 | } s1; | 1116 | } s1; |
1117 | struct uvxh_gr1_tlb_mmr_control_s { | ||
1118 | unsigned long index:12; /* RW */ | ||
1119 | unsigned long mem_sel:2; /* RW */ | ||
1120 | unsigned long rsvd_14_15:2; | ||
1121 | unsigned long auto_valid_en:1; /* RW */ | ||
1122 | unsigned long rsvd_17_19:3; | ||
1123 | unsigned long mmr_hash_index_en:1; /* RW */ | ||
1124 | unsigned long rsvd_21_29:9; | ||
1125 | unsigned long mmr_write:1; /* WP */ | ||
1126 | unsigned long mmr_read:1; /* WP */ | ||
1127 | unsigned long mmr_op_done:1; /* RW */ | ||
1128 | unsigned long rsvd_33_47:15; | ||
1129 | unsigned long rsvd_48:1; | ||
1130 | unsigned long rsvd_49_51:3; | ||
1131 | unsigned long rsvd_52:1; | ||
1132 | unsigned long rsvd_53_63:11; | ||
1133 | } sx; | ||
918 | struct uv2h_gr1_tlb_mmr_control_s { | 1134 | struct uv2h_gr1_tlb_mmr_control_s { |
919 | unsigned long index:12; /* RW */ | 1135 | unsigned long index:12; /* RW */ |
920 | unsigned long mem_sel:2; /* RW */ | 1136 | unsigned long mem_sel:2; /* RW */ |
@@ -932,6 +1148,24 @@ union uvh_gr1_tlb_mmr_control_u { | |||
932 | unsigned long mmr_inj_tlbram:1; /* RW */ | 1148 | unsigned long mmr_inj_tlbram:1; /* RW */ |
933 | unsigned long rsvd_53_63:11; | 1149 | unsigned long rsvd_53_63:11; |
934 | } s2; | 1150 | } s2; |
1151 | struct uv3h_gr1_tlb_mmr_control_s { | ||
1152 | unsigned long index:12; /* RW */ | ||
1153 | unsigned long mem_sel:2; /* RW */ | ||
1154 | unsigned long rsvd_14_15:2; | ||
1155 | unsigned long auto_valid_en:1; /* RW */ | ||
1156 | unsigned long rsvd_17_19:3; | ||
1157 | unsigned long mmr_hash_index_en:1; /* RW */ | ||
1158 | unsigned long ecc_sel:1; /* RW */ | ||
1159 | unsigned long rsvd_22_29:8; | ||
1160 | unsigned long mmr_write:1; /* WP */ | ||
1161 | unsigned long mmr_read:1; /* WP */ | ||
1162 | unsigned long mmr_op_done:1; /* RW */ | ||
1163 | unsigned long rsvd_33_47:15; | ||
1164 | unsigned long undef_48:1; /* Undefined */ | ||
1165 | unsigned long rsvd_49_51:3; | ||
1166 | unsigned long undef_52:1; /* Undefined */ | ||
1167 | unsigned long rsvd_53_63:11; | ||
1168 | } s3; | ||
935 | }; | 1169 | }; |
936 | 1170 | ||
937 | /* ========================================================================= */ | 1171 | /* ========================================================================= */ |
@@ -939,9 +1173,11 @@ union uvh_gr1_tlb_mmr_control_u { | |||
939 | /* ========================================================================= */ | 1173 | /* ========================================================================= */ |
940 | #define UV1H_GR1_TLB_MMR_READ_DATA_HI 0x8010a0UL | 1174 | #define UV1H_GR1_TLB_MMR_READ_DATA_HI 0x8010a0UL |
941 | #define UV2H_GR1_TLB_MMR_READ_DATA_HI 0x10010a0UL | 1175 | #define UV2H_GR1_TLB_MMR_READ_DATA_HI 0x10010a0UL |
942 | #define UVH_GR1_TLB_MMR_READ_DATA_HI (is_uv1_hub() ? \ | 1176 | #define UV3H_GR1_TLB_MMR_READ_DATA_HI 0x10010a0UL |
943 | UV1H_GR1_TLB_MMR_READ_DATA_HI : \ | 1177 | #define UVH_GR1_TLB_MMR_READ_DATA_HI \ |
944 | UV2H_GR1_TLB_MMR_READ_DATA_HI) | 1178 | (is_uv1_hub() ? UV1H_GR1_TLB_MMR_READ_DATA_HI : \ |
1179 | (is_uv2_hub() ? UV2H_GR1_TLB_MMR_READ_DATA_HI : \ | ||
1180 | UV3H_GR1_TLB_MMR_READ_DATA_HI)) | ||
945 | 1181 | ||
946 | #define UVH_GR1_TLB_MMR_READ_DATA_HI_PFN_SHFT 0 | 1182 | #define UVH_GR1_TLB_MMR_READ_DATA_HI_PFN_SHFT 0 |
947 | #define UVH_GR1_TLB_MMR_READ_DATA_HI_GAA_SHFT 41 | 1183 | #define UVH_GR1_TLB_MMR_READ_DATA_HI_GAA_SHFT 41 |
@@ -952,6 +1188,46 @@ union uvh_gr1_tlb_mmr_control_u { | |||
952 | #define UVH_GR1_TLB_MMR_READ_DATA_HI_DIRTY_MASK 0x0000080000000000UL | 1188 | #define UVH_GR1_TLB_MMR_READ_DATA_HI_DIRTY_MASK 0x0000080000000000UL |
953 | #define UVH_GR1_TLB_MMR_READ_DATA_HI_LARGER_MASK 0x0000100000000000UL | 1189 | #define UVH_GR1_TLB_MMR_READ_DATA_HI_LARGER_MASK 0x0000100000000000UL |
954 | 1190 | ||
1191 | #define UV1H_GR1_TLB_MMR_READ_DATA_HI_PFN_SHFT 0 | ||
1192 | #define UV1H_GR1_TLB_MMR_READ_DATA_HI_GAA_SHFT 41 | ||
1193 | #define UV1H_GR1_TLB_MMR_READ_DATA_HI_DIRTY_SHFT 43 | ||
1194 | #define UV1H_GR1_TLB_MMR_READ_DATA_HI_LARGER_SHFT 44 | ||
1195 | #define UV1H_GR1_TLB_MMR_READ_DATA_HI_PFN_MASK 0x000001ffffffffffUL | ||
1196 | #define UV1H_GR1_TLB_MMR_READ_DATA_HI_GAA_MASK 0x0000060000000000UL | ||
1197 | #define UV1H_GR1_TLB_MMR_READ_DATA_HI_DIRTY_MASK 0x0000080000000000UL | ||
1198 | #define UV1H_GR1_TLB_MMR_READ_DATA_HI_LARGER_MASK 0x0000100000000000UL | ||
1199 | |||
1200 | #define UVXH_GR1_TLB_MMR_READ_DATA_HI_PFN_SHFT 0 | ||
1201 | #define UVXH_GR1_TLB_MMR_READ_DATA_HI_GAA_SHFT 41 | ||
1202 | #define UVXH_GR1_TLB_MMR_READ_DATA_HI_DIRTY_SHFT 43 | ||
1203 | #define UVXH_GR1_TLB_MMR_READ_DATA_HI_LARGER_SHFT 44 | ||
1204 | #define UVXH_GR1_TLB_MMR_READ_DATA_HI_PFN_MASK 0x000001ffffffffffUL | ||
1205 | #define UVXH_GR1_TLB_MMR_READ_DATA_HI_GAA_MASK 0x0000060000000000UL | ||
1206 | #define UVXH_GR1_TLB_MMR_READ_DATA_HI_DIRTY_MASK 0x0000080000000000UL | ||
1207 | #define UVXH_GR1_TLB_MMR_READ_DATA_HI_LARGER_MASK 0x0000100000000000UL | ||
1208 | |||
1209 | #define UV2H_GR1_TLB_MMR_READ_DATA_HI_PFN_SHFT 0 | ||
1210 | #define UV2H_GR1_TLB_MMR_READ_DATA_HI_GAA_SHFT 41 | ||
1211 | #define UV2H_GR1_TLB_MMR_READ_DATA_HI_DIRTY_SHFT 43 | ||
1212 | #define UV2H_GR1_TLB_MMR_READ_DATA_HI_LARGER_SHFT 44 | ||
1213 | #define UV2H_GR1_TLB_MMR_READ_DATA_HI_PFN_MASK 0x000001ffffffffffUL | ||
1214 | #define UV2H_GR1_TLB_MMR_READ_DATA_HI_GAA_MASK 0x0000060000000000UL | ||
1215 | #define UV2H_GR1_TLB_MMR_READ_DATA_HI_DIRTY_MASK 0x0000080000000000UL | ||
1216 | #define UV2H_GR1_TLB_MMR_READ_DATA_HI_LARGER_MASK 0x0000100000000000UL | ||
1217 | |||
1218 | #define UV3H_GR1_TLB_MMR_READ_DATA_HI_PFN_SHFT 0 | ||
1219 | #define UV3H_GR1_TLB_MMR_READ_DATA_HI_GAA_SHFT 41 | ||
1220 | #define UV3H_GR1_TLB_MMR_READ_DATA_HI_DIRTY_SHFT 43 | ||
1221 | #define UV3H_GR1_TLB_MMR_READ_DATA_HI_LARGER_SHFT 44 | ||
1222 | #define UV3H_GR1_TLB_MMR_READ_DATA_HI_AA_EXT_SHFT 45 | ||
1223 | #define UV3H_GR1_TLB_MMR_READ_DATA_HI_WAY_ECC_SHFT 55 | ||
1224 | #define UV3H_GR1_TLB_MMR_READ_DATA_HI_PFN_MASK 0x000001ffffffffffUL | ||
1225 | #define UV3H_GR1_TLB_MMR_READ_DATA_HI_GAA_MASK 0x0000060000000000UL | ||
1226 | #define UV3H_GR1_TLB_MMR_READ_DATA_HI_DIRTY_MASK 0x0000080000000000UL | ||
1227 | #define UV3H_GR1_TLB_MMR_READ_DATA_HI_LARGER_MASK 0x0000100000000000UL | ||
1228 | #define UV3H_GR1_TLB_MMR_READ_DATA_HI_AA_EXT_MASK 0x0000200000000000UL | ||
1229 | #define UV3H_GR1_TLB_MMR_READ_DATA_HI_WAY_ECC_MASK 0xff80000000000000UL | ||
1230 | |||
955 | union uvh_gr1_tlb_mmr_read_data_hi_u { | 1231 | union uvh_gr1_tlb_mmr_read_data_hi_u { |
956 | unsigned long v; | 1232 | unsigned long v; |
957 | struct uvh_gr1_tlb_mmr_read_data_hi_s { | 1233 | struct uvh_gr1_tlb_mmr_read_data_hi_s { |
@@ -961,6 +1237,36 @@ union uvh_gr1_tlb_mmr_read_data_hi_u { | |||
961 | unsigned long larger:1; /* RO */ | 1237 | unsigned long larger:1; /* RO */ |
962 | unsigned long rsvd_45_63:19; | 1238 | unsigned long rsvd_45_63:19; |
963 | } s; | 1239 | } s; |
1240 | struct uv1h_gr1_tlb_mmr_read_data_hi_s { | ||
1241 | unsigned long pfn:41; /* RO */ | ||
1242 | unsigned long gaa:2; /* RO */ | ||
1243 | unsigned long dirty:1; /* RO */ | ||
1244 | unsigned long larger:1; /* RO */ | ||
1245 | unsigned long rsvd_45_63:19; | ||
1246 | } s1; | ||
1247 | struct uvxh_gr1_tlb_mmr_read_data_hi_s { | ||
1248 | unsigned long pfn:41; /* RO */ | ||
1249 | unsigned long gaa:2; /* RO */ | ||
1250 | unsigned long dirty:1; /* RO */ | ||
1251 | unsigned long larger:1; /* RO */ | ||
1252 | unsigned long rsvd_45_63:19; | ||
1253 | } sx; | ||
1254 | struct uv2h_gr1_tlb_mmr_read_data_hi_s { | ||
1255 | unsigned long pfn:41; /* RO */ | ||
1256 | unsigned long gaa:2; /* RO */ | ||
1257 | unsigned long dirty:1; /* RO */ | ||
1258 | unsigned long larger:1; /* RO */ | ||
1259 | unsigned long rsvd_45_63:19; | ||
1260 | } s2; | ||
1261 | struct uv3h_gr1_tlb_mmr_read_data_hi_s { | ||
1262 | unsigned long pfn:41; /* RO */ | ||
1263 | unsigned long gaa:2; /* RO */ | ||
1264 | unsigned long dirty:1; /* RO */ | ||
1265 | unsigned long larger:1; /* RO */ | ||
1266 | unsigned long aa_ext:1; /* RO */ | ||
1267 | unsigned long undef_46_54:9; /* Undefined */ | ||
1268 | unsigned long way_ecc:9; /* RO */ | ||
1269 | } s3; | ||
964 | }; | 1270 | }; |
965 | 1271 | ||
966 | /* ========================================================================= */ | 1272 | /* ========================================================================= */ |
@@ -968,9 +1274,11 @@ union uvh_gr1_tlb_mmr_read_data_hi_u { | |||
968 | /* ========================================================================= */ | 1274 | /* ========================================================================= */ |
969 | #define UV1H_GR1_TLB_MMR_READ_DATA_LO 0x8010a8UL | 1275 | #define UV1H_GR1_TLB_MMR_READ_DATA_LO 0x8010a8UL |
970 | #define UV2H_GR1_TLB_MMR_READ_DATA_LO 0x10010a8UL | 1276 | #define UV2H_GR1_TLB_MMR_READ_DATA_LO 0x10010a8UL |
971 | #define UVH_GR1_TLB_MMR_READ_DATA_LO (is_uv1_hub() ? \ | 1277 | #define UV3H_GR1_TLB_MMR_READ_DATA_LO 0x10010a8UL |
972 | UV1H_GR1_TLB_MMR_READ_DATA_LO : \ | 1278 | #define UVH_GR1_TLB_MMR_READ_DATA_LO \ |
973 | UV2H_GR1_TLB_MMR_READ_DATA_LO) | 1279 | (is_uv1_hub() ? UV1H_GR1_TLB_MMR_READ_DATA_LO : \ |
1280 | (is_uv2_hub() ? UV2H_GR1_TLB_MMR_READ_DATA_LO : \ | ||
1281 | UV3H_GR1_TLB_MMR_READ_DATA_LO)) | ||
974 | 1282 | ||
975 | #define UVH_GR1_TLB_MMR_READ_DATA_LO_VPN_SHFT 0 | 1283 | #define UVH_GR1_TLB_MMR_READ_DATA_LO_VPN_SHFT 0 |
976 | #define UVH_GR1_TLB_MMR_READ_DATA_LO_ASID_SHFT 39 | 1284 | #define UVH_GR1_TLB_MMR_READ_DATA_LO_ASID_SHFT 39 |
@@ -979,6 +1287,34 @@ union uvh_gr1_tlb_mmr_read_data_hi_u { | |||
979 | #define UVH_GR1_TLB_MMR_READ_DATA_LO_ASID_MASK 0x7fffff8000000000UL | 1287 | #define UVH_GR1_TLB_MMR_READ_DATA_LO_ASID_MASK 0x7fffff8000000000UL |
980 | #define UVH_GR1_TLB_MMR_READ_DATA_LO_VALID_MASK 0x8000000000000000UL | 1288 | #define UVH_GR1_TLB_MMR_READ_DATA_LO_VALID_MASK 0x8000000000000000UL |
981 | 1289 | ||
1290 | #define UV1H_GR1_TLB_MMR_READ_DATA_LO_VPN_SHFT 0 | ||
1291 | #define UV1H_GR1_TLB_MMR_READ_DATA_LO_ASID_SHFT 39 | ||
1292 | #define UV1H_GR1_TLB_MMR_READ_DATA_LO_VALID_SHFT 63 | ||
1293 | #define UV1H_GR1_TLB_MMR_READ_DATA_LO_VPN_MASK 0x0000007fffffffffUL | ||
1294 | #define UV1H_GR1_TLB_MMR_READ_DATA_LO_ASID_MASK 0x7fffff8000000000UL | ||
1295 | #define UV1H_GR1_TLB_MMR_READ_DATA_LO_VALID_MASK 0x8000000000000000UL | ||
1296 | |||
1297 | #define UVXH_GR1_TLB_MMR_READ_DATA_LO_VPN_SHFT 0 | ||
1298 | #define UVXH_GR1_TLB_MMR_READ_DATA_LO_ASID_SHFT 39 | ||
1299 | #define UVXH_GR1_TLB_MMR_READ_DATA_LO_VALID_SHFT 63 | ||
1300 | #define UVXH_GR1_TLB_MMR_READ_DATA_LO_VPN_MASK 0x0000007fffffffffUL | ||
1301 | #define UVXH_GR1_TLB_MMR_READ_DATA_LO_ASID_MASK 0x7fffff8000000000UL | ||
1302 | #define UVXH_GR1_TLB_MMR_READ_DATA_LO_VALID_MASK 0x8000000000000000UL | ||
1303 | |||
1304 | #define UV2H_GR1_TLB_MMR_READ_DATA_LO_VPN_SHFT 0 | ||
1305 | #define UV2H_GR1_TLB_MMR_READ_DATA_LO_ASID_SHFT 39 | ||
1306 | #define UV2H_GR1_TLB_MMR_READ_DATA_LO_VALID_SHFT 63 | ||
1307 | #define UV2H_GR1_TLB_MMR_READ_DATA_LO_VPN_MASK 0x0000007fffffffffUL | ||
1308 | #define UV2H_GR1_TLB_MMR_READ_DATA_LO_ASID_MASK 0x7fffff8000000000UL | ||
1309 | #define UV2H_GR1_TLB_MMR_READ_DATA_LO_VALID_MASK 0x8000000000000000UL | ||
1310 | |||
1311 | #define UV3H_GR1_TLB_MMR_READ_DATA_LO_VPN_SHFT 0 | ||
1312 | #define UV3H_GR1_TLB_MMR_READ_DATA_LO_ASID_SHFT 39 | ||
1313 | #define UV3H_GR1_TLB_MMR_READ_DATA_LO_VALID_SHFT 63 | ||
1314 | #define UV3H_GR1_TLB_MMR_READ_DATA_LO_VPN_MASK 0x0000007fffffffffUL | ||
1315 | #define UV3H_GR1_TLB_MMR_READ_DATA_LO_ASID_MASK 0x7fffff8000000000UL | ||
1316 | #define UV3H_GR1_TLB_MMR_READ_DATA_LO_VALID_MASK 0x8000000000000000UL | ||
1317 | |||
982 | union uvh_gr1_tlb_mmr_read_data_lo_u { | 1318 | union uvh_gr1_tlb_mmr_read_data_lo_u { |
983 | unsigned long v; | 1319 | unsigned long v; |
984 | struct uvh_gr1_tlb_mmr_read_data_lo_s { | 1320 | struct uvh_gr1_tlb_mmr_read_data_lo_s { |
@@ -986,12 +1322,32 @@ union uvh_gr1_tlb_mmr_read_data_lo_u { | |||
986 | unsigned long asid:24; /* RO */ | 1322 | unsigned long asid:24; /* RO */ |
987 | unsigned long valid:1; /* RO */ | 1323 | unsigned long valid:1; /* RO */ |
988 | } s; | 1324 | } s; |
1325 | struct uv1h_gr1_tlb_mmr_read_data_lo_s { | ||
1326 | unsigned long vpn:39; /* RO */ | ||
1327 | unsigned long asid:24; /* RO */ | ||
1328 | unsigned long valid:1; /* RO */ | ||
1329 | } s1; | ||
1330 | struct uvxh_gr1_tlb_mmr_read_data_lo_s { | ||
1331 | unsigned long vpn:39; /* RO */ | ||
1332 | unsigned long asid:24; /* RO */ | ||
1333 | unsigned long valid:1; /* RO */ | ||
1334 | } sx; | ||
1335 | struct uv2h_gr1_tlb_mmr_read_data_lo_s { | ||
1336 | unsigned long vpn:39; /* RO */ | ||
1337 | unsigned long asid:24; /* RO */ | ||
1338 | unsigned long valid:1; /* RO */ | ||
1339 | } s2; | ||
1340 | struct uv3h_gr1_tlb_mmr_read_data_lo_s { | ||
1341 | unsigned long vpn:39; /* RO */ | ||
1342 | unsigned long asid:24; /* RO */ | ||
1343 | unsigned long valid:1; /* RO */ | ||
1344 | } s3; | ||
989 | }; | 1345 | }; |
990 | 1346 | ||
991 | /* ========================================================================= */ | 1347 | /* ========================================================================= */ |
992 | /* UVH_INT_CMPB */ | 1348 | /* UVH_INT_CMPB */ |
993 | /* ========================================================================= */ | 1349 | /* ========================================================================= */ |
994 | #define UVH_INT_CMPB 0x22080UL | 1350 | #define UVH_INT_CMPB 0x22080UL |
995 | 1351 | ||
996 | #define UVH_INT_CMPB_REAL_TIME_CMPB_SHFT 0 | 1352 | #define UVH_INT_CMPB_REAL_TIME_CMPB_SHFT 0 |
997 | #define UVH_INT_CMPB_REAL_TIME_CMPB_MASK 0x00ffffffffffffffUL | 1353 | #define UVH_INT_CMPB_REAL_TIME_CMPB_MASK 0x00ffffffffffffffUL |
@@ -1007,10 +1363,13 @@ union uvh_int_cmpb_u { | |||
1007 | /* ========================================================================= */ | 1363 | /* ========================================================================= */ |
1008 | /* UVH_INT_CMPC */ | 1364 | /* UVH_INT_CMPC */ |
1009 | /* ========================================================================= */ | 1365 | /* ========================================================================= */ |
1010 | #define UVH_INT_CMPC 0x22100UL | 1366 | #define UVH_INT_CMPC 0x22100UL |
1367 | |||
1368 | #define UV1H_INT_CMPC_REAL_TIME_CMPC_SHFT 0 | ||
1369 | #define UV1H_INT_CMPC_REAL_TIME_CMPC_MASK 0x00ffffffffffffffUL | ||
1011 | 1370 | ||
1012 | #define UVH_INT_CMPC_REAL_TIME_CMPC_SHFT 0 | 1371 | #define UVXH_INT_CMPC_REAL_TIME_CMP_2_SHFT 0 |
1013 | #define UVH_INT_CMPC_REAL_TIME_CMPC_MASK 0xffffffffffffffUL | 1372 | #define UVXH_INT_CMPC_REAL_TIME_CMP_2_MASK 0x00ffffffffffffffUL |
1014 | 1373 | ||
1015 | union uvh_int_cmpc_u { | 1374 | union uvh_int_cmpc_u { |
1016 | unsigned long v; | 1375 | unsigned long v; |
@@ -1023,10 +1382,13 @@ union uvh_int_cmpc_u { | |||
1023 | /* ========================================================================= */ | 1382 | /* ========================================================================= */ |
1024 | /* UVH_INT_CMPD */ | 1383 | /* UVH_INT_CMPD */ |
1025 | /* ========================================================================= */ | 1384 | /* ========================================================================= */ |
1026 | #define UVH_INT_CMPD 0x22180UL | 1385 | #define UVH_INT_CMPD 0x22180UL |
1027 | 1386 | ||
1028 | #define UVH_INT_CMPD_REAL_TIME_CMPD_SHFT 0 | 1387 | #define UV1H_INT_CMPD_REAL_TIME_CMPD_SHFT 0 |
1029 | #define UVH_INT_CMPD_REAL_TIME_CMPD_MASK 0xffffffffffffffUL | 1388 | #define UV1H_INT_CMPD_REAL_TIME_CMPD_MASK 0x00ffffffffffffffUL |
1389 | |||
1390 | #define UVXH_INT_CMPD_REAL_TIME_CMP_3_SHFT 0 | ||
1391 | #define UVXH_INT_CMPD_REAL_TIME_CMP_3_MASK 0x00ffffffffffffffUL | ||
1030 | 1392 | ||
1031 | union uvh_int_cmpd_u { | 1393 | union uvh_int_cmpd_u { |
1032 | unsigned long v; | 1394 | unsigned long v; |
@@ -1039,8 +1401,8 @@ union uvh_int_cmpd_u { | |||
1039 | /* ========================================================================= */ | 1401 | /* ========================================================================= */ |
1040 | /* UVH_IPI_INT */ | 1402 | /* UVH_IPI_INT */ |
1041 | /* ========================================================================= */ | 1403 | /* ========================================================================= */ |
1042 | #define UVH_IPI_INT 0x60500UL | 1404 | #define UVH_IPI_INT 0x60500UL |
1043 | #define UVH_IPI_INT_32 0x348 | 1405 | #define UVH_IPI_INT_32 0x348 |
1044 | 1406 | ||
1045 | #define UVH_IPI_INT_VECTOR_SHFT 0 | 1407 | #define UVH_IPI_INT_VECTOR_SHFT 0 |
1046 | #define UVH_IPI_INT_DELIVERY_MODE_SHFT 8 | 1408 | #define UVH_IPI_INT_DELIVERY_MODE_SHFT 8 |
@@ -1069,8 +1431,8 @@ union uvh_ipi_int_u { | |||
1069 | /* ========================================================================= */ | 1431 | /* ========================================================================= */ |
1070 | /* UVH_LB_BAU_INTD_PAYLOAD_QUEUE_FIRST */ | 1432 | /* UVH_LB_BAU_INTD_PAYLOAD_QUEUE_FIRST */ |
1071 | /* ========================================================================= */ | 1433 | /* ========================================================================= */ |
1072 | #define UVH_LB_BAU_INTD_PAYLOAD_QUEUE_FIRST 0x320050UL | 1434 | #define UVH_LB_BAU_INTD_PAYLOAD_QUEUE_FIRST 0x320050UL |
1073 | #define UVH_LB_BAU_INTD_PAYLOAD_QUEUE_FIRST_32 0x9c0 | 1435 | #define UVH_LB_BAU_INTD_PAYLOAD_QUEUE_FIRST_32 0x9c0 |
1074 | 1436 | ||
1075 | #define UVH_LB_BAU_INTD_PAYLOAD_QUEUE_FIRST_ADDRESS_SHFT 4 | 1437 | #define UVH_LB_BAU_INTD_PAYLOAD_QUEUE_FIRST_ADDRESS_SHFT 4 |
1076 | #define UVH_LB_BAU_INTD_PAYLOAD_QUEUE_FIRST_NODE_ID_SHFT 49 | 1438 | #define UVH_LB_BAU_INTD_PAYLOAD_QUEUE_FIRST_NODE_ID_SHFT 49 |
@@ -1091,8 +1453,8 @@ union uvh_lb_bau_intd_payload_queue_first_u { | |||
1091 | /* ========================================================================= */ | 1453 | /* ========================================================================= */ |
1092 | /* UVH_LB_BAU_INTD_PAYLOAD_QUEUE_LAST */ | 1454 | /* UVH_LB_BAU_INTD_PAYLOAD_QUEUE_LAST */ |
1093 | /* ========================================================================= */ | 1455 | /* ========================================================================= */ |
1094 | #define UVH_LB_BAU_INTD_PAYLOAD_QUEUE_LAST 0x320060UL | 1456 | #define UVH_LB_BAU_INTD_PAYLOAD_QUEUE_LAST 0x320060UL |
1095 | #define UVH_LB_BAU_INTD_PAYLOAD_QUEUE_LAST_32 0x9c8 | 1457 | #define UVH_LB_BAU_INTD_PAYLOAD_QUEUE_LAST_32 0x9c8 |
1096 | 1458 | ||
1097 | #define UVH_LB_BAU_INTD_PAYLOAD_QUEUE_LAST_ADDRESS_SHFT 4 | 1459 | #define UVH_LB_BAU_INTD_PAYLOAD_QUEUE_LAST_ADDRESS_SHFT 4 |
1098 | #define UVH_LB_BAU_INTD_PAYLOAD_QUEUE_LAST_ADDRESS_MASK 0x000007fffffffff0UL | 1460 | #define UVH_LB_BAU_INTD_PAYLOAD_QUEUE_LAST_ADDRESS_MASK 0x000007fffffffff0UL |
@@ -1109,8 +1471,8 @@ union uvh_lb_bau_intd_payload_queue_last_u { | |||
1109 | /* ========================================================================= */ | 1471 | /* ========================================================================= */ |
1110 | /* UVH_LB_BAU_INTD_PAYLOAD_QUEUE_TAIL */ | 1472 | /* UVH_LB_BAU_INTD_PAYLOAD_QUEUE_TAIL */ |
1111 | /* ========================================================================= */ | 1473 | /* ========================================================================= */ |
1112 | #define UVH_LB_BAU_INTD_PAYLOAD_QUEUE_TAIL 0x320070UL | 1474 | #define UVH_LB_BAU_INTD_PAYLOAD_QUEUE_TAIL 0x320070UL |
1113 | #define UVH_LB_BAU_INTD_PAYLOAD_QUEUE_TAIL_32 0x9d0 | 1475 | #define UVH_LB_BAU_INTD_PAYLOAD_QUEUE_TAIL_32 0x9d0 |
1114 | 1476 | ||
1115 | #define UVH_LB_BAU_INTD_PAYLOAD_QUEUE_TAIL_ADDRESS_SHFT 4 | 1477 | #define UVH_LB_BAU_INTD_PAYLOAD_QUEUE_TAIL_ADDRESS_SHFT 4 |
1116 | #define UVH_LB_BAU_INTD_PAYLOAD_QUEUE_TAIL_ADDRESS_MASK 0x000007fffffffff0UL | 1478 | #define UVH_LB_BAU_INTD_PAYLOAD_QUEUE_TAIL_ADDRESS_MASK 0x000007fffffffff0UL |
@@ -1127,8 +1489,8 @@ union uvh_lb_bau_intd_payload_queue_tail_u { | |||
1127 | /* ========================================================================= */ | 1489 | /* ========================================================================= */ |
1128 | /* UVH_LB_BAU_INTD_SOFTWARE_ACKNOWLEDGE */ | 1490 | /* UVH_LB_BAU_INTD_SOFTWARE_ACKNOWLEDGE */ |
1129 | /* ========================================================================= */ | 1491 | /* ========================================================================= */ |
1130 | #define UVH_LB_BAU_INTD_SOFTWARE_ACKNOWLEDGE 0x320080UL | 1492 | #define UVH_LB_BAU_INTD_SOFTWARE_ACKNOWLEDGE 0x320080UL |
1131 | #define UVH_LB_BAU_INTD_SOFTWARE_ACKNOWLEDGE_32 0xa68 | 1493 | #define UVH_LB_BAU_INTD_SOFTWARE_ACKNOWLEDGE_32 0xa68 |
1132 | 1494 | ||
1133 | #define UVH_LB_BAU_INTD_SOFTWARE_ACKNOWLEDGE_PENDING_0_SHFT 0 | 1495 | #define UVH_LB_BAU_INTD_SOFTWARE_ACKNOWLEDGE_PENDING_0_SHFT 0 |
1134 | #define UVH_LB_BAU_INTD_SOFTWARE_ACKNOWLEDGE_PENDING_1_SHFT 1 | 1496 | #define UVH_LB_BAU_INTD_SOFTWARE_ACKNOWLEDGE_PENDING_1_SHFT 1 |
@@ -1189,14 +1551,21 @@ union uvh_lb_bau_intd_software_acknowledge_u { | |||
1189 | /* ========================================================================= */ | 1551 | /* ========================================================================= */ |
1190 | /* UVH_LB_BAU_INTD_SOFTWARE_ACKNOWLEDGE_ALIAS */ | 1552 | /* UVH_LB_BAU_INTD_SOFTWARE_ACKNOWLEDGE_ALIAS */ |
1191 | /* ========================================================================= */ | 1553 | /* ========================================================================= */ |
1192 | #define UVH_LB_BAU_INTD_SOFTWARE_ACKNOWLEDGE_ALIAS 0x0000000000320088UL | 1554 | #define UVH_LB_BAU_INTD_SOFTWARE_ACKNOWLEDGE_ALIAS 0x320088UL |
1193 | #define UVH_LB_BAU_INTD_SOFTWARE_ACKNOWLEDGE_ALIAS_32 0xa70 | 1555 | #define UVH_LB_BAU_INTD_SOFTWARE_ACKNOWLEDGE_ALIAS_32 0xa70 |
1556 | |||
1194 | 1557 | ||
1195 | /* ========================================================================= */ | 1558 | /* ========================================================================= */ |
1196 | /* UVH_LB_BAU_MISC_CONTROL */ | 1559 | /* UVH_LB_BAU_MISC_CONTROL */ |
1197 | /* ========================================================================= */ | 1560 | /* ========================================================================= */ |
1198 | #define UVH_LB_BAU_MISC_CONTROL 0x320170UL | 1561 | #define UVH_LB_BAU_MISC_CONTROL 0x320170UL |
1199 | #define UVH_LB_BAU_MISC_CONTROL_32 0xa10 | 1562 | #define UV1H_LB_BAU_MISC_CONTROL 0x320170UL |
1563 | #define UV2H_LB_BAU_MISC_CONTROL 0x320170UL | ||
1564 | #define UV3H_LB_BAU_MISC_CONTROL 0x320170UL | ||
1565 | #define UVH_LB_BAU_MISC_CONTROL_32 0xa10 | ||
1566 | #define UV1H_LB_BAU_MISC_CONTROL_32 0x320170UL | ||
1567 | #define UV2H_LB_BAU_MISC_CONTROL_32 0x320170UL | ||
1568 | #define UV3H_LB_BAU_MISC_CONTROL_32 0x320170UL | ||
1200 | 1569 | ||
1201 | #define UVH_LB_BAU_MISC_CONTROL_REJECTION_DELAY_SHFT 0 | 1570 | #define UVH_LB_BAU_MISC_CONTROL_REJECTION_DELAY_SHFT 0 |
1202 | #define UVH_LB_BAU_MISC_CONTROL_APIC_MODE_SHFT 8 | 1571 | #define UVH_LB_BAU_MISC_CONTROL_APIC_MODE_SHFT 8 |
@@ -1213,6 +1582,7 @@ union uvh_lb_bau_intd_software_acknowledge_u { | |||
1213 | #define UVH_LB_BAU_MISC_CONTROL_PROGRAMMED_INITIAL_PRIORITY_SHFT 24 | 1582 | #define UVH_LB_BAU_MISC_CONTROL_PROGRAMMED_INITIAL_PRIORITY_SHFT 24 |
1214 | #define UVH_LB_BAU_MISC_CONTROL_USE_INCOMING_PRIORITY_SHFT 27 | 1583 | #define UVH_LB_BAU_MISC_CONTROL_USE_INCOMING_PRIORITY_SHFT 27 |
1215 | #define UVH_LB_BAU_MISC_CONTROL_ENABLE_PROGRAMMED_INITIAL_PRIORITY_SHFT 28 | 1584 | #define UVH_LB_BAU_MISC_CONTROL_ENABLE_PROGRAMMED_INITIAL_PRIORITY_SHFT 28 |
1585 | #define UVH_LB_BAU_MISC_CONTROL_FUN_SHFT 48 | ||
1216 | #define UVH_LB_BAU_MISC_CONTROL_REJECTION_DELAY_MASK 0x00000000000000ffUL | 1586 | #define UVH_LB_BAU_MISC_CONTROL_REJECTION_DELAY_MASK 0x00000000000000ffUL |
1217 | #define UVH_LB_BAU_MISC_CONTROL_APIC_MODE_MASK 0x0000000000000100UL | 1587 | #define UVH_LB_BAU_MISC_CONTROL_APIC_MODE_MASK 0x0000000000000100UL |
1218 | #define UVH_LB_BAU_MISC_CONTROL_FORCE_BROADCAST_MASK 0x0000000000000200UL | 1588 | #define UVH_LB_BAU_MISC_CONTROL_FORCE_BROADCAST_MASK 0x0000000000000200UL |
@@ -1228,6 +1598,7 @@ union uvh_lb_bau_intd_software_acknowledge_u { | |||
1228 | #define UVH_LB_BAU_MISC_CONTROL_PROGRAMMED_INITIAL_PRIORITY_MASK 0x0000000007000000UL | 1598 | #define UVH_LB_BAU_MISC_CONTROL_PROGRAMMED_INITIAL_PRIORITY_MASK 0x0000000007000000UL |
1229 | #define UVH_LB_BAU_MISC_CONTROL_USE_INCOMING_PRIORITY_MASK 0x0000000008000000UL | 1599 | #define UVH_LB_BAU_MISC_CONTROL_USE_INCOMING_PRIORITY_MASK 0x0000000008000000UL |
1230 | #define UVH_LB_BAU_MISC_CONTROL_ENABLE_PROGRAMMED_INITIAL_PRIORITY_MASK 0x0000000010000000UL | 1600 | #define UVH_LB_BAU_MISC_CONTROL_ENABLE_PROGRAMMED_INITIAL_PRIORITY_MASK 0x0000000010000000UL |
1601 | #define UVH_LB_BAU_MISC_CONTROL_FUN_MASK 0xffff000000000000UL | ||
1231 | 1602 | ||
1232 | #define UV1H_LB_BAU_MISC_CONTROL_REJECTION_DELAY_SHFT 0 | 1603 | #define UV1H_LB_BAU_MISC_CONTROL_REJECTION_DELAY_SHFT 0 |
1233 | #define UV1H_LB_BAU_MISC_CONTROL_APIC_MODE_SHFT 8 | 1604 | #define UV1H_LB_BAU_MISC_CONTROL_APIC_MODE_SHFT 8 |
@@ -1262,6 +1633,53 @@ union uvh_lb_bau_intd_software_acknowledge_u { | |||
1262 | #define UV1H_LB_BAU_MISC_CONTROL_ENABLE_PROGRAMMED_INITIAL_PRIORITY_MASK 0x0000000010000000UL | 1633 | #define UV1H_LB_BAU_MISC_CONTROL_ENABLE_PROGRAMMED_INITIAL_PRIORITY_MASK 0x0000000010000000UL |
1263 | #define UV1H_LB_BAU_MISC_CONTROL_FUN_MASK 0xffff000000000000UL | 1634 | #define UV1H_LB_BAU_MISC_CONTROL_FUN_MASK 0xffff000000000000UL |
1264 | 1635 | ||
1636 | #define UVXH_LB_BAU_MISC_CONTROL_REJECTION_DELAY_SHFT 0 | ||
1637 | #define UVXH_LB_BAU_MISC_CONTROL_APIC_MODE_SHFT 8 | ||
1638 | #define UVXH_LB_BAU_MISC_CONTROL_FORCE_BROADCAST_SHFT 9 | ||
1639 | #define UVXH_LB_BAU_MISC_CONTROL_FORCE_LOCK_NOP_SHFT 10 | ||
1640 | #define UVXH_LB_BAU_MISC_CONTROL_QPI_AGENT_PRESENCE_VECTOR_SHFT 11 | ||
1641 | #define UVXH_LB_BAU_MISC_CONTROL_DESCRIPTOR_FETCH_MODE_SHFT 14 | ||
1642 | #define UVXH_LB_BAU_MISC_CONTROL_ENABLE_INTD_SOFT_ACK_MODE_SHFT 15 | ||
1643 | #define UVXH_LB_BAU_MISC_CONTROL_INTD_SOFT_ACK_TIMEOUT_PERIOD_SHFT 16 | ||
1644 | #define UVXH_LB_BAU_MISC_CONTROL_ENABLE_DUAL_MAPPING_MODE_SHFT 20 | ||
1645 | #define UVXH_LB_BAU_MISC_CONTROL_VGA_IO_PORT_DECODE_ENABLE_SHFT 21 | ||
1646 | #define UVXH_LB_BAU_MISC_CONTROL_VGA_IO_PORT_16_BIT_DECODE_SHFT 22 | ||
1647 | #define UVXH_LB_BAU_MISC_CONTROL_SUPPRESS_DEST_REGISTRATION_SHFT 23 | ||
1648 | #define UVXH_LB_BAU_MISC_CONTROL_PROGRAMMED_INITIAL_PRIORITY_SHFT 24 | ||
1649 | #define UVXH_LB_BAU_MISC_CONTROL_USE_INCOMING_PRIORITY_SHFT 27 | ||
1650 | #define UVXH_LB_BAU_MISC_CONTROL_ENABLE_PROGRAMMED_INITIAL_PRIORITY_SHFT 28 | ||
1651 | #define UVXH_LB_BAU_MISC_CONTROL_ENABLE_AUTOMATIC_APIC_MODE_SELECTION_SHFT 29 | ||
1652 | #define UVXH_LB_BAU_MISC_CONTROL_APIC_MODE_STATUS_SHFT 30 | ||
1653 | #define UVXH_LB_BAU_MISC_CONTROL_SUPPRESS_INTERRUPTS_TO_SELF_SHFT 31 | ||
1654 | #define UVXH_LB_BAU_MISC_CONTROL_ENABLE_LOCK_BASED_SYSTEM_FLUSH_SHFT 32 | ||
1655 | #define UVXH_LB_BAU_MISC_CONTROL_ENABLE_EXTENDED_SB_STATUS_SHFT 33 | ||
1656 | #define UVXH_LB_BAU_MISC_CONTROL_SUPPRESS_INT_PRIO_UDT_TO_SELF_SHFT 34 | ||
1657 | #define UVXH_LB_BAU_MISC_CONTROL_USE_LEGACY_DESCRIPTOR_FORMATS_SHFT 35 | ||
1658 | #define UVXH_LB_BAU_MISC_CONTROL_FUN_SHFT 48 | ||
1659 | #define UVXH_LB_BAU_MISC_CONTROL_REJECTION_DELAY_MASK 0x00000000000000ffUL | ||
1660 | #define UVXH_LB_BAU_MISC_CONTROL_APIC_MODE_MASK 0x0000000000000100UL | ||
1661 | #define UVXH_LB_BAU_MISC_CONTROL_FORCE_BROADCAST_MASK 0x0000000000000200UL | ||
1662 | #define UVXH_LB_BAU_MISC_CONTROL_FORCE_LOCK_NOP_MASK 0x0000000000000400UL | ||
1663 | #define UVXH_LB_BAU_MISC_CONTROL_QPI_AGENT_PRESENCE_VECTOR_MASK 0x0000000000003800UL | ||
1664 | #define UVXH_LB_BAU_MISC_CONTROL_DESCRIPTOR_FETCH_MODE_MASK 0x0000000000004000UL | ||
1665 | #define UVXH_LB_BAU_MISC_CONTROL_ENABLE_INTD_SOFT_ACK_MODE_MASK 0x0000000000008000UL | ||
1666 | #define UVXH_LB_BAU_MISC_CONTROL_INTD_SOFT_ACK_TIMEOUT_PERIOD_MASK 0x00000000000f0000UL | ||
1667 | #define UVXH_LB_BAU_MISC_CONTROL_ENABLE_DUAL_MAPPING_MODE_MASK 0x0000000000100000UL | ||
1668 | #define UVXH_LB_BAU_MISC_CONTROL_VGA_IO_PORT_DECODE_ENABLE_MASK 0x0000000000200000UL | ||
1669 | #define UVXH_LB_BAU_MISC_CONTROL_VGA_IO_PORT_16_BIT_DECODE_MASK 0x0000000000400000UL | ||
1670 | #define UVXH_LB_BAU_MISC_CONTROL_SUPPRESS_DEST_REGISTRATION_MASK 0x0000000000800000UL | ||
1671 | #define UVXH_LB_BAU_MISC_CONTROL_PROGRAMMED_INITIAL_PRIORITY_MASK 0x0000000007000000UL | ||
1672 | #define UVXH_LB_BAU_MISC_CONTROL_USE_INCOMING_PRIORITY_MASK 0x0000000008000000UL | ||
1673 | #define UVXH_LB_BAU_MISC_CONTROL_ENABLE_PROGRAMMED_INITIAL_PRIORITY_MASK 0x0000000010000000UL | ||
1674 | #define UVXH_LB_BAU_MISC_CONTROL_ENABLE_AUTOMATIC_APIC_MODE_SELECTION_MASK 0x0000000020000000UL | ||
1675 | #define UVXH_LB_BAU_MISC_CONTROL_APIC_MODE_STATUS_MASK 0x0000000040000000UL | ||
1676 | #define UVXH_LB_BAU_MISC_CONTROL_SUPPRESS_INTERRUPTS_TO_SELF_MASK 0x0000000080000000UL | ||
1677 | #define UVXH_LB_BAU_MISC_CONTROL_ENABLE_LOCK_BASED_SYSTEM_FLUSH_MASK 0x0000000100000000UL | ||
1678 | #define UVXH_LB_BAU_MISC_CONTROL_ENABLE_EXTENDED_SB_STATUS_MASK 0x0000000200000000UL | ||
1679 | #define UVXH_LB_BAU_MISC_CONTROL_SUPPRESS_INT_PRIO_UDT_TO_SELF_MASK 0x0000000400000000UL | ||
1680 | #define UVXH_LB_BAU_MISC_CONTROL_USE_LEGACY_DESCRIPTOR_FORMATS_MASK 0x0000000800000000UL | ||
1681 | #define UVXH_LB_BAU_MISC_CONTROL_FUN_MASK 0xffff000000000000UL | ||
1682 | |||
1265 | #define UV2H_LB_BAU_MISC_CONTROL_REJECTION_DELAY_SHFT 0 | 1683 | #define UV2H_LB_BAU_MISC_CONTROL_REJECTION_DELAY_SHFT 0 |
1266 | #define UV2H_LB_BAU_MISC_CONTROL_APIC_MODE_SHFT 8 | 1684 | #define UV2H_LB_BAU_MISC_CONTROL_APIC_MODE_SHFT 8 |
1267 | #define UV2H_LB_BAU_MISC_CONTROL_FORCE_BROADCAST_SHFT 9 | 1685 | #define UV2H_LB_BAU_MISC_CONTROL_FORCE_BROADCAST_SHFT 9 |
@@ -1309,6 +1727,59 @@ union uvh_lb_bau_intd_software_acknowledge_u { | |||
1309 | #define UV2H_LB_BAU_MISC_CONTROL_USE_LEGACY_DESCRIPTOR_FORMATS_MASK 0x0000000800000000UL | 1727 | #define UV2H_LB_BAU_MISC_CONTROL_USE_LEGACY_DESCRIPTOR_FORMATS_MASK 0x0000000800000000UL |
1310 | #define UV2H_LB_BAU_MISC_CONTROL_FUN_MASK 0xffff000000000000UL | 1728 | #define UV2H_LB_BAU_MISC_CONTROL_FUN_MASK 0xffff000000000000UL |
1311 | 1729 | ||
1730 | #define UV3H_LB_BAU_MISC_CONTROL_REJECTION_DELAY_SHFT 0 | ||
1731 | #define UV3H_LB_BAU_MISC_CONTROL_APIC_MODE_SHFT 8 | ||
1732 | #define UV3H_LB_BAU_MISC_CONTROL_FORCE_BROADCAST_SHFT 9 | ||
1733 | #define UV3H_LB_BAU_MISC_CONTROL_FORCE_LOCK_NOP_SHFT 10 | ||
1734 | #define UV3H_LB_BAU_MISC_CONTROL_QPI_AGENT_PRESENCE_VECTOR_SHFT 11 | ||
1735 | #define UV3H_LB_BAU_MISC_CONTROL_DESCRIPTOR_FETCH_MODE_SHFT 14 | ||
1736 | #define UV3H_LB_BAU_MISC_CONTROL_ENABLE_INTD_SOFT_ACK_MODE_SHFT 15 | ||
1737 | #define UV3H_LB_BAU_MISC_CONTROL_INTD_SOFT_ACK_TIMEOUT_PERIOD_SHFT 16 | ||
1738 | #define UV3H_LB_BAU_MISC_CONTROL_ENABLE_DUAL_MAPPING_MODE_SHFT 20 | ||
1739 | #define UV3H_LB_BAU_MISC_CONTROL_VGA_IO_PORT_DECODE_ENABLE_SHFT 21 | ||
1740 | #define UV3H_LB_BAU_MISC_CONTROL_VGA_IO_PORT_16_BIT_DECODE_SHFT 22 | ||
1741 | #define UV3H_LB_BAU_MISC_CONTROL_SUPPRESS_DEST_REGISTRATION_SHFT 23 | ||
1742 | #define UV3H_LB_BAU_MISC_CONTROL_PROGRAMMED_INITIAL_PRIORITY_SHFT 24 | ||
1743 | #define UV3H_LB_BAU_MISC_CONTROL_USE_INCOMING_PRIORITY_SHFT 27 | ||
1744 | #define UV3H_LB_BAU_MISC_CONTROL_ENABLE_PROGRAMMED_INITIAL_PRIORITY_SHFT 28 | ||
1745 | #define UV3H_LB_BAU_MISC_CONTROL_ENABLE_AUTOMATIC_APIC_MODE_SELECTION_SHFT 29 | ||
1746 | #define UV3H_LB_BAU_MISC_CONTROL_APIC_MODE_STATUS_SHFT 30 | ||
1747 | #define UV3H_LB_BAU_MISC_CONTROL_SUPPRESS_INTERRUPTS_TO_SELF_SHFT 31 | ||
1748 | #define UV3H_LB_BAU_MISC_CONTROL_ENABLE_LOCK_BASED_SYSTEM_FLUSH_SHFT 32 | ||
1749 | #define UV3H_LB_BAU_MISC_CONTROL_ENABLE_EXTENDED_SB_STATUS_SHFT 33 | ||
1750 | #define UV3H_LB_BAU_MISC_CONTROL_SUPPRESS_INT_PRIO_UDT_TO_SELF_SHFT 34 | ||
1751 | #define UV3H_LB_BAU_MISC_CONTROL_USE_LEGACY_DESCRIPTOR_FORMATS_SHFT 35 | ||
1752 | #define UV3H_LB_BAU_MISC_CONTROL_SUPPRESS_QUIESCE_MSGS_TO_QPI_SHFT 36 | ||
1753 | #define UV3H_LB_BAU_MISC_CONTROL_ENABLE_INTD_PREFETCH_HINT_SHFT 37 | ||
1754 | #define UV3H_LB_BAU_MISC_CONTROL_THREAD_KILL_TIMEBASE_SHFT 38 | ||
1755 | #define UV3H_LB_BAU_MISC_CONTROL_FUN_SHFT 48 | ||
1756 | #define UV3H_LB_BAU_MISC_CONTROL_REJECTION_DELAY_MASK 0x00000000000000ffUL | ||
1757 | #define UV3H_LB_BAU_MISC_CONTROL_APIC_MODE_MASK 0x0000000000000100UL | ||
1758 | #define UV3H_LB_BAU_MISC_CONTROL_FORCE_BROADCAST_MASK 0x0000000000000200UL | ||
1759 | #define UV3H_LB_BAU_MISC_CONTROL_FORCE_LOCK_NOP_MASK 0x0000000000000400UL | ||
1760 | #define UV3H_LB_BAU_MISC_CONTROL_QPI_AGENT_PRESENCE_VECTOR_MASK 0x0000000000003800UL | ||
1761 | #define UV3H_LB_BAU_MISC_CONTROL_DESCRIPTOR_FETCH_MODE_MASK 0x0000000000004000UL | ||
1762 | #define UV3H_LB_BAU_MISC_CONTROL_ENABLE_INTD_SOFT_ACK_MODE_MASK 0x0000000000008000UL | ||
1763 | #define UV3H_LB_BAU_MISC_CONTROL_INTD_SOFT_ACK_TIMEOUT_PERIOD_MASK 0x00000000000f0000UL | ||
1764 | #define UV3H_LB_BAU_MISC_CONTROL_ENABLE_DUAL_MAPPING_MODE_MASK 0x0000000000100000UL | ||
1765 | #define UV3H_LB_BAU_MISC_CONTROL_VGA_IO_PORT_DECODE_ENABLE_MASK 0x0000000000200000UL | ||
1766 | #define UV3H_LB_BAU_MISC_CONTROL_VGA_IO_PORT_16_BIT_DECODE_MASK 0x0000000000400000UL | ||
1767 | #define UV3H_LB_BAU_MISC_CONTROL_SUPPRESS_DEST_REGISTRATION_MASK 0x0000000000800000UL | ||
1768 | #define UV3H_LB_BAU_MISC_CONTROL_PROGRAMMED_INITIAL_PRIORITY_MASK 0x0000000007000000UL | ||
1769 | #define UV3H_LB_BAU_MISC_CONTROL_USE_INCOMING_PRIORITY_MASK 0x0000000008000000UL | ||
1770 | #define UV3H_LB_BAU_MISC_CONTROL_ENABLE_PROGRAMMED_INITIAL_PRIORITY_MASK 0x0000000010000000UL | ||
1771 | #define UV3H_LB_BAU_MISC_CONTROL_ENABLE_AUTOMATIC_APIC_MODE_SELECTION_MASK 0x0000000020000000UL | ||
1772 | #define UV3H_LB_BAU_MISC_CONTROL_APIC_MODE_STATUS_MASK 0x0000000040000000UL | ||
1773 | #define UV3H_LB_BAU_MISC_CONTROL_SUPPRESS_INTERRUPTS_TO_SELF_MASK 0x0000000080000000UL | ||
1774 | #define UV3H_LB_BAU_MISC_CONTROL_ENABLE_LOCK_BASED_SYSTEM_FLUSH_MASK 0x0000000100000000UL | ||
1775 | #define UV3H_LB_BAU_MISC_CONTROL_ENABLE_EXTENDED_SB_STATUS_MASK 0x0000000200000000UL | ||
1776 | #define UV3H_LB_BAU_MISC_CONTROL_SUPPRESS_INT_PRIO_UDT_TO_SELF_MASK 0x0000000400000000UL | ||
1777 | #define UV3H_LB_BAU_MISC_CONTROL_USE_LEGACY_DESCRIPTOR_FORMATS_MASK 0x0000000800000000UL | ||
1778 | #define UV3H_LB_BAU_MISC_CONTROL_SUPPRESS_QUIESCE_MSGS_TO_QPI_MASK 0x0000001000000000UL | ||
1779 | #define UV3H_LB_BAU_MISC_CONTROL_ENABLE_INTD_PREFETCH_HINT_MASK 0x0000002000000000UL | ||
1780 | #define UV3H_LB_BAU_MISC_CONTROL_THREAD_KILL_TIMEBASE_MASK 0x00003fc000000000UL | ||
1781 | #define UV3H_LB_BAU_MISC_CONTROL_FUN_MASK 0xffff000000000000UL | ||
1782 | |||
1312 | union uvh_lb_bau_misc_control_u { | 1783 | union uvh_lb_bau_misc_control_u { |
1313 | unsigned long v; | 1784 | unsigned long v; |
1314 | struct uvh_lb_bau_misc_control_s { | 1785 | struct uvh_lb_bau_misc_control_s { |
@@ -1327,7 +1798,8 @@ union uvh_lb_bau_misc_control_u { | |||
1327 | unsigned long programmed_initial_priority:3; /* RW */ | 1798 | unsigned long programmed_initial_priority:3; /* RW */ |
1328 | unsigned long use_incoming_priority:1; /* RW */ | 1799 | unsigned long use_incoming_priority:1; /* RW */ |
1329 | unsigned long enable_programmed_initial_priority:1;/* RW */ | 1800 | unsigned long enable_programmed_initial_priority:1;/* RW */ |
1330 | unsigned long rsvd_29_63:35; | 1801 | unsigned long rsvd_29_47:19; |
1802 | unsigned long fun:16; /* RW */ | ||
1331 | } s; | 1803 | } s; |
1332 | struct uv1h_lb_bau_misc_control_s { | 1804 | struct uv1h_lb_bau_misc_control_s { |
1333 | unsigned long rejection_delay:8; /* RW */ | 1805 | unsigned long rejection_delay:8; /* RW */ |
@@ -1348,6 +1820,32 @@ union uvh_lb_bau_misc_control_u { | |||
1348 | unsigned long rsvd_29_47:19; | 1820 | unsigned long rsvd_29_47:19; |
1349 | unsigned long fun:16; /* RW */ | 1821 | unsigned long fun:16; /* RW */ |
1350 | } s1; | 1822 | } s1; |
1823 | struct uvxh_lb_bau_misc_control_s { | ||
1824 | unsigned long rejection_delay:8; /* RW */ | ||
1825 | unsigned long apic_mode:1; /* RW */ | ||
1826 | unsigned long force_broadcast:1; /* RW */ | ||
1827 | unsigned long force_lock_nop:1; /* RW */ | ||
1828 | unsigned long qpi_agent_presence_vector:3; /* RW */ | ||
1829 | unsigned long descriptor_fetch_mode:1; /* RW */ | ||
1830 | unsigned long enable_intd_soft_ack_mode:1; /* RW */ | ||
1831 | unsigned long intd_soft_ack_timeout_period:4; /* RW */ | ||
1832 | unsigned long enable_dual_mapping_mode:1; /* RW */ | ||
1833 | unsigned long vga_io_port_decode_enable:1; /* RW */ | ||
1834 | unsigned long vga_io_port_16_bit_decode:1; /* RW */ | ||
1835 | unsigned long suppress_dest_registration:1; /* RW */ | ||
1836 | unsigned long programmed_initial_priority:3; /* RW */ | ||
1837 | unsigned long use_incoming_priority:1; /* RW */ | ||
1838 | unsigned long enable_programmed_initial_priority:1;/* RW */ | ||
1839 | unsigned long enable_automatic_apic_mode_selection:1;/* RW */ | ||
1840 | unsigned long apic_mode_status:1; /* RO */ | ||
1841 | unsigned long suppress_interrupts_to_self:1; /* RW */ | ||
1842 | unsigned long enable_lock_based_system_flush:1;/* RW */ | ||
1843 | unsigned long enable_extended_sb_status:1; /* RW */ | ||
1844 | unsigned long suppress_int_prio_udt_to_self:1;/* RW */ | ||
1845 | unsigned long use_legacy_descriptor_formats:1;/* RW */ | ||
1846 | unsigned long rsvd_36_47:12; | ||
1847 | unsigned long fun:16; /* RW */ | ||
1848 | } sx; | ||
1351 | struct uv2h_lb_bau_misc_control_s { | 1849 | struct uv2h_lb_bau_misc_control_s { |
1352 | unsigned long rejection_delay:8; /* RW */ | 1850 | unsigned long rejection_delay:8; /* RW */ |
1353 | unsigned long apic_mode:1; /* RW */ | 1851 | unsigned long apic_mode:1; /* RW */ |
@@ -1374,13 +1872,42 @@ union uvh_lb_bau_misc_control_u { | |||
1374 | unsigned long rsvd_36_47:12; | 1872 | unsigned long rsvd_36_47:12; |
1375 | unsigned long fun:16; /* RW */ | 1873 | unsigned long fun:16; /* RW */ |
1376 | } s2; | 1874 | } s2; |
1875 | struct uv3h_lb_bau_misc_control_s { | ||
1876 | unsigned long rejection_delay:8; /* RW */ | ||
1877 | unsigned long apic_mode:1; /* RW */ | ||
1878 | unsigned long force_broadcast:1; /* RW */ | ||
1879 | unsigned long force_lock_nop:1; /* RW */ | ||
1880 | unsigned long qpi_agent_presence_vector:3; /* RW */ | ||
1881 | unsigned long descriptor_fetch_mode:1; /* RW */ | ||
1882 | unsigned long enable_intd_soft_ack_mode:1; /* RW */ | ||
1883 | unsigned long intd_soft_ack_timeout_period:4; /* RW */ | ||
1884 | unsigned long enable_dual_mapping_mode:1; /* RW */ | ||
1885 | unsigned long vga_io_port_decode_enable:1; /* RW */ | ||
1886 | unsigned long vga_io_port_16_bit_decode:1; /* RW */ | ||
1887 | unsigned long suppress_dest_registration:1; /* RW */ | ||
1888 | unsigned long programmed_initial_priority:3; /* RW */ | ||
1889 | unsigned long use_incoming_priority:1; /* RW */ | ||
1890 | unsigned long enable_programmed_initial_priority:1;/* RW */ | ||
1891 | unsigned long enable_automatic_apic_mode_selection:1;/* RW */ | ||
1892 | unsigned long apic_mode_status:1; /* RO */ | ||
1893 | unsigned long suppress_interrupts_to_self:1; /* RW */ | ||
1894 | unsigned long enable_lock_based_system_flush:1;/* RW */ | ||
1895 | unsigned long enable_extended_sb_status:1; /* RW */ | ||
1896 | unsigned long suppress_int_prio_udt_to_self:1;/* RW */ | ||
1897 | unsigned long use_legacy_descriptor_formats:1;/* RW */ | ||
1898 | unsigned long suppress_quiesce_msgs_to_qpi:1; /* RW */ | ||
1899 | unsigned long enable_intd_prefetch_hint:1; /* RW */ | ||
1900 | unsigned long thread_kill_timebase:8; /* RW */ | ||
1901 | unsigned long rsvd_46_47:2; | ||
1902 | unsigned long fun:16; /* RW */ | ||
1903 | } s3; | ||
1377 | }; | 1904 | }; |
1378 | 1905 | ||
1379 | /* ========================================================================= */ | 1906 | /* ========================================================================= */ |
1380 | /* UVH_LB_BAU_SB_ACTIVATION_CONTROL */ | 1907 | /* UVH_LB_BAU_SB_ACTIVATION_CONTROL */ |
1381 | /* ========================================================================= */ | 1908 | /* ========================================================================= */ |
1382 | #define UVH_LB_BAU_SB_ACTIVATION_CONTROL 0x320020UL | 1909 | #define UVH_LB_BAU_SB_ACTIVATION_CONTROL 0x320020UL |
1383 | #define UVH_LB_BAU_SB_ACTIVATION_CONTROL_32 0x9a8 | 1910 | #define UVH_LB_BAU_SB_ACTIVATION_CONTROL_32 0x9a8 |
1384 | 1911 | ||
1385 | #define UVH_LB_BAU_SB_ACTIVATION_CONTROL_INDEX_SHFT 0 | 1912 | #define UVH_LB_BAU_SB_ACTIVATION_CONTROL_INDEX_SHFT 0 |
1386 | #define UVH_LB_BAU_SB_ACTIVATION_CONTROL_PUSH_SHFT 62 | 1913 | #define UVH_LB_BAU_SB_ACTIVATION_CONTROL_PUSH_SHFT 62 |
@@ -1402,8 +1929,8 @@ union uvh_lb_bau_sb_activation_control_u { | |||
1402 | /* ========================================================================= */ | 1929 | /* ========================================================================= */ |
1403 | /* UVH_LB_BAU_SB_ACTIVATION_STATUS_0 */ | 1930 | /* UVH_LB_BAU_SB_ACTIVATION_STATUS_0 */ |
1404 | /* ========================================================================= */ | 1931 | /* ========================================================================= */ |
1405 | #define UVH_LB_BAU_SB_ACTIVATION_STATUS_0 0x320030UL | 1932 | #define UVH_LB_BAU_SB_ACTIVATION_STATUS_0 0x320030UL |
1406 | #define UVH_LB_BAU_SB_ACTIVATION_STATUS_0_32 0x9b0 | 1933 | #define UVH_LB_BAU_SB_ACTIVATION_STATUS_0_32 0x9b0 |
1407 | 1934 | ||
1408 | #define UVH_LB_BAU_SB_ACTIVATION_STATUS_0_STATUS_SHFT 0 | 1935 | #define UVH_LB_BAU_SB_ACTIVATION_STATUS_0_STATUS_SHFT 0 |
1409 | #define UVH_LB_BAU_SB_ACTIVATION_STATUS_0_STATUS_MASK 0xffffffffffffffffUL | 1936 | #define UVH_LB_BAU_SB_ACTIVATION_STATUS_0_STATUS_MASK 0xffffffffffffffffUL |
@@ -1418,8 +1945,8 @@ union uvh_lb_bau_sb_activation_status_0_u { | |||
1418 | /* ========================================================================= */ | 1945 | /* ========================================================================= */ |
1419 | /* UVH_LB_BAU_SB_ACTIVATION_STATUS_1 */ | 1946 | /* UVH_LB_BAU_SB_ACTIVATION_STATUS_1 */ |
1420 | /* ========================================================================= */ | 1947 | /* ========================================================================= */ |
1421 | #define UVH_LB_BAU_SB_ACTIVATION_STATUS_1 0x320040UL | 1948 | #define UVH_LB_BAU_SB_ACTIVATION_STATUS_1 0x320040UL |
1422 | #define UVH_LB_BAU_SB_ACTIVATION_STATUS_1_32 0x9b8 | 1949 | #define UVH_LB_BAU_SB_ACTIVATION_STATUS_1_32 0x9b8 |
1423 | 1950 | ||
1424 | #define UVH_LB_BAU_SB_ACTIVATION_STATUS_1_STATUS_SHFT 0 | 1951 | #define UVH_LB_BAU_SB_ACTIVATION_STATUS_1_STATUS_SHFT 0 |
1425 | #define UVH_LB_BAU_SB_ACTIVATION_STATUS_1_STATUS_MASK 0xffffffffffffffffUL | 1952 | #define UVH_LB_BAU_SB_ACTIVATION_STATUS_1_STATUS_MASK 0xffffffffffffffffUL |
@@ -1434,8 +1961,8 @@ union uvh_lb_bau_sb_activation_status_1_u { | |||
1434 | /* ========================================================================= */ | 1961 | /* ========================================================================= */ |
1435 | /* UVH_LB_BAU_SB_DESCRIPTOR_BASE */ | 1962 | /* UVH_LB_BAU_SB_DESCRIPTOR_BASE */ |
1436 | /* ========================================================================= */ | 1963 | /* ========================================================================= */ |
1437 | #define UVH_LB_BAU_SB_DESCRIPTOR_BASE 0x320010UL | 1964 | #define UVH_LB_BAU_SB_DESCRIPTOR_BASE 0x320010UL |
1438 | #define UVH_LB_BAU_SB_DESCRIPTOR_BASE_32 0x9a0 | 1965 | #define UVH_LB_BAU_SB_DESCRIPTOR_BASE_32 0x9a0 |
1439 | 1966 | ||
1440 | #define UVH_LB_BAU_SB_DESCRIPTOR_BASE_PAGE_ADDRESS_SHFT 12 | 1967 | #define UVH_LB_BAU_SB_DESCRIPTOR_BASE_PAGE_ADDRESS_SHFT 12 |
1441 | #define UVH_LB_BAU_SB_DESCRIPTOR_BASE_NODE_ID_SHFT 49 | 1968 | #define UVH_LB_BAU_SB_DESCRIPTOR_BASE_NODE_ID_SHFT 49 |
@@ -1456,7 +1983,10 @@ union uvh_lb_bau_sb_descriptor_base_u { | |||
1456 | /* ========================================================================= */ | 1983 | /* ========================================================================= */ |
1457 | /* UVH_NODE_ID */ | 1984 | /* UVH_NODE_ID */ |
1458 | /* ========================================================================= */ | 1985 | /* ========================================================================= */ |
1459 | #define UVH_NODE_ID 0x0UL | 1986 | #define UVH_NODE_ID 0x0UL |
1987 | #define UV1H_NODE_ID 0x0UL | ||
1988 | #define UV2H_NODE_ID 0x0UL | ||
1989 | #define UV3H_NODE_ID 0x0UL | ||
1460 | 1990 | ||
1461 | #define UVH_NODE_ID_FORCE1_SHFT 0 | 1991 | #define UVH_NODE_ID_FORCE1_SHFT 0 |
1462 | #define UVH_NODE_ID_MANUFACTURER_SHFT 1 | 1992 | #define UVH_NODE_ID_MANUFACTURER_SHFT 1 |
@@ -1484,6 +2014,21 @@ union uvh_lb_bau_sb_descriptor_base_u { | |||
1484 | #define UV1H_NODE_ID_NODES_PER_BIT_MASK 0x007f000000000000UL | 2014 | #define UV1H_NODE_ID_NODES_PER_BIT_MASK 0x007f000000000000UL |
1485 | #define UV1H_NODE_ID_NI_PORT_MASK 0x0f00000000000000UL | 2015 | #define UV1H_NODE_ID_NI_PORT_MASK 0x0f00000000000000UL |
1486 | 2016 | ||
2017 | #define UVXH_NODE_ID_FORCE1_SHFT 0 | ||
2018 | #define UVXH_NODE_ID_MANUFACTURER_SHFT 1 | ||
2019 | #define UVXH_NODE_ID_PART_NUMBER_SHFT 12 | ||
2020 | #define UVXH_NODE_ID_REVISION_SHFT 28 | ||
2021 | #define UVXH_NODE_ID_NODE_ID_SHFT 32 | ||
2022 | #define UVXH_NODE_ID_NODES_PER_BIT_SHFT 50 | ||
2023 | #define UVXH_NODE_ID_NI_PORT_SHFT 57 | ||
2024 | #define UVXH_NODE_ID_FORCE1_MASK 0x0000000000000001UL | ||
2025 | #define UVXH_NODE_ID_MANUFACTURER_MASK 0x0000000000000ffeUL | ||
2026 | #define UVXH_NODE_ID_PART_NUMBER_MASK 0x000000000ffff000UL | ||
2027 | #define UVXH_NODE_ID_REVISION_MASK 0x00000000f0000000UL | ||
2028 | #define UVXH_NODE_ID_NODE_ID_MASK 0x00007fff00000000UL | ||
2029 | #define UVXH_NODE_ID_NODES_PER_BIT_MASK 0x01fc000000000000UL | ||
2030 | #define UVXH_NODE_ID_NI_PORT_MASK 0x3e00000000000000UL | ||
2031 | |||
1487 | #define UV2H_NODE_ID_FORCE1_SHFT 0 | 2032 | #define UV2H_NODE_ID_FORCE1_SHFT 0 |
1488 | #define UV2H_NODE_ID_MANUFACTURER_SHFT 1 | 2033 | #define UV2H_NODE_ID_MANUFACTURER_SHFT 1 |
1489 | #define UV2H_NODE_ID_PART_NUMBER_SHFT 12 | 2034 | #define UV2H_NODE_ID_PART_NUMBER_SHFT 12 |
@@ -1499,6 +2044,25 @@ union uvh_lb_bau_sb_descriptor_base_u { | |||
1499 | #define UV2H_NODE_ID_NODES_PER_BIT_MASK 0x01fc000000000000UL | 2044 | #define UV2H_NODE_ID_NODES_PER_BIT_MASK 0x01fc000000000000UL |
1500 | #define UV2H_NODE_ID_NI_PORT_MASK 0x3e00000000000000UL | 2045 | #define UV2H_NODE_ID_NI_PORT_MASK 0x3e00000000000000UL |
1501 | 2046 | ||
2047 | #define UV3H_NODE_ID_FORCE1_SHFT 0 | ||
2048 | #define UV3H_NODE_ID_MANUFACTURER_SHFT 1 | ||
2049 | #define UV3H_NODE_ID_PART_NUMBER_SHFT 12 | ||
2050 | #define UV3H_NODE_ID_REVISION_SHFT 28 | ||
2051 | #define UV3H_NODE_ID_NODE_ID_SHFT 32 | ||
2052 | #define UV3H_NODE_ID_ROUTER_SELECT_SHFT 48 | ||
2053 | #define UV3H_NODE_ID_RESERVED_2_SHFT 49 | ||
2054 | #define UV3H_NODE_ID_NODES_PER_BIT_SHFT 50 | ||
2055 | #define UV3H_NODE_ID_NI_PORT_SHFT 57 | ||
2056 | #define UV3H_NODE_ID_FORCE1_MASK 0x0000000000000001UL | ||
2057 | #define UV3H_NODE_ID_MANUFACTURER_MASK 0x0000000000000ffeUL | ||
2058 | #define UV3H_NODE_ID_PART_NUMBER_MASK 0x000000000ffff000UL | ||
2059 | #define UV3H_NODE_ID_REVISION_MASK 0x00000000f0000000UL | ||
2060 | #define UV3H_NODE_ID_NODE_ID_MASK 0x00007fff00000000UL | ||
2061 | #define UV3H_NODE_ID_ROUTER_SELECT_MASK 0x0001000000000000UL | ||
2062 | #define UV3H_NODE_ID_RESERVED_2_MASK 0x0002000000000000UL | ||
2063 | #define UV3H_NODE_ID_NODES_PER_BIT_MASK 0x01fc000000000000UL | ||
2064 | #define UV3H_NODE_ID_NI_PORT_MASK 0x3e00000000000000UL | ||
2065 | |||
1502 | union uvh_node_id_u { | 2066 | union uvh_node_id_u { |
1503 | unsigned long v; | 2067 | unsigned long v; |
1504 | struct uvh_node_id_s { | 2068 | struct uvh_node_id_s { |
@@ -1521,6 +2085,17 @@ union uvh_node_id_u { | |||
1521 | unsigned long ni_port:4; /* RO */ | 2085 | unsigned long ni_port:4; /* RO */ |
1522 | unsigned long rsvd_60_63:4; | 2086 | unsigned long rsvd_60_63:4; |
1523 | } s1; | 2087 | } s1; |
2088 | struct uvxh_node_id_s { | ||
2089 | unsigned long force1:1; /* RO */ | ||
2090 | unsigned long manufacturer:11; /* RO */ | ||
2091 | unsigned long part_number:16; /* RO */ | ||
2092 | unsigned long revision:4; /* RO */ | ||
2093 | unsigned long node_id:15; /* RW */ | ||
2094 | unsigned long rsvd_47_49:3; | ||
2095 | unsigned long nodes_per_bit:7; /* RO */ | ||
2096 | unsigned long ni_port:5; /* RO */ | ||
2097 | unsigned long rsvd_62_63:2; | ||
2098 | } sx; | ||
1524 | struct uv2h_node_id_s { | 2099 | struct uv2h_node_id_s { |
1525 | unsigned long force1:1; /* RO */ | 2100 | unsigned long force1:1; /* RO */ |
1526 | unsigned long manufacturer:11; /* RO */ | 2101 | unsigned long manufacturer:11; /* RO */ |
@@ -1532,13 +2107,26 @@ union uvh_node_id_u { | |||
1532 | unsigned long ni_port:5; /* RO */ | 2107 | unsigned long ni_port:5; /* RO */ |
1533 | unsigned long rsvd_62_63:2; | 2108 | unsigned long rsvd_62_63:2; |
1534 | } s2; | 2109 | } s2; |
2110 | struct uv3h_node_id_s { | ||
2111 | unsigned long force1:1; /* RO */ | ||
2112 | unsigned long manufacturer:11; /* RO */ | ||
2113 | unsigned long part_number:16; /* RO */ | ||
2114 | unsigned long revision:4; /* RO */ | ||
2115 | unsigned long node_id:15; /* RW */ | ||
2116 | unsigned long rsvd_47:1; | ||
2117 | unsigned long router_select:1; /* RO */ | ||
2118 | unsigned long rsvd_49:1; | ||
2119 | unsigned long nodes_per_bit:7; /* RO */ | ||
2120 | unsigned long ni_port:5; /* RO */ | ||
2121 | unsigned long rsvd_62_63:2; | ||
2122 | } s3; | ||
1535 | }; | 2123 | }; |
1536 | 2124 | ||
1537 | /* ========================================================================= */ | 2125 | /* ========================================================================= */ |
1538 | /* UVH_NODE_PRESENT_TABLE */ | 2126 | /* UVH_NODE_PRESENT_TABLE */ |
1539 | /* ========================================================================= */ | 2127 | /* ========================================================================= */ |
1540 | #define UVH_NODE_PRESENT_TABLE 0x1400UL | 2128 | #define UVH_NODE_PRESENT_TABLE 0x1400UL |
1541 | #define UVH_NODE_PRESENT_TABLE_DEPTH 16 | 2129 | #define UVH_NODE_PRESENT_TABLE_DEPTH 16 |
1542 | 2130 | ||
1543 | #define UVH_NODE_PRESENT_TABLE_NODES_SHFT 0 | 2131 | #define UVH_NODE_PRESENT_TABLE_NODES_SHFT 0 |
1544 | #define UVH_NODE_PRESENT_TABLE_NODES_MASK 0xffffffffffffffffUL | 2132 | #define UVH_NODE_PRESENT_TABLE_NODES_MASK 0xffffffffffffffffUL |
@@ -1553,7 +2141,7 @@ union uvh_node_present_table_u { | |||
1553 | /* ========================================================================= */ | 2141 | /* ========================================================================= */ |
1554 | /* UVH_RH_GAM_ALIAS210_OVERLAY_CONFIG_0_MMR */ | 2142 | /* UVH_RH_GAM_ALIAS210_OVERLAY_CONFIG_0_MMR */ |
1555 | /* ========================================================================= */ | 2143 | /* ========================================================================= */ |
1556 | #define UVH_RH_GAM_ALIAS210_OVERLAY_CONFIG_0_MMR 0x16000c8UL | 2144 | #define UVH_RH_GAM_ALIAS210_OVERLAY_CONFIG_0_MMR 0x16000c8UL |
1557 | 2145 | ||
1558 | #define UVH_RH_GAM_ALIAS210_OVERLAY_CONFIG_0_MMR_BASE_SHFT 24 | 2146 | #define UVH_RH_GAM_ALIAS210_OVERLAY_CONFIG_0_MMR_BASE_SHFT 24 |
1559 | #define UVH_RH_GAM_ALIAS210_OVERLAY_CONFIG_0_MMR_M_ALIAS_SHFT 48 | 2147 | #define UVH_RH_GAM_ALIAS210_OVERLAY_CONFIG_0_MMR_M_ALIAS_SHFT 48 |
@@ -1577,7 +2165,7 @@ union uvh_rh_gam_alias210_overlay_config_0_mmr_u { | |||
1577 | /* ========================================================================= */ | 2165 | /* ========================================================================= */ |
1578 | /* UVH_RH_GAM_ALIAS210_OVERLAY_CONFIG_1_MMR */ | 2166 | /* UVH_RH_GAM_ALIAS210_OVERLAY_CONFIG_1_MMR */ |
1579 | /* ========================================================================= */ | 2167 | /* ========================================================================= */ |
1580 | #define UVH_RH_GAM_ALIAS210_OVERLAY_CONFIG_1_MMR 0x16000d8UL | 2168 | #define UVH_RH_GAM_ALIAS210_OVERLAY_CONFIG_1_MMR 0x16000d8UL |
1581 | 2169 | ||
1582 | #define UVH_RH_GAM_ALIAS210_OVERLAY_CONFIG_1_MMR_BASE_SHFT 24 | 2170 | #define UVH_RH_GAM_ALIAS210_OVERLAY_CONFIG_1_MMR_BASE_SHFT 24 |
1583 | #define UVH_RH_GAM_ALIAS210_OVERLAY_CONFIG_1_MMR_M_ALIAS_SHFT 48 | 2171 | #define UVH_RH_GAM_ALIAS210_OVERLAY_CONFIG_1_MMR_M_ALIAS_SHFT 48 |
@@ -1601,7 +2189,7 @@ union uvh_rh_gam_alias210_overlay_config_1_mmr_u { | |||
1601 | /* ========================================================================= */ | 2189 | /* ========================================================================= */ |
1602 | /* UVH_RH_GAM_ALIAS210_OVERLAY_CONFIG_2_MMR */ | 2190 | /* UVH_RH_GAM_ALIAS210_OVERLAY_CONFIG_2_MMR */ |
1603 | /* ========================================================================= */ | 2191 | /* ========================================================================= */ |
1604 | #define UVH_RH_GAM_ALIAS210_OVERLAY_CONFIG_2_MMR 0x16000e8UL | 2192 | #define UVH_RH_GAM_ALIAS210_OVERLAY_CONFIG_2_MMR 0x16000e8UL |
1605 | 2193 | ||
1606 | #define UVH_RH_GAM_ALIAS210_OVERLAY_CONFIG_2_MMR_BASE_SHFT 24 | 2194 | #define UVH_RH_GAM_ALIAS210_OVERLAY_CONFIG_2_MMR_BASE_SHFT 24 |
1607 | #define UVH_RH_GAM_ALIAS210_OVERLAY_CONFIG_2_MMR_M_ALIAS_SHFT 48 | 2195 | #define UVH_RH_GAM_ALIAS210_OVERLAY_CONFIG_2_MMR_M_ALIAS_SHFT 48 |
@@ -1625,7 +2213,7 @@ union uvh_rh_gam_alias210_overlay_config_2_mmr_u { | |||
1625 | /* ========================================================================= */ | 2213 | /* ========================================================================= */ |
1626 | /* UVH_RH_GAM_ALIAS210_REDIRECT_CONFIG_0_MMR */ | 2214 | /* UVH_RH_GAM_ALIAS210_REDIRECT_CONFIG_0_MMR */ |
1627 | /* ========================================================================= */ | 2215 | /* ========================================================================= */ |
1628 | #define UVH_RH_GAM_ALIAS210_REDIRECT_CONFIG_0_MMR 0x16000d0UL | 2216 | #define UVH_RH_GAM_ALIAS210_REDIRECT_CONFIG_0_MMR 0x16000d0UL |
1629 | 2217 | ||
1630 | #define UVH_RH_GAM_ALIAS210_REDIRECT_CONFIG_0_MMR_DEST_BASE_SHFT 24 | 2218 | #define UVH_RH_GAM_ALIAS210_REDIRECT_CONFIG_0_MMR_DEST_BASE_SHFT 24 |
1631 | #define UVH_RH_GAM_ALIAS210_REDIRECT_CONFIG_0_MMR_DEST_BASE_MASK 0x00003fffff000000UL | 2219 | #define UVH_RH_GAM_ALIAS210_REDIRECT_CONFIG_0_MMR_DEST_BASE_MASK 0x00003fffff000000UL |
@@ -1642,7 +2230,7 @@ union uvh_rh_gam_alias210_redirect_config_0_mmr_u { | |||
1642 | /* ========================================================================= */ | 2230 | /* ========================================================================= */ |
1643 | /* UVH_RH_GAM_ALIAS210_REDIRECT_CONFIG_1_MMR */ | 2231 | /* UVH_RH_GAM_ALIAS210_REDIRECT_CONFIG_1_MMR */ |
1644 | /* ========================================================================= */ | 2232 | /* ========================================================================= */ |
1645 | #define UVH_RH_GAM_ALIAS210_REDIRECT_CONFIG_1_MMR 0x16000e0UL | 2233 | #define UVH_RH_GAM_ALIAS210_REDIRECT_CONFIG_1_MMR 0x16000e0UL |
1646 | 2234 | ||
1647 | #define UVH_RH_GAM_ALIAS210_REDIRECT_CONFIG_1_MMR_DEST_BASE_SHFT 24 | 2235 | #define UVH_RH_GAM_ALIAS210_REDIRECT_CONFIG_1_MMR_DEST_BASE_SHFT 24 |
1648 | #define UVH_RH_GAM_ALIAS210_REDIRECT_CONFIG_1_MMR_DEST_BASE_MASK 0x00003fffff000000UL | 2236 | #define UVH_RH_GAM_ALIAS210_REDIRECT_CONFIG_1_MMR_DEST_BASE_MASK 0x00003fffff000000UL |
@@ -1659,7 +2247,7 @@ union uvh_rh_gam_alias210_redirect_config_1_mmr_u { | |||
1659 | /* ========================================================================= */ | 2247 | /* ========================================================================= */ |
1660 | /* UVH_RH_GAM_ALIAS210_REDIRECT_CONFIG_2_MMR */ | 2248 | /* UVH_RH_GAM_ALIAS210_REDIRECT_CONFIG_2_MMR */ |
1661 | /* ========================================================================= */ | 2249 | /* ========================================================================= */ |
1662 | #define UVH_RH_GAM_ALIAS210_REDIRECT_CONFIG_2_MMR 0x16000f0UL | 2250 | #define UVH_RH_GAM_ALIAS210_REDIRECT_CONFIG_2_MMR 0x16000f0UL |
1663 | 2251 | ||
1664 | #define UVH_RH_GAM_ALIAS210_REDIRECT_CONFIG_2_MMR_DEST_BASE_SHFT 24 | 2252 | #define UVH_RH_GAM_ALIAS210_REDIRECT_CONFIG_2_MMR_DEST_BASE_SHFT 24 |
1665 | #define UVH_RH_GAM_ALIAS210_REDIRECT_CONFIG_2_MMR_DEST_BASE_MASK 0x00003fffff000000UL | 2253 | #define UVH_RH_GAM_ALIAS210_REDIRECT_CONFIG_2_MMR_DEST_BASE_MASK 0x00003fffff000000UL |
@@ -1676,7 +2264,10 @@ union uvh_rh_gam_alias210_redirect_config_2_mmr_u { | |||
1676 | /* ========================================================================= */ | 2264 | /* ========================================================================= */ |
1677 | /* UVH_RH_GAM_CONFIG_MMR */ | 2265 | /* UVH_RH_GAM_CONFIG_MMR */ |
1678 | /* ========================================================================= */ | 2266 | /* ========================================================================= */ |
1679 | #define UVH_RH_GAM_CONFIG_MMR 0x1600000UL | 2267 | #define UVH_RH_GAM_CONFIG_MMR 0x1600000UL |
2268 | #define UV1H_RH_GAM_CONFIG_MMR 0x1600000UL | ||
2269 | #define UV2H_RH_GAM_CONFIG_MMR 0x1600000UL | ||
2270 | #define UV3H_RH_GAM_CONFIG_MMR 0x1600000UL | ||
1680 | 2271 | ||
1681 | #define UVH_RH_GAM_CONFIG_MMR_M_SKT_SHFT 0 | 2272 | #define UVH_RH_GAM_CONFIG_MMR_M_SKT_SHFT 0 |
1682 | #define UVH_RH_GAM_CONFIG_MMR_N_SKT_SHFT 6 | 2273 | #define UVH_RH_GAM_CONFIG_MMR_N_SKT_SHFT 6 |
@@ -1690,11 +2281,21 @@ union uvh_rh_gam_alias210_redirect_config_2_mmr_u { | |||
1690 | #define UV1H_RH_GAM_CONFIG_MMR_N_SKT_MASK 0x00000000000003c0UL | 2281 | #define UV1H_RH_GAM_CONFIG_MMR_N_SKT_MASK 0x00000000000003c0UL |
1691 | #define UV1H_RH_GAM_CONFIG_MMR_MMIOL_CFG_MASK 0x0000000000001000UL | 2282 | #define UV1H_RH_GAM_CONFIG_MMR_MMIOL_CFG_MASK 0x0000000000001000UL |
1692 | 2283 | ||
2284 | #define UVXH_RH_GAM_CONFIG_MMR_M_SKT_SHFT 0 | ||
2285 | #define UVXH_RH_GAM_CONFIG_MMR_N_SKT_SHFT 6 | ||
2286 | #define UVXH_RH_GAM_CONFIG_MMR_M_SKT_MASK 0x000000000000003fUL | ||
2287 | #define UVXH_RH_GAM_CONFIG_MMR_N_SKT_MASK 0x00000000000003c0UL | ||
2288 | |||
1693 | #define UV2H_RH_GAM_CONFIG_MMR_M_SKT_SHFT 0 | 2289 | #define UV2H_RH_GAM_CONFIG_MMR_M_SKT_SHFT 0 |
1694 | #define UV2H_RH_GAM_CONFIG_MMR_N_SKT_SHFT 6 | 2290 | #define UV2H_RH_GAM_CONFIG_MMR_N_SKT_SHFT 6 |
1695 | #define UV2H_RH_GAM_CONFIG_MMR_M_SKT_MASK 0x000000000000003fUL | 2291 | #define UV2H_RH_GAM_CONFIG_MMR_M_SKT_MASK 0x000000000000003fUL |
1696 | #define UV2H_RH_GAM_CONFIG_MMR_N_SKT_MASK 0x00000000000003c0UL | 2292 | #define UV2H_RH_GAM_CONFIG_MMR_N_SKT_MASK 0x00000000000003c0UL |
1697 | 2293 | ||
2294 | #define UV3H_RH_GAM_CONFIG_MMR_M_SKT_SHFT 0 | ||
2295 | #define UV3H_RH_GAM_CONFIG_MMR_N_SKT_SHFT 6 | ||
2296 | #define UV3H_RH_GAM_CONFIG_MMR_M_SKT_MASK 0x000000000000003fUL | ||
2297 | #define UV3H_RH_GAM_CONFIG_MMR_N_SKT_MASK 0x00000000000003c0UL | ||
2298 | |||
1698 | union uvh_rh_gam_config_mmr_u { | 2299 | union uvh_rh_gam_config_mmr_u { |
1699 | unsigned long v; | 2300 | unsigned long v; |
1700 | struct uvh_rh_gam_config_mmr_s { | 2301 | struct uvh_rh_gam_config_mmr_s { |
@@ -1709,20 +2310,37 @@ union uvh_rh_gam_config_mmr_u { | |||
1709 | unsigned long mmiol_cfg:1; /* RW */ | 2310 | unsigned long mmiol_cfg:1; /* RW */ |
1710 | unsigned long rsvd_13_63:51; | 2311 | unsigned long rsvd_13_63:51; |
1711 | } s1; | 2312 | } s1; |
2313 | struct uvxh_rh_gam_config_mmr_s { | ||
2314 | unsigned long m_skt:6; /* RW */ | ||
2315 | unsigned long n_skt:4; /* RW */ | ||
2316 | unsigned long rsvd_10_63:54; | ||
2317 | } sx; | ||
1712 | struct uv2h_rh_gam_config_mmr_s { | 2318 | struct uv2h_rh_gam_config_mmr_s { |
1713 | unsigned long m_skt:6; /* RW */ | 2319 | unsigned long m_skt:6; /* RW */ |
1714 | unsigned long n_skt:4; /* RW */ | 2320 | unsigned long n_skt:4; /* RW */ |
1715 | unsigned long rsvd_10_63:54; | 2321 | unsigned long rsvd_10_63:54; |
1716 | } s2; | 2322 | } s2; |
2323 | struct uv3h_rh_gam_config_mmr_s { | ||
2324 | unsigned long m_skt:6; /* RW */ | ||
2325 | unsigned long n_skt:4; /* RW */ | ||
2326 | unsigned long rsvd_10_63:54; | ||
2327 | } s3; | ||
1717 | }; | 2328 | }; |
1718 | 2329 | ||
1719 | /* ========================================================================= */ | 2330 | /* ========================================================================= */ |
1720 | /* UVH_RH_GAM_GRU_OVERLAY_CONFIG_MMR */ | 2331 | /* UVH_RH_GAM_GRU_OVERLAY_CONFIG_MMR */ |
1721 | /* ========================================================================= */ | 2332 | /* ========================================================================= */ |
1722 | #define UVH_RH_GAM_GRU_OVERLAY_CONFIG_MMR 0x1600010UL | 2333 | #define UVH_RH_GAM_GRU_OVERLAY_CONFIG_MMR 0x1600010UL |
2334 | #define UV1H_RH_GAM_GRU_OVERLAY_CONFIG_MMR 0x1600010UL | ||
2335 | #define UV2H_RH_GAM_GRU_OVERLAY_CONFIG_MMR 0x1600010UL | ||
2336 | #define UV3H_RH_GAM_GRU_OVERLAY_CONFIG_MMR 0x1600010UL | ||
1723 | 2337 | ||
1724 | #define UVH_RH_GAM_GRU_OVERLAY_CONFIG_MMR_BASE_SHFT 28 | 2338 | #define UVH_RH_GAM_GRU_OVERLAY_CONFIG_MMR_BASE_SHFT 28 |
2339 | #define UVH_RH_GAM_GRU_OVERLAY_CONFIG_MMR_N_GRU_SHFT 52 | ||
2340 | #define UVH_RH_GAM_GRU_OVERLAY_CONFIG_MMR_ENABLE_SHFT 63 | ||
1725 | #define UVH_RH_GAM_GRU_OVERLAY_CONFIG_MMR_BASE_MASK 0x00003ffff0000000UL | 2341 | #define UVH_RH_GAM_GRU_OVERLAY_CONFIG_MMR_BASE_MASK 0x00003ffff0000000UL |
2342 | #define UVH_RH_GAM_GRU_OVERLAY_CONFIG_MMR_N_GRU_MASK 0x00f0000000000000UL | ||
2343 | #define UVH_RH_GAM_GRU_OVERLAY_CONFIG_MMR_ENABLE_MASK 0x8000000000000000UL | ||
1726 | 2344 | ||
1727 | #define UV1H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_BASE_SHFT 28 | 2345 | #define UV1H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_BASE_SHFT 28 |
1728 | #define UV1H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_GR4_SHFT 48 | 2346 | #define UV1H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_GR4_SHFT 48 |
@@ -1733,6 +2351,13 @@ union uvh_rh_gam_config_mmr_u { | |||
1733 | #define UV1H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_N_GRU_MASK 0x00f0000000000000UL | 2351 | #define UV1H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_N_GRU_MASK 0x00f0000000000000UL |
1734 | #define UV1H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_ENABLE_MASK 0x8000000000000000UL | 2352 | #define UV1H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_ENABLE_MASK 0x8000000000000000UL |
1735 | 2353 | ||
2354 | #define UVXH_RH_GAM_GRU_OVERLAY_CONFIG_MMR_BASE_SHFT 28 | ||
2355 | #define UVXH_RH_GAM_GRU_OVERLAY_CONFIG_MMR_N_GRU_SHFT 52 | ||
2356 | #define UVXH_RH_GAM_GRU_OVERLAY_CONFIG_MMR_ENABLE_SHFT 63 | ||
2357 | #define UVXH_RH_GAM_GRU_OVERLAY_CONFIG_MMR_BASE_MASK 0x00003ffff0000000UL | ||
2358 | #define UVXH_RH_GAM_GRU_OVERLAY_CONFIG_MMR_N_GRU_MASK 0x00f0000000000000UL | ||
2359 | #define UVXH_RH_GAM_GRU_OVERLAY_CONFIG_MMR_ENABLE_MASK 0x8000000000000000UL | ||
2360 | |||
1736 | #define UV2H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_BASE_SHFT 28 | 2361 | #define UV2H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_BASE_SHFT 28 |
1737 | #define UV2H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_N_GRU_SHFT 52 | 2362 | #define UV2H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_N_GRU_SHFT 52 |
1738 | #define UV2H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_ENABLE_SHFT 63 | 2363 | #define UV2H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_ENABLE_SHFT 63 |
@@ -1740,12 +2365,23 @@ union uvh_rh_gam_config_mmr_u { | |||
1740 | #define UV2H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_N_GRU_MASK 0x00f0000000000000UL | 2365 | #define UV2H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_N_GRU_MASK 0x00f0000000000000UL |
1741 | #define UV2H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_ENABLE_MASK 0x8000000000000000UL | 2366 | #define UV2H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_ENABLE_MASK 0x8000000000000000UL |
1742 | 2367 | ||
2368 | #define UV3H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_BASE_SHFT 28 | ||
2369 | #define UV3H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_N_GRU_SHFT 52 | ||
2370 | #define UV3H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_MODE_SHFT 62 | ||
2371 | #define UV3H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_ENABLE_SHFT 63 | ||
2372 | #define UV3H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_BASE_MASK 0x00003ffff0000000UL | ||
2373 | #define UV3H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_N_GRU_MASK 0x00f0000000000000UL | ||
2374 | #define UV3H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_MODE_MASK 0x4000000000000000UL | ||
2375 | #define UV3H_RH_GAM_GRU_OVERLAY_CONFIG_MMR_ENABLE_MASK 0x8000000000000000UL | ||
2376 | |||
1743 | union uvh_rh_gam_gru_overlay_config_mmr_u { | 2377 | union uvh_rh_gam_gru_overlay_config_mmr_u { |
1744 | unsigned long v; | 2378 | unsigned long v; |
1745 | struct uvh_rh_gam_gru_overlay_config_mmr_s { | 2379 | struct uvh_rh_gam_gru_overlay_config_mmr_s { |
1746 | unsigned long rsvd_0_27:28; | 2380 | unsigned long rsvd_0_27:28; |
1747 | unsigned long base:18; /* RW */ | 2381 | unsigned long base:18; /* RW */ |
1748 | unsigned long rsvd_46_62:17; | 2382 | unsigned long rsvd_46_51:6; |
2383 | unsigned long n_gru:4; /* RW */ | ||
2384 | unsigned long rsvd_56_62:7; | ||
1749 | unsigned long enable:1; /* RW */ | 2385 | unsigned long enable:1; /* RW */ |
1750 | } s; | 2386 | } s; |
1751 | struct uv1h_rh_gam_gru_overlay_config_mmr_s { | 2387 | struct uv1h_rh_gam_gru_overlay_config_mmr_s { |
@@ -1758,6 +2394,14 @@ union uvh_rh_gam_gru_overlay_config_mmr_u { | |||
1758 | unsigned long rsvd_56_62:7; | 2394 | unsigned long rsvd_56_62:7; |
1759 | unsigned long enable:1; /* RW */ | 2395 | unsigned long enable:1; /* RW */ |
1760 | } s1; | 2396 | } s1; |
2397 | struct uvxh_rh_gam_gru_overlay_config_mmr_s { | ||
2398 | unsigned long rsvd_0_27:28; | ||
2399 | unsigned long base:18; /* RW */ | ||
2400 | unsigned long rsvd_46_51:6; | ||
2401 | unsigned long n_gru:4; /* RW */ | ||
2402 | unsigned long rsvd_56_62:7; | ||
2403 | unsigned long enable:1; /* RW */ | ||
2404 | } sx; | ||
1761 | struct uv2h_rh_gam_gru_overlay_config_mmr_s { | 2405 | struct uv2h_rh_gam_gru_overlay_config_mmr_s { |
1762 | unsigned long rsvd_0_27:28; | 2406 | unsigned long rsvd_0_27:28; |
1763 | unsigned long base:18; /* RW */ | 2407 | unsigned long base:18; /* RW */ |
@@ -1766,12 +2410,22 @@ union uvh_rh_gam_gru_overlay_config_mmr_u { | |||
1766 | unsigned long rsvd_56_62:7; | 2410 | unsigned long rsvd_56_62:7; |
1767 | unsigned long enable:1; /* RW */ | 2411 | unsigned long enable:1; /* RW */ |
1768 | } s2; | 2412 | } s2; |
2413 | struct uv3h_rh_gam_gru_overlay_config_mmr_s { | ||
2414 | unsigned long rsvd_0_27:28; | ||
2415 | unsigned long base:18; /* RW */ | ||
2416 | unsigned long rsvd_46_51:6; | ||
2417 | unsigned long n_gru:4; /* RW */ | ||
2418 | unsigned long rsvd_56_61:6; | ||
2419 | unsigned long mode:1; /* RW */ | ||
2420 | unsigned long enable:1; /* RW */ | ||
2421 | } s3; | ||
1769 | }; | 2422 | }; |
1770 | 2423 | ||
1771 | /* ========================================================================= */ | 2424 | /* ========================================================================= */ |
1772 | /* UVH_RH_GAM_MMIOH_OVERLAY_CONFIG_MMR */ | 2425 | /* UVH_RH_GAM_MMIOH_OVERLAY_CONFIG_MMR */ |
1773 | /* ========================================================================= */ | 2426 | /* ========================================================================= */ |
1774 | #define UVH_RH_GAM_MMIOH_OVERLAY_CONFIG_MMR 0x1600030UL | 2427 | #define UV1H_RH_GAM_MMIOH_OVERLAY_CONFIG_MMR 0x1600030UL |
2428 | #define UV2H_RH_GAM_MMIOH_OVERLAY_CONFIG_MMR 0x1600030UL | ||
1775 | 2429 | ||
1776 | #define UV1H_RH_GAM_MMIOH_OVERLAY_CONFIG_MMR_BASE_SHFT 30 | 2430 | #define UV1H_RH_GAM_MMIOH_OVERLAY_CONFIG_MMR_BASE_SHFT 30 |
1777 | #define UV1H_RH_GAM_MMIOH_OVERLAY_CONFIG_MMR_M_IO_SHFT 46 | 2431 | #define UV1H_RH_GAM_MMIOH_OVERLAY_CONFIG_MMR_M_IO_SHFT 46 |
@@ -1814,10 +2468,15 @@ union uvh_rh_gam_mmioh_overlay_config_mmr_u { | |||
1814 | /* ========================================================================= */ | 2468 | /* ========================================================================= */ |
1815 | /* UVH_RH_GAM_MMR_OVERLAY_CONFIG_MMR */ | 2469 | /* UVH_RH_GAM_MMR_OVERLAY_CONFIG_MMR */ |
1816 | /* ========================================================================= */ | 2470 | /* ========================================================================= */ |
1817 | #define UVH_RH_GAM_MMR_OVERLAY_CONFIG_MMR 0x1600028UL | 2471 | #define UVH_RH_GAM_MMR_OVERLAY_CONFIG_MMR 0x1600028UL |
2472 | #define UV1H_RH_GAM_MMR_OVERLAY_CONFIG_MMR 0x1600028UL | ||
2473 | #define UV2H_RH_GAM_MMR_OVERLAY_CONFIG_MMR 0x1600028UL | ||
2474 | #define UV3H_RH_GAM_MMR_OVERLAY_CONFIG_MMR 0x1600028UL | ||
1818 | 2475 | ||
1819 | #define UVH_RH_GAM_MMR_OVERLAY_CONFIG_MMR_BASE_SHFT 26 | 2476 | #define UVH_RH_GAM_MMR_OVERLAY_CONFIG_MMR_BASE_SHFT 26 |
2477 | #define UVH_RH_GAM_MMR_OVERLAY_CONFIG_MMR_ENABLE_SHFT 63 | ||
1820 | #define UVH_RH_GAM_MMR_OVERLAY_CONFIG_MMR_BASE_MASK 0x00003ffffc000000UL | 2478 | #define UVH_RH_GAM_MMR_OVERLAY_CONFIG_MMR_BASE_MASK 0x00003ffffc000000UL |
2479 | #define UVH_RH_GAM_MMR_OVERLAY_CONFIG_MMR_ENABLE_MASK 0x8000000000000000UL | ||
1821 | 2480 | ||
1822 | #define UV1H_RH_GAM_MMR_OVERLAY_CONFIG_MMR_BASE_SHFT 26 | 2481 | #define UV1H_RH_GAM_MMR_OVERLAY_CONFIG_MMR_BASE_SHFT 26 |
1823 | #define UV1H_RH_GAM_MMR_OVERLAY_CONFIG_MMR_DUAL_HUB_SHFT 46 | 2482 | #define UV1H_RH_GAM_MMR_OVERLAY_CONFIG_MMR_DUAL_HUB_SHFT 46 |
@@ -1826,11 +2485,21 @@ union uvh_rh_gam_mmioh_overlay_config_mmr_u { | |||
1826 | #define UV1H_RH_GAM_MMR_OVERLAY_CONFIG_MMR_DUAL_HUB_MASK 0x0000400000000000UL | 2485 | #define UV1H_RH_GAM_MMR_OVERLAY_CONFIG_MMR_DUAL_HUB_MASK 0x0000400000000000UL |
1827 | #define UV1H_RH_GAM_MMR_OVERLAY_CONFIG_MMR_ENABLE_MASK 0x8000000000000000UL | 2486 | #define UV1H_RH_GAM_MMR_OVERLAY_CONFIG_MMR_ENABLE_MASK 0x8000000000000000UL |
1828 | 2487 | ||
2488 | #define UVXH_RH_GAM_MMR_OVERLAY_CONFIG_MMR_BASE_SHFT 26 | ||
2489 | #define UVXH_RH_GAM_MMR_OVERLAY_CONFIG_MMR_ENABLE_SHFT 63 | ||
2490 | #define UVXH_RH_GAM_MMR_OVERLAY_CONFIG_MMR_BASE_MASK 0x00003ffffc000000UL | ||
2491 | #define UVXH_RH_GAM_MMR_OVERLAY_CONFIG_MMR_ENABLE_MASK 0x8000000000000000UL | ||
2492 | |||
1829 | #define UV2H_RH_GAM_MMR_OVERLAY_CONFIG_MMR_BASE_SHFT 26 | 2493 | #define UV2H_RH_GAM_MMR_OVERLAY_CONFIG_MMR_BASE_SHFT 26 |
1830 | #define UV2H_RH_GAM_MMR_OVERLAY_CONFIG_MMR_ENABLE_SHFT 63 | 2494 | #define UV2H_RH_GAM_MMR_OVERLAY_CONFIG_MMR_ENABLE_SHFT 63 |
1831 | #define UV2H_RH_GAM_MMR_OVERLAY_CONFIG_MMR_BASE_MASK 0x00003ffffc000000UL | 2495 | #define UV2H_RH_GAM_MMR_OVERLAY_CONFIG_MMR_BASE_MASK 0x00003ffffc000000UL |
1832 | #define UV2H_RH_GAM_MMR_OVERLAY_CONFIG_MMR_ENABLE_MASK 0x8000000000000000UL | 2496 | #define UV2H_RH_GAM_MMR_OVERLAY_CONFIG_MMR_ENABLE_MASK 0x8000000000000000UL |
1833 | 2497 | ||
2498 | #define UV3H_RH_GAM_MMR_OVERLAY_CONFIG_MMR_BASE_SHFT 26 | ||
2499 | #define UV3H_RH_GAM_MMR_OVERLAY_CONFIG_MMR_ENABLE_SHFT 63 | ||
2500 | #define UV3H_RH_GAM_MMR_OVERLAY_CONFIG_MMR_BASE_MASK 0x00003ffffc000000UL | ||
2501 | #define UV3H_RH_GAM_MMR_OVERLAY_CONFIG_MMR_ENABLE_MASK 0x8000000000000000UL | ||
2502 | |||
1834 | union uvh_rh_gam_mmr_overlay_config_mmr_u { | 2503 | union uvh_rh_gam_mmr_overlay_config_mmr_u { |
1835 | unsigned long v; | 2504 | unsigned long v; |
1836 | struct uvh_rh_gam_mmr_overlay_config_mmr_s { | 2505 | struct uvh_rh_gam_mmr_overlay_config_mmr_s { |
@@ -1846,18 +2515,30 @@ union uvh_rh_gam_mmr_overlay_config_mmr_u { | |||
1846 | unsigned long rsvd_47_62:16; | 2515 | unsigned long rsvd_47_62:16; |
1847 | unsigned long enable:1; /* RW */ | 2516 | unsigned long enable:1; /* RW */ |
1848 | } s1; | 2517 | } s1; |
2518 | struct uvxh_rh_gam_mmr_overlay_config_mmr_s { | ||
2519 | unsigned long rsvd_0_25:26; | ||
2520 | unsigned long base:20; /* RW */ | ||
2521 | unsigned long rsvd_46_62:17; | ||
2522 | unsigned long enable:1; /* RW */ | ||
2523 | } sx; | ||
1849 | struct uv2h_rh_gam_mmr_overlay_config_mmr_s { | 2524 | struct uv2h_rh_gam_mmr_overlay_config_mmr_s { |
1850 | unsigned long rsvd_0_25:26; | 2525 | unsigned long rsvd_0_25:26; |
1851 | unsigned long base:20; /* RW */ | 2526 | unsigned long base:20; /* RW */ |
1852 | unsigned long rsvd_46_62:17; | 2527 | unsigned long rsvd_46_62:17; |
1853 | unsigned long enable:1; /* RW */ | 2528 | unsigned long enable:1; /* RW */ |
1854 | } s2; | 2529 | } s2; |
2530 | struct uv3h_rh_gam_mmr_overlay_config_mmr_s { | ||
2531 | unsigned long rsvd_0_25:26; | ||
2532 | unsigned long base:20; /* RW */ | ||
2533 | unsigned long rsvd_46_62:17; | ||
2534 | unsigned long enable:1; /* RW */ | ||
2535 | } s3; | ||
1855 | }; | 2536 | }; |
1856 | 2537 | ||
1857 | /* ========================================================================= */ | 2538 | /* ========================================================================= */ |
1858 | /* UVH_RTC */ | 2539 | /* UVH_RTC */ |
1859 | /* ========================================================================= */ | 2540 | /* ========================================================================= */ |
1860 | #define UVH_RTC 0x340000UL | 2541 | #define UVH_RTC 0x340000UL |
1861 | 2542 | ||
1862 | #define UVH_RTC_REAL_TIME_CLOCK_SHFT 0 | 2543 | #define UVH_RTC_REAL_TIME_CLOCK_SHFT 0 |
1863 | #define UVH_RTC_REAL_TIME_CLOCK_MASK 0x00ffffffffffffffUL | 2544 | #define UVH_RTC_REAL_TIME_CLOCK_MASK 0x00ffffffffffffffUL |
@@ -1873,7 +2554,7 @@ union uvh_rtc_u { | |||
1873 | /* ========================================================================= */ | 2554 | /* ========================================================================= */ |
1874 | /* UVH_RTC1_INT_CONFIG */ | 2555 | /* UVH_RTC1_INT_CONFIG */ |
1875 | /* ========================================================================= */ | 2556 | /* ========================================================================= */ |
1876 | #define UVH_RTC1_INT_CONFIG 0x615c0UL | 2557 | #define UVH_RTC1_INT_CONFIG 0x615c0UL |
1877 | 2558 | ||
1878 | #define UVH_RTC1_INT_CONFIG_VECTOR_SHFT 0 | 2559 | #define UVH_RTC1_INT_CONFIG_VECTOR_SHFT 0 |
1879 | #define UVH_RTC1_INT_CONFIG_DM_SHFT 8 | 2560 | #define UVH_RTC1_INT_CONFIG_DM_SHFT 8 |
@@ -1911,8 +2592,8 @@ union uvh_rtc1_int_config_u { | |||
1911 | /* ========================================================================= */ | 2592 | /* ========================================================================= */ |
1912 | /* UVH_SCRATCH5 */ | 2593 | /* UVH_SCRATCH5 */ |
1913 | /* ========================================================================= */ | 2594 | /* ========================================================================= */ |
1914 | #define UVH_SCRATCH5 0x2d0200UL | 2595 | #define UVH_SCRATCH5 0x2d0200UL |
1915 | #define UVH_SCRATCH5_32 0x778 | 2596 | #define UVH_SCRATCH5_32 0x778 |
1916 | 2597 | ||
1917 | #define UVH_SCRATCH5_SCRATCH5_SHFT 0 | 2598 | #define UVH_SCRATCH5_SCRATCH5_SHFT 0 |
1918 | #define UVH_SCRATCH5_SCRATCH5_MASK 0xffffffffffffffffUL | 2599 | #define UVH_SCRATCH5_SCRATCH5_MASK 0xffffffffffffffffUL |
@@ -1925,79 +2606,79 @@ union uvh_scratch5_u { | |||
1925 | }; | 2606 | }; |
1926 | 2607 | ||
1927 | /* ========================================================================= */ | 2608 | /* ========================================================================= */ |
1928 | /* UV2H_EVENT_OCCURRED2 */ | 2609 | /* UVXH_EVENT_OCCURRED2 */ |
1929 | /* ========================================================================= */ | 2610 | /* ========================================================================= */ |
1930 | #define UV2H_EVENT_OCCURRED2 0x70100UL | 2611 | #define UVXH_EVENT_OCCURRED2 0x70100UL |
1931 | #define UV2H_EVENT_OCCURRED2_32 0xb68 | 2612 | #define UVXH_EVENT_OCCURRED2_32 0xb68 |
1932 | 2613 | ||
1933 | #define UV2H_EVENT_OCCURRED2_RTC_0_SHFT 0 | 2614 | #define UVXH_EVENT_OCCURRED2_RTC_0_SHFT 0 |
1934 | #define UV2H_EVENT_OCCURRED2_RTC_1_SHFT 1 | 2615 | #define UVXH_EVENT_OCCURRED2_RTC_1_SHFT 1 |
1935 | #define UV2H_EVENT_OCCURRED2_RTC_2_SHFT 2 | 2616 | #define UVXH_EVENT_OCCURRED2_RTC_2_SHFT 2 |
1936 | #define UV2H_EVENT_OCCURRED2_RTC_3_SHFT 3 | 2617 | #define UVXH_EVENT_OCCURRED2_RTC_3_SHFT 3 |
1937 | #define UV2H_EVENT_OCCURRED2_RTC_4_SHFT 4 | 2618 | #define UVXH_EVENT_OCCURRED2_RTC_4_SHFT 4 |
1938 | #define UV2H_EVENT_OCCURRED2_RTC_5_SHFT 5 | 2619 | #define UVXH_EVENT_OCCURRED2_RTC_5_SHFT 5 |
1939 | #define UV2H_EVENT_OCCURRED2_RTC_6_SHFT 6 | 2620 | #define UVXH_EVENT_OCCURRED2_RTC_6_SHFT 6 |
1940 | #define UV2H_EVENT_OCCURRED2_RTC_7_SHFT 7 | 2621 | #define UVXH_EVENT_OCCURRED2_RTC_7_SHFT 7 |
1941 | #define UV2H_EVENT_OCCURRED2_RTC_8_SHFT 8 | 2622 | #define UVXH_EVENT_OCCURRED2_RTC_8_SHFT 8 |
1942 | #define UV2H_EVENT_OCCURRED2_RTC_9_SHFT 9 | 2623 | #define UVXH_EVENT_OCCURRED2_RTC_9_SHFT 9 |
1943 | #define UV2H_EVENT_OCCURRED2_RTC_10_SHFT 10 | 2624 | #define UVXH_EVENT_OCCURRED2_RTC_10_SHFT 10 |
1944 | #define UV2H_EVENT_OCCURRED2_RTC_11_SHFT 11 | 2625 | #define UVXH_EVENT_OCCURRED2_RTC_11_SHFT 11 |
1945 | #define UV2H_EVENT_OCCURRED2_RTC_12_SHFT 12 | 2626 | #define UVXH_EVENT_OCCURRED2_RTC_12_SHFT 12 |
1946 | #define UV2H_EVENT_OCCURRED2_RTC_13_SHFT 13 | 2627 | #define UVXH_EVENT_OCCURRED2_RTC_13_SHFT 13 |
1947 | #define UV2H_EVENT_OCCURRED2_RTC_14_SHFT 14 | 2628 | #define UVXH_EVENT_OCCURRED2_RTC_14_SHFT 14 |
1948 | #define UV2H_EVENT_OCCURRED2_RTC_15_SHFT 15 | 2629 | #define UVXH_EVENT_OCCURRED2_RTC_15_SHFT 15 |
1949 | #define UV2H_EVENT_OCCURRED2_RTC_16_SHFT 16 | 2630 | #define UVXH_EVENT_OCCURRED2_RTC_16_SHFT 16 |
1950 | #define UV2H_EVENT_OCCURRED2_RTC_17_SHFT 17 | 2631 | #define UVXH_EVENT_OCCURRED2_RTC_17_SHFT 17 |
1951 | #define UV2H_EVENT_OCCURRED2_RTC_18_SHFT 18 | 2632 | #define UVXH_EVENT_OCCURRED2_RTC_18_SHFT 18 |
1952 | #define UV2H_EVENT_OCCURRED2_RTC_19_SHFT 19 | 2633 | #define UVXH_EVENT_OCCURRED2_RTC_19_SHFT 19 |
1953 | #define UV2H_EVENT_OCCURRED2_RTC_20_SHFT 20 | 2634 | #define UVXH_EVENT_OCCURRED2_RTC_20_SHFT 20 |
1954 | #define UV2H_EVENT_OCCURRED2_RTC_21_SHFT 21 | 2635 | #define UVXH_EVENT_OCCURRED2_RTC_21_SHFT 21 |
1955 | #define UV2H_EVENT_OCCURRED2_RTC_22_SHFT 22 | 2636 | #define UVXH_EVENT_OCCURRED2_RTC_22_SHFT 22 |
1956 | #define UV2H_EVENT_OCCURRED2_RTC_23_SHFT 23 | 2637 | #define UVXH_EVENT_OCCURRED2_RTC_23_SHFT 23 |
1957 | #define UV2H_EVENT_OCCURRED2_RTC_24_SHFT 24 | 2638 | #define UVXH_EVENT_OCCURRED2_RTC_24_SHFT 24 |
1958 | #define UV2H_EVENT_OCCURRED2_RTC_25_SHFT 25 | 2639 | #define UVXH_EVENT_OCCURRED2_RTC_25_SHFT 25 |
1959 | #define UV2H_EVENT_OCCURRED2_RTC_26_SHFT 26 | 2640 | #define UVXH_EVENT_OCCURRED2_RTC_26_SHFT 26 |
1960 | #define UV2H_EVENT_OCCURRED2_RTC_27_SHFT 27 | 2641 | #define UVXH_EVENT_OCCURRED2_RTC_27_SHFT 27 |
1961 | #define UV2H_EVENT_OCCURRED2_RTC_28_SHFT 28 | 2642 | #define UVXH_EVENT_OCCURRED2_RTC_28_SHFT 28 |
1962 | #define UV2H_EVENT_OCCURRED2_RTC_29_SHFT 29 | 2643 | #define UVXH_EVENT_OCCURRED2_RTC_29_SHFT 29 |
1963 | #define UV2H_EVENT_OCCURRED2_RTC_30_SHFT 30 | 2644 | #define UVXH_EVENT_OCCURRED2_RTC_30_SHFT 30 |
1964 | #define UV2H_EVENT_OCCURRED2_RTC_31_SHFT 31 | 2645 | #define UVXH_EVENT_OCCURRED2_RTC_31_SHFT 31 |
1965 | #define UV2H_EVENT_OCCURRED2_RTC_0_MASK 0x0000000000000001UL | 2646 | #define UVXH_EVENT_OCCURRED2_RTC_0_MASK 0x0000000000000001UL |
1966 | #define UV2H_EVENT_OCCURRED2_RTC_1_MASK 0x0000000000000002UL | 2647 | #define UVXH_EVENT_OCCURRED2_RTC_1_MASK 0x0000000000000002UL |
1967 | #define UV2H_EVENT_OCCURRED2_RTC_2_MASK 0x0000000000000004UL | 2648 | #define UVXH_EVENT_OCCURRED2_RTC_2_MASK 0x0000000000000004UL |
1968 | #define UV2H_EVENT_OCCURRED2_RTC_3_MASK 0x0000000000000008UL | 2649 | #define UVXH_EVENT_OCCURRED2_RTC_3_MASK 0x0000000000000008UL |
1969 | #define UV2H_EVENT_OCCURRED2_RTC_4_MASK 0x0000000000000010UL | 2650 | #define UVXH_EVENT_OCCURRED2_RTC_4_MASK 0x0000000000000010UL |
1970 | #define UV2H_EVENT_OCCURRED2_RTC_5_MASK 0x0000000000000020UL | 2651 | #define UVXH_EVENT_OCCURRED2_RTC_5_MASK 0x0000000000000020UL |
1971 | #define UV2H_EVENT_OCCURRED2_RTC_6_MASK 0x0000000000000040UL | 2652 | #define UVXH_EVENT_OCCURRED2_RTC_6_MASK 0x0000000000000040UL |
1972 | #define UV2H_EVENT_OCCURRED2_RTC_7_MASK 0x0000000000000080UL | 2653 | #define UVXH_EVENT_OCCURRED2_RTC_7_MASK 0x0000000000000080UL |
1973 | #define UV2H_EVENT_OCCURRED2_RTC_8_MASK 0x0000000000000100UL | 2654 | #define UVXH_EVENT_OCCURRED2_RTC_8_MASK 0x0000000000000100UL |
1974 | #define UV2H_EVENT_OCCURRED2_RTC_9_MASK 0x0000000000000200UL | 2655 | #define UVXH_EVENT_OCCURRED2_RTC_9_MASK 0x0000000000000200UL |
1975 | #define UV2H_EVENT_OCCURRED2_RTC_10_MASK 0x0000000000000400UL | 2656 | #define UVXH_EVENT_OCCURRED2_RTC_10_MASK 0x0000000000000400UL |
1976 | #define UV2H_EVENT_OCCURRED2_RTC_11_MASK 0x0000000000000800UL | 2657 | #define UVXH_EVENT_OCCURRED2_RTC_11_MASK 0x0000000000000800UL |
1977 | #define UV2H_EVENT_OCCURRED2_RTC_12_MASK 0x0000000000001000UL | 2658 | #define UVXH_EVENT_OCCURRED2_RTC_12_MASK 0x0000000000001000UL |
1978 | #define UV2H_EVENT_OCCURRED2_RTC_13_MASK 0x0000000000002000UL | 2659 | #define UVXH_EVENT_OCCURRED2_RTC_13_MASK 0x0000000000002000UL |
1979 | #define UV2H_EVENT_OCCURRED2_RTC_14_MASK 0x0000000000004000UL | 2660 | #define UVXH_EVENT_OCCURRED2_RTC_14_MASK 0x0000000000004000UL |
1980 | #define UV2H_EVENT_OCCURRED2_RTC_15_MASK 0x0000000000008000UL | 2661 | #define UVXH_EVENT_OCCURRED2_RTC_15_MASK 0x0000000000008000UL |
1981 | #define UV2H_EVENT_OCCURRED2_RTC_16_MASK 0x0000000000010000UL | 2662 | #define UVXH_EVENT_OCCURRED2_RTC_16_MASK 0x0000000000010000UL |
1982 | #define UV2H_EVENT_OCCURRED2_RTC_17_MASK 0x0000000000020000UL | 2663 | #define UVXH_EVENT_OCCURRED2_RTC_17_MASK 0x0000000000020000UL |
1983 | #define UV2H_EVENT_OCCURRED2_RTC_18_MASK 0x0000000000040000UL | 2664 | #define UVXH_EVENT_OCCURRED2_RTC_18_MASK 0x0000000000040000UL |
1984 | #define UV2H_EVENT_OCCURRED2_RTC_19_MASK 0x0000000000080000UL | 2665 | #define UVXH_EVENT_OCCURRED2_RTC_19_MASK 0x0000000000080000UL |
1985 | #define UV2H_EVENT_OCCURRED2_RTC_20_MASK 0x0000000000100000UL | 2666 | #define UVXH_EVENT_OCCURRED2_RTC_20_MASK 0x0000000000100000UL |
1986 | #define UV2H_EVENT_OCCURRED2_RTC_21_MASK 0x0000000000200000UL | 2667 | #define UVXH_EVENT_OCCURRED2_RTC_21_MASK 0x0000000000200000UL |
1987 | #define UV2H_EVENT_OCCURRED2_RTC_22_MASK 0x0000000000400000UL | 2668 | #define UVXH_EVENT_OCCURRED2_RTC_22_MASK 0x0000000000400000UL |
1988 | #define UV2H_EVENT_OCCURRED2_RTC_23_MASK 0x0000000000800000UL | 2669 | #define UVXH_EVENT_OCCURRED2_RTC_23_MASK 0x0000000000800000UL |
1989 | #define UV2H_EVENT_OCCURRED2_RTC_24_MASK 0x0000000001000000UL | 2670 | #define UVXH_EVENT_OCCURRED2_RTC_24_MASK 0x0000000001000000UL |
1990 | #define UV2H_EVENT_OCCURRED2_RTC_25_MASK 0x0000000002000000UL | 2671 | #define UVXH_EVENT_OCCURRED2_RTC_25_MASK 0x0000000002000000UL |
1991 | #define UV2H_EVENT_OCCURRED2_RTC_26_MASK 0x0000000004000000UL | 2672 | #define UVXH_EVENT_OCCURRED2_RTC_26_MASK 0x0000000004000000UL |
1992 | #define UV2H_EVENT_OCCURRED2_RTC_27_MASK 0x0000000008000000UL | 2673 | #define UVXH_EVENT_OCCURRED2_RTC_27_MASK 0x0000000008000000UL |
1993 | #define UV2H_EVENT_OCCURRED2_RTC_28_MASK 0x0000000010000000UL | 2674 | #define UVXH_EVENT_OCCURRED2_RTC_28_MASK 0x0000000010000000UL |
1994 | #define UV2H_EVENT_OCCURRED2_RTC_29_MASK 0x0000000020000000UL | 2675 | #define UVXH_EVENT_OCCURRED2_RTC_29_MASK 0x0000000020000000UL |
1995 | #define UV2H_EVENT_OCCURRED2_RTC_30_MASK 0x0000000040000000UL | 2676 | #define UVXH_EVENT_OCCURRED2_RTC_30_MASK 0x0000000040000000UL |
1996 | #define UV2H_EVENT_OCCURRED2_RTC_31_MASK 0x0000000080000000UL | 2677 | #define UVXH_EVENT_OCCURRED2_RTC_31_MASK 0x0000000080000000UL |
1997 | 2678 | ||
1998 | union uv2h_event_occurred2_u { | 2679 | union uvxh_event_occurred2_u { |
1999 | unsigned long v; | 2680 | unsigned long v; |
2000 | struct uv2h_event_occurred2_s { | 2681 | struct uvxh_event_occurred2_s { |
2001 | unsigned long rtc_0:1; /* RW */ | 2682 | unsigned long rtc_0:1; /* RW */ |
2002 | unsigned long rtc_1:1; /* RW */ | 2683 | unsigned long rtc_1:1; /* RW */ |
2003 | unsigned long rtc_2:1; /* RW */ | 2684 | unsigned long rtc_2:1; /* RW */ |
@@ -2031,29 +2712,46 @@ union uv2h_event_occurred2_u { | |||
2031 | unsigned long rtc_30:1; /* RW */ | 2712 | unsigned long rtc_30:1; /* RW */ |
2032 | unsigned long rtc_31:1; /* RW */ | 2713 | unsigned long rtc_31:1; /* RW */ |
2033 | unsigned long rsvd_32_63:32; | 2714 | unsigned long rsvd_32_63:32; |
2034 | } s1; | 2715 | } sx; |
2035 | }; | 2716 | }; |
2036 | 2717 | ||
2037 | /* ========================================================================= */ | 2718 | /* ========================================================================= */ |
2038 | /* UV2H_EVENT_OCCURRED2_ALIAS */ | 2719 | /* UVXH_EVENT_OCCURRED2_ALIAS */ |
2039 | /* ========================================================================= */ | 2720 | /* ========================================================================= */ |
2040 | #define UV2H_EVENT_OCCURRED2_ALIAS 0x70108UL | 2721 | #define UVXH_EVENT_OCCURRED2_ALIAS 0x70108UL |
2041 | #define UV2H_EVENT_OCCURRED2_ALIAS_32 0xb70 | 2722 | #define UVXH_EVENT_OCCURRED2_ALIAS_32 0xb70 |
2723 | |||
2042 | 2724 | ||
2043 | /* ========================================================================= */ | 2725 | /* ========================================================================= */ |
2044 | /* UV2H_LB_BAU_SB_ACTIVATION_STATUS_2 */ | 2726 | /* UVXH_LB_BAU_SB_ACTIVATION_STATUS_2 */ |
2045 | /* ========================================================================= */ | 2727 | /* ========================================================================= */ |
2046 | #define UV2H_LB_BAU_SB_ACTIVATION_STATUS_2 0x320130UL | 2728 | #define UVXH_LB_BAU_SB_ACTIVATION_STATUS_2 0x320130UL |
2047 | #define UV2H_LB_BAU_SB_ACTIVATION_STATUS_2_32 0x9f0 | 2729 | #define UV2H_LB_BAU_SB_ACTIVATION_STATUS_2 0x320130UL |
2730 | #define UV3H_LB_BAU_SB_ACTIVATION_STATUS_2 0x320130UL | ||
2731 | #define UVXH_LB_BAU_SB_ACTIVATION_STATUS_2_32 0x9f0 | ||
2732 | #define UV2H_LB_BAU_SB_ACTIVATION_STATUS_2_32 0x320130UL | ||
2733 | #define UV3H_LB_BAU_SB_ACTIVATION_STATUS_2_32 0x320130UL | ||
2734 | |||
2735 | #define UVXH_LB_BAU_SB_ACTIVATION_STATUS_2_AUX_ERROR_SHFT 0 | ||
2736 | #define UVXH_LB_BAU_SB_ACTIVATION_STATUS_2_AUX_ERROR_MASK 0xffffffffffffffffUL | ||
2048 | 2737 | ||
2049 | #define UV2H_LB_BAU_SB_ACTIVATION_STATUS_2_AUX_ERROR_SHFT 0 | 2738 | #define UV2H_LB_BAU_SB_ACTIVATION_STATUS_2_AUX_ERROR_SHFT 0 |
2050 | #define UV2H_LB_BAU_SB_ACTIVATION_STATUS_2_AUX_ERROR_MASK 0xffffffffffffffffUL | 2739 | #define UV2H_LB_BAU_SB_ACTIVATION_STATUS_2_AUX_ERROR_MASK 0xffffffffffffffffUL |
2051 | 2740 | ||
2052 | union uv2h_lb_bau_sb_activation_status_2_u { | 2741 | #define UV3H_LB_BAU_SB_ACTIVATION_STATUS_2_AUX_ERROR_SHFT 0 |
2742 | #define UV3H_LB_BAU_SB_ACTIVATION_STATUS_2_AUX_ERROR_MASK 0xffffffffffffffffUL | ||
2743 | |||
2744 | union uvxh_lb_bau_sb_activation_status_2_u { | ||
2053 | unsigned long v; | 2745 | unsigned long v; |
2746 | struct uvxh_lb_bau_sb_activation_status_2_s { | ||
2747 | unsigned long aux_error:64; /* RW */ | ||
2748 | } sx; | ||
2054 | struct uv2h_lb_bau_sb_activation_status_2_s { | 2749 | struct uv2h_lb_bau_sb_activation_status_2_s { |
2055 | unsigned long aux_error:64; /* RW */ | 2750 | unsigned long aux_error:64; /* RW */ |
2056 | } s1; | 2751 | } s2; |
2752 | struct uv3h_lb_bau_sb_activation_status_2_s { | ||
2753 | unsigned long aux_error:64; /* RW */ | ||
2754 | } s3; | ||
2057 | }; | 2755 | }; |
2058 | 2756 | ||
2059 | /* ========================================================================= */ | 2757 | /* ========================================================================= */ |
@@ -2073,5 +2771,87 @@ union uv1h_lb_target_physical_apic_id_mask_u { | |||
2073 | } s1; | 2771 | } s1; |
2074 | }; | 2772 | }; |
2075 | 2773 | ||
2774 | /* ========================================================================= */ | ||
2775 | /* UV3H_RH_GAM_MMIOH_OVERLAY_CONFIG0_MMR */ | ||
2776 | /* ========================================================================= */ | ||
2777 | #define UV3H_RH_GAM_MMIOH_OVERLAY_CONFIG0_MMR 0x1603000UL | ||
2778 | |||
2779 | #define UV3H_RH_GAM_MMIOH_OVERLAY_CONFIG0_MMR_BASE_SHFT 26 | ||
2780 | #define UV3H_RH_GAM_MMIOH_OVERLAY_CONFIG0_MMR_M_IO_SHFT 46 | ||
2781 | #define UV3H_RH_GAM_MMIOH_OVERLAY_CONFIG0_MMR_ENABLE_SHFT 63 | ||
2782 | #define UV3H_RH_GAM_MMIOH_OVERLAY_CONFIG0_MMR_BASE_MASK 0x00003ffffc000000UL | ||
2783 | #define UV3H_RH_GAM_MMIOH_OVERLAY_CONFIG0_MMR_M_IO_MASK 0x000fc00000000000UL | ||
2784 | #define UV3H_RH_GAM_MMIOH_OVERLAY_CONFIG0_MMR_ENABLE_MASK 0x8000000000000000UL | ||
2785 | |||
2786 | union uv3h_rh_gam_mmioh_overlay_config0_mmr_u { | ||
2787 | unsigned long v; | ||
2788 | struct uv3h_rh_gam_mmioh_overlay_config0_mmr_s { | ||
2789 | unsigned long rsvd_0_25:26; | ||
2790 | unsigned long base:20; /* RW */ | ||
2791 | unsigned long m_io:6; /* RW */ | ||
2792 | unsigned long n_io:4; | ||
2793 | unsigned long rsvd_56_62:7; | ||
2794 | unsigned long enable:1; /* RW */ | ||
2795 | } s3; | ||
2796 | }; | ||
2797 | |||
2798 | /* ========================================================================= */ | ||
2799 | /* UV3H_RH_GAM_MMIOH_OVERLAY_CONFIG1_MMR */ | ||
2800 | /* ========================================================================= */ | ||
2801 | #define UV3H_RH_GAM_MMIOH_OVERLAY_CONFIG1_MMR 0x1604000UL | ||
2802 | |||
2803 | #define UV3H_RH_GAM_MMIOH_OVERLAY_CONFIG1_MMR_BASE_SHFT 26 | ||
2804 | #define UV3H_RH_GAM_MMIOH_OVERLAY_CONFIG1_MMR_M_IO_SHFT 46 | ||
2805 | #define UV3H_RH_GAM_MMIOH_OVERLAY_CONFIG1_MMR_ENABLE_SHFT 63 | ||
2806 | #define UV3H_RH_GAM_MMIOH_OVERLAY_CONFIG1_MMR_BASE_MASK 0x00003ffffc000000UL | ||
2807 | #define UV3H_RH_GAM_MMIOH_OVERLAY_CONFIG1_MMR_M_IO_MASK 0x000fc00000000000UL | ||
2808 | #define UV3H_RH_GAM_MMIOH_OVERLAY_CONFIG1_MMR_ENABLE_MASK 0x8000000000000000UL | ||
2809 | |||
2810 | union uv3h_rh_gam_mmioh_overlay_config1_mmr_u { | ||
2811 | unsigned long v; | ||
2812 | struct uv3h_rh_gam_mmioh_overlay_config1_mmr_s { | ||
2813 | unsigned long rsvd_0_25:26; | ||
2814 | unsigned long base:20; /* RW */ | ||
2815 | unsigned long m_io:6; /* RW */ | ||
2816 | unsigned long n_io:4; | ||
2817 | unsigned long rsvd_56_62:7; | ||
2818 | unsigned long enable:1; /* RW */ | ||
2819 | } s3; | ||
2820 | }; | ||
2821 | |||
2822 | /* ========================================================================= */ | ||
2823 | /* UV3H_RH_GAM_MMIOH_REDIRECT_CONFIG0_MMR */ | ||
2824 | /* ========================================================================= */ | ||
2825 | #define UV3H_RH_GAM_MMIOH_REDIRECT_CONFIG0_MMR 0x1603800UL | ||
2826 | #define UV3H_RH_GAM_MMIOH_REDIRECT_CONFIG0_MMR_DEPTH 128 | ||
2827 | |||
2828 | #define UV3H_RH_GAM_MMIOH_REDIRECT_CONFIG0_MMR_NASID_SHFT 0 | ||
2829 | #define UV3H_RH_GAM_MMIOH_REDIRECT_CONFIG0_MMR_NASID_MASK 0x0000000000007fffUL | ||
2830 | |||
2831 | union uv3h_rh_gam_mmioh_redirect_config0_mmr_u { | ||
2832 | unsigned long v; | ||
2833 | struct uv3h_rh_gam_mmioh_redirect_config0_mmr_s { | ||
2834 | unsigned long nasid:15; /* RW */ | ||
2835 | unsigned long rsvd_15_63:49; | ||
2836 | } s3; | ||
2837 | }; | ||
2838 | |||
2839 | /* ========================================================================= */ | ||
2840 | /* UV3H_RH_GAM_MMIOH_REDIRECT_CONFIG1_MMR */ | ||
2841 | /* ========================================================================= */ | ||
2842 | #define UV3H_RH_GAM_MMIOH_REDIRECT_CONFIG1_MMR 0x1604800UL | ||
2843 | #define UV3H_RH_GAM_MMIOH_REDIRECT_CONFIG1_MMR_DEPTH 128 | ||
2844 | |||
2845 | #define UV3H_RH_GAM_MMIOH_REDIRECT_CONFIG1_MMR_NASID_SHFT 0 | ||
2846 | #define UV3H_RH_GAM_MMIOH_REDIRECT_CONFIG1_MMR_NASID_MASK 0x0000000000007fffUL | ||
2847 | |||
2848 | union uv3h_rh_gam_mmioh_redirect_config1_mmr_u { | ||
2849 | unsigned long v; | ||
2850 | struct uv3h_rh_gam_mmioh_redirect_config1_mmr_s { | ||
2851 | unsigned long nasid:15; /* RW */ | ||
2852 | unsigned long rsvd_15_63:49; | ||
2853 | } s3; | ||
2854 | }; | ||
2855 | |||
2076 | 2856 | ||
2077 | #endif /* _ASM_X86_UV_UV_MMRS_H */ | 2857 | #endif /* _ASM_X86_UV_UV_MMRS_H */ |
diff --git a/arch/x86/include/asm/x86_init.h b/arch/x86/include/asm/x86_init.h index 57693498519c..7669941cc9d2 100644 --- a/arch/x86/include/asm/x86_init.h +++ b/arch/x86/include/asm/x86_init.h | |||
@@ -181,19 +181,38 @@ struct x86_platform_ops { | |||
181 | }; | 181 | }; |
182 | 182 | ||
183 | struct pci_dev; | 183 | struct pci_dev; |
184 | struct msi_msg; | ||
184 | 185 | ||
185 | struct x86_msi_ops { | 186 | struct x86_msi_ops { |
186 | int (*setup_msi_irqs)(struct pci_dev *dev, int nvec, int type); | 187 | int (*setup_msi_irqs)(struct pci_dev *dev, int nvec, int type); |
188 | void (*compose_msi_msg)(struct pci_dev *dev, unsigned int irq, | ||
189 | unsigned int dest, struct msi_msg *msg, | ||
190 | u8 hpet_id); | ||
187 | void (*teardown_msi_irq)(unsigned int irq); | 191 | void (*teardown_msi_irq)(unsigned int irq); |
188 | void (*teardown_msi_irqs)(struct pci_dev *dev); | 192 | void (*teardown_msi_irqs)(struct pci_dev *dev); |
189 | void (*restore_msi_irqs)(struct pci_dev *dev, int irq); | 193 | void (*restore_msi_irqs)(struct pci_dev *dev, int irq); |
194 | int (*setup_hpet_msi)(unsigned int irq, unsigned int id); | ||
190 | }; | 195 | }; |
191 | 196 | ||
197 | struct IO_APIC_route_entry; | ||
198 | struct io_apic_irq_attr; | ||
199 | struct irq_data; | ||
200 | struct cpumask; | ||
201 | |||
192 | struct x86_io_apic_ops { | 202 | struct x86_io_apic_ops { |
193 | void (*init) (void); | 203 | void (*init) (void); |
194 | unsigned int (*read) (unsigned int apic, unsigned int reg); | 204 | unsigned int (*read) (unsigned int apic, unsigned int reg); |
195 | void (*write) (unsigned int apic, unsigned int reg, unsigned int value); | 205 | void (*write) (unsigned int apic, unsigned int reg, unsigned int value); |
196 | void (*modify)(unsigned int apic, unsigned int reg, unsigned int value); | 206 | void (*modify) (unsigned int apic, unsigned int reg, unsigned int value); |
207 | void (*disable)(void); | ||
208 | void (*print_entries)(unsigned int apic, unsigned int nr_entries); | ||
209 | int (*set_affinity)(struct irq_data *data, | ||
210 | const struct cpumask *mask, | ||
211 | bool force); | ||
212 | int (*setup_entry)(int irq, struct IO_APIC_route_entry *entry, | ||
213 | unsigned int destination, int vector, | ||
214 | struct io_apic_irq_attr *attr); | ||
215 | void (*eoi_ioapic_pin)(int apic, int pin, int vector); | ||
197 | }; | 216 | }; |
198 | 217 | ||
199 | extern struct x86_init_ops x86_init; | 218 | extern struct x86_init_ops x86_init; |
diff --git a/arch/x86/include/asm/xor.h b/arch/x86/include/asm/xor.h index f8fde90bc45e..d8829751b3f8 100644 --- a/arch/x86/include/asm/xor.h +++ b/arch/x86/include/asm/xor.h | |||
@@ -1,10 +1,499 @@ | |||
1 | #ifdef CONFIG_KMEMCHECK | 1 | #ifdef CONFIG_KMEMCHECK |
2 | /* kmemcheck doesn't handle MMX/SSE/SSE2 instructions */ | 2 | /* kmemcheck doesn't handle MMX/SSE/SSE2 instructions */ |
3 | # include <asm-generic/xor.h> | 3 | # include <asm-generic/xor.h> |
4 | #elif !defined(_ASM_X86_XOR_H) | ||
5 | #define _ASM_X86_XOR_H | ||
6 | |||
7 | /* | ||
8 | * Optimized RAID-5 checksumming functions for SSE. | ||
9 | * | ||
10 | * This program is free software; you can redistribute it and/or modify | ||
11 | * it under the terms of the GNU General Public License as published by | ||
12 | * the Free Software Foundation; either version 2, or (at your option) | ||
13 | * any later version. | ||
14 | * | ||
15 | * You should have received a copy of the GNU General Public License | ||
16 | * (for example /usr/src/linux/COPYING); if not, write to the Free | ||
17 | * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | ||
18 | */ | ||
19 | |||
20 | /* | ||
21 | * Cache avoiding checksumming functions utilizing KNI instructions | ||
22 | * Copyright (C) 1999 Zach Brown (with obvious credit due Ingo) | ||
23 | */ | ||
24 | |||
25 | /* | ||
26 | * Based on | ||
27 | * High-speed RAID5 checksumming functions utilizing SSE instructions. | ||
28 | * Copyright (C) 1998 Ingo Molnar. | ||
29 | */ | ||
30 | |||
31 | /* | ||
32 | * x86-64 changes / gcc fixes from Andi Kleen. | ||
33 | * Copyright 2002 Andi Kleen, SuSE Labs. | ||
34 | * | ||
35 | * This hasn't been optimized for the hammer yet, but there are likely | ||
36 | * no advantages to be gotten from x86-64 here anyways. | ||
37 | */ | ||
38 | |||
39 | #include <asm/i387.h> | ||
40 | |||
41 | #ifdef CONFIG_X86_32 | ||
42 | /* reduce register pressure */ | ||
43 | # define XOR_CONSTANT_CONSTRAINT "i" | ||
4 | #else | 44 | #else |
45 | # define XOR_CONSTANT_CONSTRAINT "re" | ||
46 | #endif | ||
47 | |||
48 | #define OFFS(x) "16*("#x")" | ||
49 | #define PF_OFFS(x) "256+16*("#x")" | ||
50 | #define PF0(x) " prefetchnta "PF_OFFS(x)"(%[p1]) ;\n" | ||
51 | #define LD(x, y) " movaps "OFFS(x)"(%[p1]), %%xmm"#y" ;\n" | ||
52 | #define ST(x, y) " movaps %%xmm"#y", "OFFS(x)"(%[p1]) ;\n" | ||
53 | #define PF1(x) " prefetchnta "PF_OFFS(x)"(%[p2]) ;\n" | ||
54 | #define PF2(x) " prefetchnta "PF_OFFS(x)"(%[p3]) ;\n" | ||
55 | #define PF3(x) " prefetchnta "PF_OFFS(x)"(%[p4]) ;\n" | ||
56 | #define PF4(x) " prefetchnta "PF_OFFS(x)"(%[p5]) ;\n" | ||
57 | #define XO1(x, y) " xorps "OFFS(x)"(%[p2]), %%xmm"#y" ;\n" | ||
58 | #define XO2(x, y) " xorps "OFFS(x)"(%[p3]), %%xmm"#y" ;\n" | ||
59 | #define XO3(x, y) " xorps "OFFS(x)"(%[p4]), %%xmm"#y" ;\n" | ||
60 | #define XO4(x, y) " xorps "OFFS(x)"(%[p5]), %%xmm"#y" ;\n" | ||
61 | #define NOP(x) | ||
62 | |||
63 | #define BLK64(pf, op, i) \ | ||
64 | pf(i) \ | ||
65 | op(i, 0) \ | ||
66 | op(i + 1, 1) \ | ||
67 | op(i + 2, 2) \ | ||
68 | op(i + 3, 3) | ||
69 | |||
70 | static void | ||
71 | xor_sse_2(unsigned long bytes, unsigned long *p1, unsigned long *p2) | ||
72 | { | ||
73 | unsigned long lines = bytes >> 8; | ||
74 | |||
75 | kernel_fpu_begin(); | ||
76 | |||
77 | asm volatile( | ||
78 | #undef BLOCK | ||
79 | #define BLOCK(i) \ | ||
80 | LD(i, 0) \ | ||
81 | LD(i + 1, 1) \ | ||
82 | PF1(i) \ | ||
83 | PF1(i + 2) \ | ||
84 | LD(i + 2, 2) \ | ||
85 | LD(i + 3, 3) \ | ||
86 | PF0(i + 4) \ | ||
87 | PF0(i + 6) \ | ||
88 | XO1(i, 0) \ | ||
89 | XO1(i + 1, 1) \ | ||
90 | XO1(i + 2, 2) \ | ||
91 | XO1(i + 3, 3) \ | ||
92 | ST(i, 0) \ | ||
93 | ST(i + 1, 1) \ | ||
94 | ST(i + 2, 2) \ | ||
95 | ST(i + 3, 3) \ | ||
96 | |||
97 | |||
98 | PF0(0) | ||
99 | PF0(2) | ||
100 | |||
101 | " .align 32 ;\n" | ||
102 | " 1: ;\n" | ||
103 | |||
104 | BLOCK(0) | ||
105 | BLOCK(4) | ||
106 | BLOCK(8) | ||
107 | BLOCK(12) | ||
108 | |||
109 | " add %[inc], %[p1] ;\n" | ||
110 | " add %[inc], %[p2] ;\n" | ||
111 | " dec %[cnt] ;\n" | ||
112 | " jnz 1b ;\n" | ||
113 | : [cnt] "+r" (lines), | ||
114 | [p1] "+r" (p1), [p2] "+r" (p2) | ||
115 | : [inc] XOR_CONSTANT_CONSTRAINT (256UL) | ||
116 | : "memory"); | ||
117 | |||
118 | kernel_fpu_end(); | ||
119 | } | ||
120 | |||
121 | static void | ||
122 | xor_sse_2_pf64(unsigned long bytes, unsigned long *p1, unsigned long *p2) | ||
123 | { | ||
124 | unsigned long lines = bytes >> 8; | ||
125 | |||
126 | kernel_fpu_begin(); | ||
127 | |||
128 | asm volatile( | ||
129 | #undef BLOCK | ||
130 | #define BLOCK(i) \ | ||
131 | BLK64(PF0, LD, i) \ | ||
132 | BLK64(PF1, XO1, i) \ | ||
133 | BLK64(NOP, ST, i) \ | ||
134 | |||
135 | " .align 32 ;\n" | ||
136 | " 1: ;\n" | ||
137 | |||
138 | BLOCK(0) | ||
139 | BLOCK(4) | ||
140 | BLOCK(8) | ||
141 | BLOCK(12) | ||
142 | |||
143 | " add %[inc], %[p1] ;\n" | ||
144 | " add %[inc], %[p2] ;\n" | ||
145 | " dec %[cnt] ;\n" | ||
146 | " jnz 1b ;\n" | ||
147 | : [cnt] "+r" (lines), | ||
148 | [p1] "+r" (p1), [p2] "+r" (p2) | ||
149 | : [inc] XOR_CONSTANT_CONSTRAINT (256UL) | ||
150 | : "memory"); | ||
151 | |||
152 | kernel_fpu_end(); | ||
153 | } | ||
154 | |||
155 | static void | ||
156 | xor_sse_3(unsigned long bytes, unsigned long *p1, unsigned long *p2, | ||
157 | unsigned long *p3) | ||
158 | { | ||
159 | unsigned long lines = bytes >> 8; | ||
160 | |||
161 | kernel_fpu_begin(); | ||
162 | |||
163 | asm volatile( | ||
164 | #undef BLOCK | ||
165 | #define BLOCK(i) \ | ||
166 | PF1(i) \ | ||
167 | PF1(i + 2) \ | ||
168 | LD(i, 0) \ | ||
169 | LD(i + 1, 1) \ | ||
170 | LD(i + 2, 2) \ | ||
171 | LD(i + 3, 3) \ | ||
172 | PF2(i) \ | ||
173 | PF2(i + 2) \ | ||
174 | PF0(i + 4) \ | ||
175 | PF0(i + 6) \ | ||
176 | XO1(i, 0) \ | ||
177 | XO1(i + 1, 1) \ | ||
178 | XO1(i + 2, 2) \ | ||
179 | XO1(i + 3, 3) \ | ||
180 | XO2(i, 0) \ | ||
181 | XO2(i + 1, 1) \ | ||
182 | XO2(i + 2, 2) \ | ||
183 | XO2(i + 3, 3) \ | ||
184 | ST(i, 0) \ | ||
185 | ST(i + 1, 1) \ | ||
186 | ST(i + 2, 2) \ | ||
187 | ST(i + 3, 3) \ | ||
188 | |||
189 | |||
190 | PF0(0) | ||
191 | PF0(2) | ||
192 | |||
193 | " .align 32 ;\n" | ||
194 | " 1: ;\n" | ||
195 | |||
196 | BLOCK(0) | ||
197 | BLOCK(4) | ||
198 | BLOCK(8) | ||
199 | BLOCK(12) | ||
200 | |||
201 | " add %[inc], %[p1] ;\n" | ||
202 | " add %[inc], %[p2] ;\n" | ||
203 | " add %[inc], %[p3] ;\n" | ||
204 | " dec %[cnt] ;\n" | ||
205 | " jnz 1b ;\n" | ||
206 | : [cnt] "+r" (lines), | ||
207 | [p1] "+r" (p1), [p2] "+r" (p2), [p3] "+r" (p3) | ||
208 | : [inc] XOR_CONSTANT_CONSTRAINT (256UL) | ||
209 | : "memory"); | ||
210 | |||
211 | kernel_fpu_end(); | ||
212 | } | ||
213 | |||
214 | static void | ||
215 | xor_sse_3_pf64(unsigned long bytes, unsigned long *p1, unsigned long *p2, | ||
216 | unsigned long *p3) | ||
217 | { | ||
218 | unsigned long lines = bytes >> 8; | ||
219 | |||
220 | kernel_fpu_begin(); | ||
221 | |||
222 | asm volatile( | ||
223 | #undef BLOCK | ||
224 | #define BLOCK(i) \ | ||
225 | BLK64(PF0, LD, i) \ | ||
226 | BLK64(PF1, XO1, i) \ | ||
227 | BLK64(PF2, XO2, i) \ | ||
228 | BLK64(NOP, ST, i) \ | ||
229 | |||
230 | " .align 32 ;\n" | ||
231 | " 1: ;\n" | ||
232 | |||
233 | BLOCK(0) | ||
234 | BLOCK(4) | ||
235 | BLOCK(8) | ||
236 | BLOCK(12) | ||
237 | |||
238 | " add %[inc], %[p1] ;\n" | ||
239 | " add %[inc], %[p2] ;\n" | ||
240 | " add %[inc], %[p3] ;\n" | ||
241 | " dec %[cnt] ;\n" | ||
242 | " jnz 1b ;\n" | ||
243 | : [cnt] "+r" (lines), | ||
244 | [p1] "+r" (p1), [p2] "+r" (p2), [p3] "+r" (p3) | ||
245 | : [inc] XOR_CONSTANT_CONSTRAINT (256UL) | ||
246 | : "memory"); | ||
247 | |||
248 | kernel_fpu_end(); | ||
249 | } | ||
250 | |||
251 | static void | ||
252 | xor_sse_4(unsigned long bytes, unsigned long *p1, unsigned long *p2, | ||
253 | unsigned long *p3, unsigned long *p4) | ||
254 | { | ||
255 | unsigned long lines = bytes >> 8; | ||
256 | |||
257 | kernel_fpu_begin(); | ||
258 | |||
259 | asm volatile( | ||
260 | #undef BLOCK | ||
261 | #define BLOCK(i) \ | ||
262 | PF1(i) \ | ||
263 | PF1(i + 2) \ | ||
264 | LD(i, 0) \ | ||
265 | LD(i + 1, 1) \ | ||
266 | LD(i + 2, 2) \ | ||
267 | LD(i + 3, 3) \ | ||
268 | PF2(i) \ | ||
269 | PF2(i + 2) \ | ||
270 | XO1(i, 0) \ | ||
271 | XO1(i + 1, 1) \ | ||
272 | XO1(i + 2, 2) \ | ||
273 | XO1(i + 3, 3) \ | ||
274 | PF3(i) \ | ||
275 | PF3(i + 2) \ | ||
276 | PF0(i + 4) \ | ||
277 | PF0(i + 6) \ | ||
278 | XO2(i, 0) \ | ||
279 | XO2(i + 1, 1) \ | ||
280 | XO2(i + 2, 2) \ | ||
281 | XO2(i + 3, 3) \ | ||
282 | XO3(i, 0) \ | ||
283 | XO3(i + 1, 1) \ | ||
284 | XO3(i + 2, 2) \ | ||
285 | XO3(i + 3, 3) \ | ||
286 | ST(i, 0) \ | ||
287 | ST(i + 1, 1) \ | ||
288 | ST(i + 2, 2) \ | ||
289 | ST(i + 3, 3) \ | ||
290 | |||
291 | |||
292 | PF0(0) | ||
293 | PF0(2) | ||
294 | |||
295 | " .align 32 ;\n" | ||
296 | " 1: ;\n" | ||
297 | |||
298 | BLOCK(0) | ||
299 | BLOCK(4) | ||
300 | BLOCK(8) | ||
301 | BLOCK(12) | ||
302 | |||
303 | " add %[inc], %[p1] ;\n" | ||
304 | " add %[inc], %[p2] ;\n" | ||
305 | " add %[inc], %[p3] ;\n" | ||
306 | " add %[inc], %[p4] ;\n" | ||
307 | " dec %[cnt] ;\n" | ||
308 | " jnz 1b ;\n" | ||
309 | : [cnt] "+r" (lines), [p1] "+r" (p1), | ||
310 | [p2] "+r" (p2), [p3] "+r" (p3), [p4] "+r" (p4) | ||
311 | : [inc] XOR_CONSTANT_CONSTRAINT (256UL) | ||
312 | : "memory"); | ||
313 | |||
314 | kernel_fpu_end(); | ||
315 | } | ||
316 | |||
317 | static void | ||
318 | xor_sse_4_pf64(unsigned long bytes, unsigned long *p1, unsigned long *p2, | ||
319 | unsigned long *p3, unsigned long *p4) | ||
320 | { | ||
321 | unsigned long lines = bytes >> 8; | ||
322 | |||
323 | kernel_fpu_begin(); | ||
324 | |||
325 | asm volatile( | ||
326 | #undef BLOCK | ||
327 | #define BLOCK(i) \ | ||
328 | BLK64(PF0, LD, i) \ | ||
329 | BLK64(PF1, XO1, i) \ | ||
330 | BLK64(PF2, XO2, i) \ | ||
331 | BLK64(PF3, XO3, i) \ | ||
332 | BLK64(NOP, ST, i) \ | ||
333 | |||
334 | " .align 32 ;\n" | ||
335 | " 1: ;\n" | ||
336 | |||
337 | BLOCK(0) | ||
338 | BLOCK(4) | ||
339 | BLOCK(8) | ||
340 | BLOCK(12) | ||
341 | |||
342 | " add %[inc], %[p1] ;\n" | ||
343 | " add %[inc], %[p2] ;\n" | ||
344 | " add %[inc], %[p3] ;\n" | ||
345 | " add %[inc], %[p4] ;\n" | ||
346 | " dec %[cnt] ;\n" | ||
347 | " jnz 1b ;\n" | ||
348 | : [cnt] "+r" (lines), [p1] "+r" (p1), | ||
349 | [p2] "+r" (p2), [p3] "+r" (p3), [p4] "+r" (p4) | ||
350 | : [inc] XOR_CONSTANT_CONSTRAINT (256UL) | ||
351 | : "memory"); | ||
352 | |||
353 | kernel_fpu_end(); | ||
354 | } | ||
355 | |||
356 | static void | ||
357 | xor_sse_5(unsigned long bytes, unsigned long *p1, unsigned long *p2, | ||
358 | unsigned long *p3, unsigned long *p4, unsigned long *p5) | ||
359 | { | ||
360 | unsigned long lines = bytes >> 8; | ||
361 | |||
362 | kernel_fpu_begin(); | ||
363 | |||
364 | asm volatile( | ||
365 | #undef BLOCK | ||
366 | #define BLOCK(i) \ | ||
367 | PF1(i) \ | ||
368 | PF1(i + 2) \ | ||
369 | LD(i, 0) \ | ||
370 | LD(i + 1, 1) \ | ||
371 | LD(i + 2, 2) \ | ||
372 | LD(i + 3, 3) \ | ||
373 | PF2(i) \ | ||
374 | PF2(i + 2) \ | ||
375 | XO1(i, 0) \ | ||
376 | XO1(i + 1, 1) \ | ||
377 | XO1(i + 2, 2) \ | ||
378 | XO1(i + 3, 3) \ | ||
379 | PF3(i) \ | ||
380 | PF3(i + 2) \ | ||
381 | XO2(i, 0) \ | ||
382 | XO2(i + 1, 1) \ | ||
383 | XO2(i + 2, 2) \ | ||
384 | XO2(i + 3, 3) \ | ||
385 | PF4(i) \ | ||
386 | PF4(i + 2) \ | ||
387 | PF0(i + 4) \ | ||
388 | PF0(i + 6) \ | ||
389 | XO3(i, 0) \ | ||
390 | XO3(i + 1, 1) \ | ||
391 | XO3(i + 2, 2) \ | ||
392 | XO3(i + 3, 3) \ | ||
393 | XO4(i, 0) \ | ||
394 | XO4(i + 1, 1) \ | ||
395 | XO4(i + 2, 2) \ | ||
396 | XO4(i + 3, 3) \ | ||
397 | ST(i, 0) \ | ||
398 | ST(i + 1, 1) \ | ||
399 | ST(i + 2, 2) \ | ||
400 | ST(i + 3, 3) \ | ||
401 | |||
402 | |||
403 | PF0(0) | ||
404 | PF0(2) | ||
405 | |||
406 | " .align 32 ;\n" | ||
407 | " 1: ;\n" | ||
408 | |||
409 | BLOCK(0) | ||
410 | BLOCK(4) | ||
411 | BLOCK(8) | ||
412 | BLOCK(12) | ||
413 | |||
414 | " add %[inc], %[p1] ;\n" | ||
415 | " add %[inc], %[p2] ;\n" | ||
416 | " add %[inc], %[p3] ;\n" | ||
417 | " add %[inc], %[p4] ;\n" | ||
418 | " add %[inc], %[p5] ;\n" | ||
419 | " dec %[cnt] ;\n" | ||
420 | " jnz 1b ;\n" | ||
421 | : [cnt] "+r" (lines), [p1] "+r" (p1), [p2] "+r" (p2), | ||
422 | [p3] "+r" (p3), [p4] "+r" (p4), [p5] "+r" (p5) | ||
423 | : [inc] XOR_CONSTANT_CONSTRAINT (256UL) | ||
424 | : "memory"); | ||
425 | |||
426 | kernel_fpu_end(); | ||
427 | } | ||
428 | |||
429 | static void | ||
430 | xor_sse_5_pf64(unsigned long bytes, unsigned long *p1, unsigned long *p2, | ||
431 | unsigned long *p3, unsigned long *p4, unsigned long *p5) | ||
432 | { | ||
433 | unsigned long lines = bytes >> 8; | ||
434 | |||
435 | kernel_fpu_begin(); | ||
436 | |||
437 | asm volatile( | ||
438 | #undef BLOCK | ||
439 | #define BLOCK(i) \ | ||
440 | BLK64(PF0, LD, i) \ | ||
441 | BLK64(PF1, XO1, i) \ | ||
442 | BLK64(PF2, XO2, i) \ | ||
443 | BLK64(PF3, XO3, i) \ | ||
444 | BLK64(PF4, XO4, i) \ | ||
445 | BLK64(NOP, ST, i) \ | ||
446 | |||
447 | " .align 32 ;\n" | ||
448 | " 1: ;\n" | ||
449 | |||
450 | BLOCK(0) | ||
451 | BLOCK(4) | ||
452 | BLOCK(8) | ||
453 | BLOCK(12) | ||
454 | |||
455 | " add %[inc], %[p1] ;\n" | ||
456 | " add %[inc], %[p2] ;\n" | ||
457 | " add %[inc], %[p3] ;\n" | ||
458 | " add %[inc], %[p4] ;\n" | ||
459 | " add %[inc], %[p5] ;\n" | ||
460 | " dec %[cnt] ;\n" | ||
461 | " jnz 1b ;\n" | ||
462 | : [cnt] "+r" (lines), [p1] "+r" (p1), [p2] "+r" (p2), | ||
463 | [p3] "+r" (p3), [p4] "+r" (p4), [p5] "+r" (p5) | ||
464 | : [inc] XOR_CONSTANT_CONSTRAINT (256UL) | ||
465 | : "memory"); | ||
466 | |||
467 | kernel_fpu_end(); | ||
468 | } | ||
469 | |||
470 | static struct xor_block_template xor_block_sse_pf64 = { | ||
471 | .name = "prefetch64-sse", | ||
472 | .do_2 = xor_sse_2_pf64, | ||
473 | .do_3 = xor_sse_3_pf64, | ||
474 | .do_4 = xor_sse_4_pf64, | ||
475 | .do_5 = xor_sse_5_pf64, | ||
476 | }; | ||
477 | |||
478 | #undef LD | ||
479 | #undef XO1 | ||
480 | #undef XO2 | ||
481 | #undef XO3 | ||
482 | #undef XO4 | ||
483 | #undef ST | ||
484 | #undef NOP | ||
485 | #undef BLK64 | ||
486 | #undef BLOCK | ||
487 | |||
488 | #undef XOR_CONSTANT_CONSTRAINT | ||
489 | |||
5 | #ifdef CONFIG_X86_32 | 490 | #ifdef CONFIG_X86_32 |
6 | # include <asm/xor_32.h> | 491 | # include <asm/xor_32.h> |
7 | #else | 492 | #else |
8 | # include <asm/xor_64.h> | 493 | # include <asm/xor_64.h> |
9 | #endif | 494 | #endif |
10 | #endif | 495 | |
496 | #define XOR_SELECT_TEMPLATE(FASTEST) \ | ||
497 | AVX_SELECT(FASTEST) | ||
498 | |||
499 | #endif /* _ASM_X86_XOR_H */ | ||
diff --git a/arch/x86/include/asm/xor_32.h b/arch/x86/include/asm/xor_32.h index f79cb7ec0e06..ce05722e3c68 100644 --- a/arch/x86/include/asm/xor_32.h +++ b/arch/x86/include/asm/xor_32.h | |||
@@ -2,7 +2,7 @@ | |||
2 | #define _ASM_X86_XOR_32_H | 2 | #define _ASM_X86_XOR_32_H |
3 | 3 | ||
4 | /* | 4 | /* |
5 | * Optimized RAID-5 checksumming functions for MMX and SSE. | 5 | * Optimized RAID-5 checksumming functions for MMX. |
6 | * | 6 | * |
7 | * This program is free software; you can redistribute it and/or modify | 7 | * This program is free software; you can redistribute it and/or modify |
8 | * it under the terms of the GNU General Public License as published by | 8 | * it under the terms of the GNU General Public License as published by |
@@ -529,290 +529,6 @@ static struct xor_block_template xor_block_p5_mmx = { | |||
529 | .do_5 = xor_p5_mmx_5, | 529 | .do_5 = xor_p5_mmx_5, |
530 | }; | 530 | }; |
531 | 531 | ||
532 | /* | ||
533 | * Cache avoiding checksumming functions utilizing KNI instructions | ||
534 | * Copyright (C) 1999 Zach Brown (with obvious credit due Ingo) | ||
535 | */ | ||
536 | |||
537 | #define OFFS(x) "16*("#x")" | ||
538 | #define PF_OFFS(x) "256+16*("#x")" | ||
539 | #define PF0(x) " prefetchnta "PF_OFFS(x)"(%1) ;\n" | ||
540 | #define LD(x, y) " movaps "OFFS(x)"(%1), %%xmm"#y" ;\n" | ||
541 | #define ST(x, y) " movaps %%xmm"#y", "OFFS(x)"(%1) ;\n" | ||
542 | #define PF1(x) " prefetchnta "PF_OFFS(x)"(%2) ;\n" | ||
543 | #define PF2(x) " prefetchnta "PF_OFFS(x)"(%3) ;\n" | ||
544 | #define PF3(x) " prefetchnta "PF_OFFS(x)"(%4) ;\n" | ||
545 | #define PF4(x) " prefetchnta "PF_OFFS(x)"(%5) ;\n" | ||
546 | #define PF5(x) " prefetchnta "PF_OFFS(x)"(%6) ;\n" | ||
547 | #define XO1(x, y) " xorps "OFFS(x)"(%2), %%xmm"#y" ;\n" | ||
548 | #define XO2(x, y) " xorps "OFFS(x)"(%3), %%xmm"#y" ;\n" | ||
549 | #define XO3(x, y) " xorps "OFFS(x)"(%4), %%xmm"#y" ;\n" | ||
550 | #define XO4(x, y) " xorps "OFFS(x)"(%5), %%xmm"#y" ;\n" | ||
551 | #define XO5(x, y) " xorps "OFFS(x)"(%6), %%xmm"#y" ;\n" | ||
552 | |||
553 | |||
554 | static void | ||
555 | xor_sse_2(unsigned long bytes, unsigned long *p1, unsigned long *p2) | ||
556 | { | ||
557 | unsigned long lines = bytes >> 8; | ||
558 | |||
559 | kernel_fpu_begin(); | ||
560 | |||
561 | asm volatile( | ||
562 | #undef BLOCK | ||
563 | #define BLOCK(i) \ | ||
564 | LD(i, 0) \ | ||
565 | LD(i + 1, 1) \ | ||
566 | PF1(i) \ | ||
567 | PF1(i + 2) \ | ||
568 | LD(i + 2, 2) \ | ||
569 | LD(i + 3, 3) \ | ||
570 | PF0(i + 4) \ | ||
571 | PF0(i + 6) \ | ||
572 | XO1(i, 0) \ | ||
573 | XO1(i + 1, 1) \ | ||
574 | XO1(i + 2, 2) \ | ||
575 | XO1(i + 3, 3) \ | ||
576 | ST(i, 0) \ | ||
577 | ST(i + 1, 1) \ | ||
578 | ST(i + 2, 2) \ | ||
579 | ST(i + 3, 3) \ | ||
580 | |||
581 | |||
582 | PF0(0) | ||
583 | PF0(2) | ||
584 | |||
585 | " .align 32 ;\n" | ||
586 | " 1: ;\n" | ||
587 | |||
588 | BLOCK(0) | ||
589 | BLOCK(4) | ||
590 | BLOCK(8) | ||
591 | BLOCK(12) | ||
592 | |||
593 | " addl $256, %1 ;\n" | ||
594 | " addl $256, %2 ;\n" | ||
595 | " decl %0 ;\n" | ||
596 | " jnz 1b ;\n" | ||
597 | : "+r" (lines), | ||
598 | "+r" (p1), "+r" (p2) | ||
599 | : | ||
600 | : "memory"); | ||
601 | |||
602 | kernel_fpu_end(); | ||
603 | } | ||
604 | |||
605 | static void | ||
606 | xor_sse_3(unsigned long bytes, unsigned long *p1, unsigned long *p2, | ||
607 | unsigned long *p3) | ||
608 | { | ||
609 | unsigned long lines = bytes >> 8; | ||
610 | |||
611 | kernel_fpu_begin(); | ||
612 | |||
613 | asm volatile( | ||
614 | #undef BLOCK | ||
615 | #define BLOCK(i) \ | ||
616 | PF1(i) \ | ||
617 | PF1(i + 2) \ | ||
618 | LD(i,0) \ | ||
619 | LD(i + 1, 1) \ | ||
620 | LD(i + 2, 2) \ | ||
621 | LD(i + 3, 3) \ | ||
622 | PF2(i) \ | ||
623 | PF2(i + 2) \ | ||
624 | PF0(i + 4) \ | ||
625 | PF0(i + 6) \ | ||
626 | XO1(i,0) \ | ||
627 | XO1(i + 1, 1) \ | ||
628 | XO1(i + 2, 2) \ | ||
629 | XO1(i + 3, 3) \ | ||
630 | XO2(i,0) \ | ||
631 | XO2(i + 1, 1) \ | ||
632 | XO2(i + 2, 2) \ | ||
633 | XO2(i + 3, 3) \ | ||
634 | ST(i,0) \ | ||
635 | ST(i + 1, 1) \ | ||
636 | ST(i + 2, 2) \ | ||
637 | ST(i + 3, 3) \ | ||
638 | |||
639 | |||
640 | PF0(0) | ||
641 | PF0(2) | ||
642 | |||
643 | " .align 32 ;\n" | ||
644 | " 1: ;\n" | ||
645 | |||
646 | BLOCK(0) | ||
647 | BLOCK(4) | ||
648 | BLOCK(8) | ||
649 | BLOCK(12) | ||
650 | |||
651 | " addl $256, %1 ;\n" | ||
652 | " addl $256, %2 ;\n" | ||
653 | " addl $256, %3 ;\n" | ||
654 | " decl %0 ;\n" | ||
655 | " jnz 1b ;\n" | ||
656 | : "+r" (lines), | ||
657 | "+r" (p1), "+r"(p2), "+r"(p3) | ||
658 | : | ||
659 | : "memory" ); | ||
660 | |||
661 | kernel_fpu_end(); | ||
662 | } | ||
663 | |||
664 | static void | ||
665 | xor_sse_4(unsigned long bytes, unsigned long *p1, unsigned long *p2, | ||
666 | unsigned long *p3, unsigned long *p4) | ||
667 | { | ||
668 | unsigned long lines = bytes >> 8; | ||
669 | |||
670 | kernel_fpu_begin(); | ||
671 | |||
672 | asm volatile( | ||
673 | #undef BLOCK | ||
674 | #define BLOCK(i) \ | ||
675 | PF1(i) \ | ||
676 | PF1(i + 2) \ | ||
677 | LD(i,0) \ | ||
678 | LD(i + 1, 1) \ | ||
679 | LD(i + 2, 2) \ | ||
680 | LD(i + 3, 3) \ | ||
681 | PF2(i) \ | ||
682 | PF2(i + 2) \ | ||
683 | XO1(i,0) \ | ||
684 | XO1(i + 1, 1) \ | ||
685 | XO1(i + 2, 2) \ | ||
686 | XO1(i + 3, 3) \ | ||
687 | PF3(i) \ | ||
688 | PF3(i + 2) \ | ||
689 | PF0(i + 4) \ | ||
690 | PF0(i + 6) \ | ||
691 | XO2(i,0) \ | ||
692 | XO2(i + 1, 1) \ | ||
693 | XO2(i + 2, 2) \ | ||
694 | XO2(i + 3, 3) \ | ||
695 | XO3(i,0) \ | ||
696 | XO3(i + 1, 1) \ | ||
697 | XO3(i + 2, 2) \ | ||
698 | XO3(i + 3, 3) \ | ||
699 | ST(i,0) \ | ||
700 | ST(i + 1, 1) \ | ||
701 | ST(i + 2, 2) \ | ||
702 | ST(i + 3, 3) \ | ||
703 | |||
704 | |||
705 | PF0(0) | ||
706 | PF0(2) | ||
707 | |||
708 | " .align 32 ;\n" | ||
709 | " 1: ;\n" | ||
710 | |||
711 | BLOCK(0) | ||
712 | BLOCK(4) | ||
713 | BLOCK(8) | ||
714 | BLOCK(12) | ||
715 | |||
716 | " addl $256, %1 ;\n" | ||
717 | " addl $256, %2 ;\n" | ||
718 | " addl $256, %3 ;\n" | ||
719 | " addl $256, %4 ;\n" | ||
720 | " decl %0 ;\n" | ||
721 | " jnz 1b ;\n" | ||
722 | : "+r" (lines), | ||
723 | "+r" (p1), "+r" (p2), "+r" (p3), "+r" (p4) | ||
724 | : | ||
725 | : "memory" ); | ||
726 | |||
727 | kernel_fpu_end(); | ||
728 | } | ||
729 | |||
730 | static void | ||
731 | xor_sse_5(unsigned long bytes, unsigned long *p1, unsigned long *p2, | ||
732 | unsigned long *p3, unsigned long *p4, unsigned long *p5) | ||
733 | { | ||
734 | unsigned long lines = bytes >> 8; | ||
735 | |||
736 | kernel_fpu_begin(); | ||
737 | |||
738 | /* Make sure GCC forgets anything it knows about p4 or p5, | ||
739 | such that it won't pass to the asm volatile below a | ||
740 | register that is shared with any other variable. That's | ||
741 | because we modify p4 and p5 there, but we can't mark them | ||
742 | as read/write, otherwise we'd overflow the 10-asm-operands | ||
743 | limit of GCC < 3.1. */ | ||
744 | asm("" : "+r" (p4), "+r" (p5)); | ||
745 | |||
746 | asm volatile( | ||
747 | #undef BLOCK | ||
748 | #define BLOCK(i) \ | ||
749 | PF1(i) \ | ||
750 | PF1(i + 2) \ | ||
751 | LD(i,0) \ | ||
752 | LD(i + 1, 1) \ | ||
753 | LD(i + 2, 2) \ | ||
754 | LD(i + 3, 3) \ | ||
755 | PF2(i) \ | ||
756 | PF2(i + 2) \ | ||
757 | XO1(i,0) \ | ||
758 | XO1(i + 1, 1) \ | ||
759 | XO1(i + 2, 2) \ | ||
760 | XO1(i + 3, 3) \ | ||
761 | PF3(i) \ | ||
762 | PF3(i + 2) \ | ||
763 | XO2(i,0) \ | ||
764 | XO2(i + 1, 1) \ | ||
765 | XO2(i + 2, 2) \ | ||
766 | XO2(i + 3, 3) \ | ||
767 | PF4(i) \ | ||
768 | PF4(i + 2) \ | ||
769 | PF0(i + 4) \ | ||
770 | PF0(i + 6) \ | ||
771 | XO3(i,0) \ | ||
772 | XO3(i + 1, 1) \ | ||
773 | XO3(i + 2, 2) \ | ||
774 | XO3(i + 3, 3) \ | ||
775 | XO4(i,0) \ | ||
776 | XO4(i + 1, 1) \ | ||
777 | XO4(i + 2, 2) \ | ||
778 | XO4(i + 3, 3) \ | ||
779 | ST(i,0) \ | ||
780 | ST(i + 1, 1) \ | ||
781 | ST(i + 2, 2) \ | ||
782 | ST(i + 3, 3) \ | ||
783 | |||
784 | |||
785 | PF0(0) | ||
786 | PF0(2) | ||
787 | |||
788 | " .align 32 ;\n" | ||
789 | " 1: ;\n" | ||
790 | |||
791 | BLOCK(0) | ||
792 | BLOCK(4) | ||
793 | BLOCK(8) | ||
794 | BLOCK(12) | ||
795 | |||
796 | " addl $256, %1 ;\n" | ||
797 | " addl $256, %2 ;\n" | ||
798 | " addl $256, %3 ;\n" | ||
799 | " addl $256, %4 ;\n" | ||
800 | " addl $256, %5 ;\n" | ||
801 | " decl %0 ;\n" | ||
802 | " jnz 1b ;\n" | ||
803 | : "+r" (lines), | ||
804 | "+r" (p1), "+r" (p2), "+r" (p3) | ||
805 | : "r" (p4), "r" (p5) | ||
806 | : "memory"); | ||
807 | |||
808 | /* p4 and p5 were modified, and now the variables are dead. | ||
809 | Clobber them just to be sure nobody does something stupid | ||
810 | like assuming they have some legal value. */ | ||
811 | asm("" : "=r" (p4), "=r" (p5)); | ||
812 | |||
813 | kernel_fpu_end(); | ||
814 | } | ||
815 | |||
816 | static struct xor_block_template xor_block_pIII_sse = { | 532 | static struct xor_block_template xor_block_pIII_sse = { |
817 | .name = "pIII_sse", | 533 | .name = "pIII_sse", |
818 | .do_2 = xor_sse_2, | 534 | .do_2 = xor_sse_2, |
@@ -827,26 +543,25 @@ static struct xor_block_template xor_block_pIII_sse = { | |||
827 | /* Also try the generic routines. */ | 543 | /* Also try the generic routines. */ |
828 | #include <asm-generic/xor.h> | 544 | #include <asm-generic/xor.h> |
829 | 545 | ||
546 | /* We force the use of the SSE xor block because it can write around L2. | ||
547 | We may also be able to load into the L1 only depending on how the cpu | ||
548 | deals with a load to a line that is being prefetched. */ | ||
830 | #undef XOR_TRY_TEMPLATES | 549 | #undef XOR_TRY_TEMPLATES |
831 | #define XOR_TRY_TEMPLATES \ | 550 | #define XOR_TRY_TEMPLATES \ |
832 | do { \ | 551 | do { \ |
833 | xor_speed(&xor_block_8regs); \ | ||
834 | xor_speed(&xor_block_8regs_p); \ | ||
835 | xor_speed(&xor_block_32regs); \ | ||
836 | xor_speed(&xor_block_32regs_p); \ | ||
837 | AVX_XOR_SPEED; \ | 552 | AVX_XOR_SPEED; \ |
838 | if (cpu_has_xmm) \ | 553 | if (cpu_has_xmm) { \ |
839 | xor_speed(&xor_block_pIII_sse); \ | 554 | xor_speed(&xor_block_pIII_sse); \ |
840 | if (cpu_has_mmx) { \ | 555 | xor_speed(&xor_block_sse_pf64); \ |
556 | } else if (cpu_has_mmx) { \ | ||
841 | xor_speed(&xor_block_pII_mmx); \ | 557 | xor_speed(&xor_block_pII_mmx); \ |
842 | xor_speed(&xor_block_p5_mmx); \ | 558 | xor_speed(&xor_block_p5_mmx); \ |
559 | } else { \ | ||
560 | xor_speed(&xor_block_8regs); \ | ||
561 | xor_speed(&xor_block_8regs_p); \ | ||
562 | xor_speed(&xor_block_32regs); \ | ||
563 | xor_speed(&xor_block_32regs_p); \ | ||
843 | } \ | 564 | } \ |
844 | } while (0) | 565 | } while (0) |
845 | 566 | ||
846 | /* We force the use of the SSE xor block because it can write around L2. | ||
847 | We may also be able to load into the L1 only depending on how the cpu | ||
848 | deals with a load to a line that is being prefetched. */ | ||
849 | #define XOR_SELECT_TEMPLATE(FASTEST) \ | ||
850 | AVX_SELECT(cpu_has_xmm ? &xor_block_pIII_sse : FASTEST) | ||
851 | |||
852 | #endif /* _ASM_X86_XOR_32_H */ | 567 | #endif /* _ASM_X86_XOR_32_H */ |
diff --git a/arch/x86/include/asm/xor_64.h b/arch/x86/include/asm/xor_64.h index 87ac522c4af5..546f1e3b87cc 100644 --- a/arch/x86/include/asm/xor_64.h +++ b/arch/x86/include/asm/xor_64.h | |||
@@ -1,301 +1,6 @@ | |||
1 | #ifndef _ASM_X86_XOR_64_H | 1 | #ifndef _ASM_X86_XOR_64_H |
2 | #define _ASM_X86_XOR_64_H | 2 | #define _ASM_X86_XOR_64_H |
3 | 3 | ||
4 | /* | ||
5 | * Optimized RAID-5 checksumming functions for MMX and SSE. | ||
6 | * | ||
7 | * This program is free software; you can redistribute it and/or modify | ||
8 | * it under the terms of the GNU General Public License as published by | ||
9 | * the Free Software Foundation; either version 2, or (at your option) | ||
10 | * any later version. | ||
11 | * | ||
12 | * You should have received a copy of the GNU General Public License | ||
13 | * (for example /usr/src/linux/COPYING); if not, write to the Free | ||
14 | * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | ||
15 | */ | ||
16 | |||
17 | |||
18 | /* | ||
19 | * Cache avoiding checksumming functions utilizing KNI instructions | ||
20 | * Copyright (C) 1999 Zach Brown (with obvious credit due Ingo) | ||
21 | */ | ||
22 | |||
23 | /* | ||
24 | * Based on | ||
25 | * High-speed RAID5 checksumming functions utilizing SSE instructions. | ||
26 | * Copyright (C) 1998 Ingo Molnar. | ||
27 | */ | ||
28 | |||
29 | /* | ||
30 | * x86-64 changes / gcc fixes from Andi Kleen. | ||
31 | * Copyright 2002 Andi Kleen, SuSE Labs. | ||
32 | * | ||
33 | * This hasn't been optimized for the hammer yet, but there are likely | ||
34 | * no advantages to be gotten from x86-64 here anyways. | ||
35 | */ | ||
36 | |||
37 | #include <asm/i387.h> | ||
38 | |||
39 | #define OFFS(x) "16*("#x")" | ||
40 | #define PF_OFFS(x) "256+16*("#x")" | ||
41 | #define PF0(x) " prefetchnta "PF_OFFS(x)"(%[p1]) ;\n" | ||
42 | #define LD(x, y) " movaps "OFFS(x)"(%[p1]), %%xmm"#y" ;\n" | ||
43 | #define ST(x, y) " movaps %%xmm"#y", "OFFS(x)"(%[p1]) ;\n" | ||
44 | #define PF1(x) " prefetchnta "PF_OFFS(x)"(%[p2]) ;\n" | ||
45 | #define PF2(x) " prefetchnta "PF_OFFS(x)"(%[p3]) ;\n" | ||
46 | #define PF3(x) " prefetchnta "PF_OFFS(x)"(%[p4]) ;\n" | ||
47 | #define PF4(x) " prefetchnta "PF_OFFS(x)"(%[p5]) ;\n" | ||
48 | #define PF5(x) " prefetchnta "PF_OFFS(x)"(%[p6]) ;\n" | ||
49 | #define XO1(x, y) " xorps "OFFS(x)"(%[p2]), %%xmm"#y" ;\n" | ||
50 | #define XO2(x, y) " xorps "OFFS(x)"(%[p3]), %%xmm"#y" ;\n" | ||
51 | #define XO3(x, y) " xorps "OFFS(x)"(%[p4]), %%xmm"#y" ;\n" | ||
52 | #define XO4(x, y) " xorps "OFFS(x)"(%[p5]), %%xmm"#y" ;\n" | ||
53 | #define XO5(x, y) " xorps "OFFS(x)"(%[p6]), %%xmm"#y" ;\n" | ||
54 | |||
55 | |||
56 | static void | ||
57 | xor_sse_2(unsigned long bytes, unsigned long *p1, unsigned long *p2) | ||
58 | { | ||
59 | unsigned int lines = bytes >> 8; | ||
60 | |||
61 | kernel_fpu_begin(); | ||
62 | |||
63 | asm volatile( | ||
64 | #undef BLOCK | ||
65 | #define BLOCK(i) \ | ||
66 | LD(i, 0) \ | ||
67 | LD(i + 1, 1) \ | ||
68 | PF1(i) \ | ||
69 | PF1(i + 2) \ | ||
70 | LD(i + 2, 2) \ | ||
71 | LD(i + 3, 3) \ | ||
72 | PF0(i + 4) \ | ||
73 | PF0(i + 6) \ | ||
74 | XO1(i, 0) \ | ||
75 | XO1(i + 1, 1) \ | ||
76 | XO1(i + 2, 2) \ | ||
77 | XO1(i + 3, 3) \ | ||
78 | ST(i, 0) \ | ||
79 | ST(i + 1, 1) \ | ||
80 | ST(i + 2, 2) \ | ||
81 | ST(i + 3, 3) \ | ||
82 | |||
83 | |||
84 | PF0(0) | ||
85 | PF0(2) | ||
86 | |||
87 | " .align 32 ;\n" | ||
88 | " 1: ;\n" | ||
89 | |||
90 | BLOCK(0) | ||
91 | BLOCK(4) | ||
92 | BLOCK(8) | ||
93 | BLOCK(12) | ||
94 | |||
95 | " addq %[inc], %[p1] ;\n" | ||
96 | " addq %[inc], %[p2] ;\n" | ||
97 | " decl %[cnt] ; jnz 1b" | ||
98 | : [p1] "+r" (p1), [p2] "+r" (p2), [cnt] "+r" (lines) | ||
99 | : [inc] "r" (256UL) | ||
100 | : "memory"); | ||
101 | |||
102 | kernel_fpu_end(); | ||
103 | } | ||
104 | |||
105 | static void | ||
106 | xor_sse_3(unsigned long bytes, unsigned long *p1, unsigned long *p2, | ||
107 | unsigned long *p3) | ||
108 | { | ||
109 | unsigned int lines = bytes >> 8; | ||
110 | |||
111 | kernel_fpu_begin(); | ||
112 | asm volatile( | ||
113 | #undef BLOCK | ||
114 | #define BLOCK(i) \ | ||
115 | PF1(i) \ | ||
116 | PF1(i + 2) \ | ||
117 | LD(i, 0) \ | ||
118 | LD(i + 1, 1) \ | ||
119 | LD(i + 2, 2) \ | ||
120 | LD(i + 3, 3) \ | ||
121 | PF2(i) \ | ||
122 | PF2(i + 2) \ | ||
123 | PF0(i + 4) \ | ||
124 | PF0(i + 6) \ | ||
125 | XO1(i, 0) \ | ||
126 | XO1(i + 1, 1) \ | ||
127 | XO1(i + 2, 2) \ | ||
128 | XO1(i + 3, 3) \ | ||
129 | XO2(i, 0) \ | ||
130 | XO2(i + 1, 1) \ | ||
131 | XO2(i + 2, 2) \ | ||
132 | XO2(i + 3, 3) \ | ||
133 | ST(i, 0) \ | ||
134 | ST(i + 1, 1) \ | ||
135 | ST(i + 2, 2) \ | ||
136 | ST(i + 3, 3) \ | ||
137 | |||
138 | |||
139 | PF0(0) | ||
140 | PF0(2) | ||
141 | |||
142 | " .align 32 ;\n" | ||
143 | " 1: ;\n" | ||
144 | |||
145 | BLOCK(0) | ||
146 | BLOCK(4) | ||
147 | BLOCK(8) | ||
148 | BLOCK(12) | ||
149 | |||
150 | " addq %[inc], %[p1] ;\n" | ||
151 | " addq %[inc], %[p2] ;\n" | ||
152 | " addq %[inc], %[p3] ;\n" | ||
153 | " decl %[cnt] ; jnz 1b" | ||
154 | : [cnt] "+r" (lines), | ||
155 | [p1] "+r" (p1), [p2] "+r" (p2), [p3] "+r" (p3) | ||
156 | : [inc] "r" (256UL) | ||
157 | : "memory"); | ||
158 | kernel_fpu_end(); | ||
159 | } | ||
160 | |||
161 | static void | ||
162 | xor_sse_4(unsigned long bytes, unsigned long *p1, unsigned long *p2, | ||
163 | unsigned long *p3, unsigned long *p4) | ||
164 | { | ||
165 | unsigned int lines = bytes >> 8; | ||
166 | |||
167 | kernel_fpu_begin(); | ||
168 | |||
169 | asm volatile( | ||
170 | #undef BLOCK | ||
171 | #define BLOCK(i) \ | ||
172 | PF1(i) \ | ||
173 | PF1(i + 2) \ | ||
174 | LD(i, 0) \ | ||
175 | LD(i + 1, 1) \ | ||
176 | LD(i + 2, 2) \ | ||
177 | LD(i + 3, 3) \ | ||
178 | PF2(i) \ | ||
179 | PF2(i + 2) \ | ||
180 | XO1(i, 0) \ | ||
181 | XO1(i + 1, 1) \ | ||
182 | XO1(i + 2, 2) \ | ||
183 | XO1(i + 3, 3) \ | ||
184 | PF3(i) \ | ||
185 | PF3(i + 2) \ | ||
186 | PF0(i + 4) \ | ||
187 | PF0(i + 6) \ | ||
188 | XO2(i, 0) \ | ||
189 | XO2(i + 1, 1) \ | ||
190 | XO2(i + 2, 2) \ | ||
191 | XO2(i + 3, 3) \ | ||
192 | XO3(i, 0) \ | ||
193 | XO3(i + 1, 1) \ | ||
194 | XO3(i + 2, 2) \ | ||
195 | XO3(i + 3, 3) \ | ||
196 | ST(i, 0) \ | ||
197 | ST(i + 1, 1) \ | ||
198 | ST(i + 2, 2) \ | ||
199 | ST(i + 3, 3) \ | ||
200 | |||
201 | |||
202 | PF0(0) | ||
203 | PF0(2) | ||
204 | |||
205 | " .align 32 ;\n" | ||
206 | " 1: ;\n" | ||
207 | |||
208 | BLOCK(0) | ||
209 | BLOCK(4) | ||
210 | BLOCK(8) | ||
211 | BLOCK(12) | ||
212 | |||
213 | " addq %[inc], %[p1] ;\n" | ||
214 | " addq %[inc], %[p2] ;\n" | ||
215 | " addq %[inc], %[p3] ;\n" | ||
216 | " addq %[inc], %[p4] ;\n" | ||
217 | " decl %[cnt] ; jnz 1b" | ||
218 | : [cnt] "+c" (lines), | ||
219 | [p1] "+r" (p1), [p2] "+r" (p2), [p3] "+r" (p3), [p4] "+r" (p4) | ||
220 | : [inc] "r" (256UL) | ||
221 | : "memory" ); | ||
222 | |||
223 | kernel_fpu_end(); | ||
224 | } | ||
225 | |||
226 | static void | ||
227 | xor_sse_5(unsigned long bytes, unsigned long *p1, unsigned long *p2, | ||
228 | unsigned long *p3, unsigned long *p4, unsigned long *p5) | ||
229 | { | ||
230 | unsigned int lines = bytes >> 8; | ||
231 | |||
232 | kernel_fpu_begin(); | ||
233 | |||
234 | asm volatile( | ||
235 | #undef BLOCK | ||
236 | #define BLOCK(i) \ | ||
237 | PF1(i) \ | ||
238 | PF1(i + 2) \ | ||
239 | LD(i, 0) \ | ||
240 | LD(i + 1, 1) \ | ||
241 | LD(i + 2, 2) \ | ||
242 | LD(i + 3, 3) \ | ||
243 | PF2(i) \ | ||
244 | PF2(i + 2) \ | ||
245 | XO1(i, 0) \ | ||
246 | XO1(i + 1, 1) \ | ||
247 | XO1(i + 2, 2) \ | ||
248 | XO1(i + 3, 3) \ | ||
249 | PF3(i) \ | ||
250 | PF3(i + 2) \ | ||
251 | XO2(i, 0) \ | ||
252 | XO2(i + 1, 1) \ | ||
253 | XO2(i + 2, 2) \ | ||
254 | XO2(i + 3, 3) \ | ||
255 | PF4(i) \ | ||
256 | PF4(i + 2) \ | ||
257 | PF0(i + 4) \ | ||
258 | PF0(i + 6) \ | ||
259 | XO3(i, 0) \ | ||
260 | XO3(i + 1, 1) \ | ||
261 | XO3(i + 2, 2) \ | ||
262 | XO3(i + 3, 3) \ | ||
263 | XO4(i, 0) \ | ||
264 | XO4(i + 1, 1) \ | ||
265 | XO4(i + 2, 2) \ | ||
266 | XO4(i + 3, 3) \ | ||
267 | ST(i, 0) \ | ||
268 | ST(i + 1, 1) \ | ||
269 | ST(i + 2, 2) \ | ||
270 | ST(i + 3, 3) \ | ||
271 | |||
272 | |||
273 | PF0(0) | ||
274 | PF0(2) | ||
275 | |||
276 | " .align 32 ;\n" | ||
277 | " 1: ;\n" | ||
278 | |||
279 | BLOCK(0) | ||
280 | BLOCK(4) | ||
281 | BLOCK(8) | ||
282 | BLOCK(12) | ||
283 | |||
284 | " addq %[inc], %[p1] ;\n" | ||
285 | " addq %[inc], %[p2] ;\n" | ||
286 | " addq %[inc], %[p3] ;\n" | ||
287 | " addq %[inc], %[p4] ;\n" | ||
288 | " addq %[inc], %[p5] ;\n" | ||
289 | " decl %[cnt] ; jnz 1b" | ||
290 | : [cnt] "+c" (lines), | ||
291 | [p1] "+r" (p1), [p2] "+r" (p2), [p3] "+r" (p3), [p4] "+r" (p4), | ||
292 | [p5] "+r" (p5) | ||
293 | : [inc] "r" (256UL) | ||
294 | : "memory"); | ||
295 | |||
296 | kernel_fpu_end(); | ||
297 | } | ||
298 | |||
299 | static struct xor_block_template xor_block_sse = { | 4 | static struct xor_block_template xor_block_sse = { |
300 | .name = "generic_sse", | 5 | .name = "generic_sse", |
301 | .do_2 = xor_sse_2, | 6 | .do_2 = xor_sse_2, |
@@ -308,17 +13,15 @@ static struct xor_block_template xor_block_sse = { | |||
308 | /* Also try the AVX routines */ | 13 | /* Also try the AVX routines */ |
309 | #include <asm/xor_avx.h> | 14 | #include <asm/xor_avx.h> |
310 | 15 | ||
16 | /* We force the use of the SSE xor block because it can write around L2. | ||
17 | We may also be able to load into the L1 only depending on how the cpu | ||
18 | deals with a load to a line that is being prefetched. */ | ||
311 | #undef XOR_TRY_TEMPLATES | 19 | #undef XOR_TRY_TEMPLATES |
312 | #define XOR_TRY_TEMPLATES \ | 20 | #define XOR_TRY_TEMPLATES \ |
313 | do { \ | 21 | do { \ |
314 | AVX_XOR_SPEED; \ | 22 | AVX_XOR_SPEED; \ |
23 | xor_speed(&xor_block_sse_pf64); \ | ||
315 | xor_speed(&xor_block_sse); \ | 24 | xor_speed(&xor_block_sse); \ |
316 | } while (0) | 25 | } while (0) |
317 | 26 | ||
318 | /* We force the use of the SSE xor block because it can write around L2. | ||
319 | We may also be able to load into the L1 only depending on how the cpu | ||
320 | deals with a load to a line that is being prefetched. */ | ||
321 | #define XOR_SELECT_TEMPLATE(FASTEST) \ | ||
322 | AVX_SELECT(&xor_block_sse) | ||
323 | |||
324 | #endif /* _ASM_X86_XOR_64_H */ | 27 | #endif /* _ASM_X86_XOR_64_H */ |
diff --git a/arch/x86/include/uapi/asm/bootparam.h b/arch/x86/include/uapi/asm/bootparam.h index 92862cd90201..c15ddaf90710 100644 --- a/arch/x86/include/uapi/asm/bootparam.h +++ b/arch/x86/include/uapi/asm/bootparam.h | |||
@@ -1,6 +1,31 @@ | |||
1 | #ifndef _ASM_X86_BOOTPARAM_H | 1 | #ifndef _ASM_X86_BOOTPARAM_H |
2 | #define _ASM_X86_BOOTPARAM_H | 2 | #define _ASM_X86_BOOTPARAM_H |
3 | 3 | ||
4 | /* setup_data types */ | ||
5 | #define SETUP_NONE 0 | ||
6 | #define SETUP_E820_EXT 1 | ||
7 | #define SETUP_DTB 2 | ||
8 | #define SETUP_PCI 3 | ||
9 | |||
10 | /* ram_size flags */ | ||
11 | #define RAMDISK_IMAGE_START_MASK 0x07FF | ||
12 | #define RAMDISK_PROMPT_FLAG 0x8000 | ||
13 | #define RAMDISK_LOAD_FLAG 0x4000 | ||
14 | |||
15 | /* loadflags */ | ||
16 | #define LOADED_HIGH (1<<0) | ||
17 | #define QUIET_FLAG (1<<5) | ||
18 | #define KEEP_SEGMENTS (1<<6) | ||
19 | #define CAN_USE_HEAP (1<<7) | ||
20 | |||
21 | /* xloadflags */ | ||
22 | #define XLF_KERNEL_64 (1<<0) | ||
23 | #define XLF_CAN_BE_LOADED_ABOVE_4G (1<<1) | ||
24 | #define XLF_EFI_HANDOVER_32 (1<<2) | ||
25 | #define XLF_EFI_HANDOVER_64 (1<<3) | ||
26 | |||
27 | #ifndef __ASSEMBLY__ | ||
28 | |||
4 | #include <linux/types.h> | 29 | #include <linux/types.h> |
5 | #include <linux/screen_info.h> | 30 | #include <linux/screen_info.h> |
6 | #include <linux/apm_bios.h> | 31 | #include <linux/apm_bios.h> |
@@ -9,12 +34,6 @@ | |||
9 | #include <asm/ist.h> | 34 | #include <asm/ist.h> |
10 | #include <video/edid.h> | 35 | #include <video/edid.h> |
11 | 36 | ||
12 | /* setup data types */ | ||
13 | #define SETUP_NONE 0 | ||
14 | #define SETUP_E820_EXT 1 | ||
15 | #define SETUP_DTB 2 | ||
16 | #define SETUP_PCI 3 | ||
17 | |||
18 | /* extensible setup data list node */ | 37 | /* extensible setup data list node */ |
19 | struct setup_data { | 38 | struct setup_data { |
20 | __u64 next; | 39 | __u64 next; |
@@ -28,9 +47,6 @@ struct setup_header { | |||
28 | __u16 root_flags; | 47 | __u16 root_flags; |
29 | __u32 syssize; | 48 | __u32 syssize; |
30 | __u16 ram_size; | 49 | __u16 ram_size; |
31 | #define RAMDISK_IMAGE_START_MASK 0x07FF | ||
32 | #define RAMDISK_PROMPT_FLAG 0x8000 | ||
33 | #define RAMDISK_LOAD_FLAG 0x4000 | ||
34 | __u16 vid_mode; | 50 | __u16 vid_mode; |
35 | __u16 root_dev; | 51 | __u16 root_dev; |
36 | __u16 boot_flag; | 52 | __u16 boot_flag; |
@@ -42,10 +58,6 @@ struct setup_header { | |||
42 | __u16 kernel_version; | 58 | __u16 kernel_version; |
43 | __u8 type_of_loader; | 59 | __u8 type_of_loader; |
44 | __u8 loadflags; | 60 | __u8 loadflags; |
45 | #define LOADED_HIGH (1<<0) | ||
46 | #define QUIET_FLAG (1<<5) | ||
47 | #define KEEP_SEGMENTS (1<<6) | ||
48 | #define CAN_USE_HEAP (1<<7) | ||
49 | __u16 setup_move_size; | 61 | __u16 setup_move_size; |
50 | __u32 code32_start; | 62 | __u32 code32_start; |
51 | __u32 ramdisk_image; | 63 | __u32 ramdisk_image; |
@@ -58,7 +70,8 @@ struct setup_header { | |||
58 | __u32 initrd_addr_max; | 70 | __u32 initrd_addr_max; |
59 | __u32 kernel_alignment; | 71 | __u32 kernel_alignment; |
60 | __u8 relocatable_kernel; | 72 | __u8 relocatable_kernel; |
61 | __u8 _pad2[3]; | 73 | __u8 min_alignment; |
74 | __u16 xloadflags; | ||
62 | __u32 cmdline_size; | 75 | __u32 cmdline_size; |
63 | __u32 hardware_subarch; | 76 | __u32 hardware_subarch; |
64 | __u64 hardware_subarch_data; | 77 | __u64 hardware_subarch_data; |
@@ -106,7 +119,10 @@ struct boot_params { | |||
106 | __u8 hd1_info[16]; /* obsolete! */ /* 0x090 */ | 119 | __u8 hd1_info[16]; /* obsolete! */ /* 0x090 */ |
107 | struct sys_desc_table sys_desc_table; /* 0x0a0 */ | 120 | struct sys_desc_table sys_desc_table; /* 0x0a0 */ |
108 | struct olpc_ofw_header olpc_ofw_header; /* 0x0b0 */ | 121 | struct olpc_ofw_header olpc_ofw_header; /* 0x0b0 */ |
109 | __u8 _pad4[128]; /* 0x0c0 */ | 122 | __u32 ext_ramdisk_image; /* 0x0c0 */ |
123 | __u32 ext_ramdisk_size; /* 0x0c4 */ | ||
124 | __u32 ext_cmd_line_ptr; /* 0x0c8 */ | ||
125 | __u8 _pad4[116]; /* 0x0cc */ | ||
110 | struct edid_info edid_info; /* 0x140 */ | 126 | struct edid_info edid_info; /* 0x140 */ |
111 | struct efi_info efi_info; /* 0x1c0 */ | 127 | struct efi_info efi_info; /* 0x1c0 */ |
112 | __u32 alt_mem_k; /* 0x1e0 */ | 128 | __u32 alt_mem_k; /* 0x1e0 */ |
@@ -115,7 +131,20 @@ struct boot_params { | |||
115 | __u8 eddbuf_entries; /* 0x1e9 */ | 131 | __u8 eddbuf_entries; /* 0x1e9 */ |
116 | __u8 edd_mbr_sig_buf_entries; /* 0x1ea */ | 132 | __u8 edd_mbr_sig_buf_entries; /* 0x1ea */ |
117 | __u8 kbd_status; /* 0x1eb */ | 133 | __u8 kbd_status; /* 0x1eb */ |
118 | __u8 _pad6[5]; /* 0x1ec */ | 134 | __u8 _pad5[3]; /* 0x1ec */ |
135 | /* | ||
136 | * The sentinel is set to a nonzero value (0xff) in header.S. | ||
137 | * | ||
138 | * A bootloader is supposed to only take setup_header and put | ||
139 | * it into a clean boot_params buffer. If it turns out that | ||
140 | * it is clumsy or too generous with the buffer, it most | ||
141 | * probably will pick up the sentinel variable too. The fact | ||
142 | * that this variable then is still 0xff will let kernel | ||
143 | * know that some variables in boot_params are invalid and | ||
144 | * kernel should zero out certain portions of boot_params. | ||
145 | */ | ||
146 | __u8 sentinel; /* 0x1ef */ | ||
147 | __u8 _pad6[1]; /* 0x1f0 */ | ||
119 | struct setup_header hdr; /* setup header */ /* 0x1f1 */ | 148 | struct setup_header hdr; /* setup header */ /* 0x1f1 */ |
120 | __u8 _pad7[0x290-0x1f1-sizeof(struct setup_header)]; | 149 | __u8 _pad7[0x290-0x1f1-sizeof(struct setup_header)]; |
121 | __u32 edd_mbr_sig_buffer[EDD_MBR_SIG_MAX]; /* 0x290 */ | 150 | __u32 edd_mbr_sig_buffer[EDD_MBR_SIG_MAX]; /* 0x290 */ |
@@ -134,6 +163,6 @@ enum { | |||
134 | X86_NR_SUBARCHS, | 163 | X86_NR_SUBARCHS, |
135 | }; | 164 | }; |
136 | 165 | ||
137 | 166 | #endif /* __ASSEMBLY__ */ | |
138 | 167 | ||
139 | #endif /* _ASM_X86_BOOTPARAM_H */ | 168 | #endif /* _ASM_X86_BOOTPARAM_H */ |
diff --git a/arch/x86/include/uapi/asm/mce.h b/arch/x86/include/uapi/asm/mce.h index 58c829871c31..a0eab85ce7b8 100644 --- a/arch/x86/include/uapi/asm/mce.h +++ b/arch/x86/include/uapi/asm/mce.h | |||
@@ -4,66 +4,6 @@ | |||
4 | #include <linux/types.h> | 4 | #include <linux/types.h> |
5 | #include <asm/ioctls.h> | 5 | #include <asm/ioctls.h> |
6 | 6 | ||
7 | /* | ||
8 | * Machine Check support for x86 | ||
9 | */ | ||
10 | |||
11 | /* MCG_CAP register defines */ | ||
12 | #define MCG_BANKCNT_MASK 0xff /* Number of Banks */ | ||
13 | #define MCG_CTL_P (1ULL<<8) /* MCG_CTL register available */ | ||
14 | #define MCG_EXT_P (1ULL<<9) /* Extended registers available */ | ||
15 | #define MCG_CMCI_P (1ULL<<10) /* CMCI supported */ | ||
16 | #define MCG_EXT_CNT_MASK 0xff0000 /* Number of Extended registers */ | ||
17 | #define MCG_EXT_CNT_SHIFT 16 | ||
18 | #define MCG_EXT_CNT(c) (((c) & MCG_EXT_CNT_MASK) >> MCG_EXT_CNT_SHIFT) | ||
19 | #define MCG_SER_P (1ULL<<24) /* MCA recovery/new status bits */ | ||
20 | |||
21 | /* MCG_STATUS register defines */ | ||
22 | #define MCG_STATUS_RIPV (1ULL<<0) /* restart ip valid */ | ||
23 | #define MCG_STATUS_EIPV (1ULL<<1) /* ip points to correct instruction */ | ||
24 | #define MCG_STATUS_MCIP (1ULL<<2) /* machine check in progress */ | ||
25 | |||
26 | /* MCi_STATUS register defines */ | ||
27 | #define MCI_STATUS_VAL (1ULL<<63) /* valid error */ | ||
28 | #define MCI_STATUS_OVER (1ULL<<62) /* previous errors lost */ | ||
29 | #define MCI_STATUS_UC (1ULL<<61) /* uncorrected error */ | ||
30 | #define MCI_STATUS_EN (1ULL<<60) /* error enabled */ | ||
31 | #define MCI_STATUS_MISCV (1ULL<<59) /* misc error reg. valid */ | ||
32 | #define MCI_STATUS_ADDRV (1ULL<<58) /* addr reg. valid */ | ||
33 | #define MCI_STATUS_PCC (1ULL<<57) /* processor context corrupt */ | ||
34 | #define MCI_STATUS_S (1ULL<<56) /* Signaled machine check */ | ||
35 | #define MCI_STATUS_AR (1ULL<<55) /* Action required */ | ||
36 | #define MCACOD 0xffff /* MCA Error Code */ | ||
37 | |||
38 | /* Architecturally defined codes from SDM Vol. 3B Chapter 15 */ | ||
39 | #define MCACOD_SCRUB 0x00C0 /* 0xC0-0xCF Memory Scrubbing */ | ||
40 | #define MCACOD_SCRUBMSK 0xfff0 | ||
41 | #define MCACOD_L3WB 0x017A /* L3 Explicit Writeback */ | ||
42 | #define MCACOD_DATA 0x0134 /* Data Load */ | ||
43 | #define MCACOD_INSTR 0x0150 /* Instruction Fetch */ | ||
44 | |||
45 | /* MCi_MISC register defines */ | ||
46 | #define MCI_MISC_ADDR_LSB(m) ((m) & 0x3f) | ||
47 | #define MCI_MISC_ADDR_MODE(m) (((m) >> 6) & 7) | ||
48 | #define MCI_MISC_ADDR_SEGOFF 0 /* segment offset */ | ||
49 | #define MCI_MISC_ADDR_LINEAR 1 /* linear address */ | ||
50 | #define MCI_MISC_ADDR_PHYS 2 /* physical address */ | ||
51 | #define MCI_MISC_ADDR_MEM 3 /* memory address */ | ||
52 | #define MCI_MISC_ADDR_GENERIC 7 /* generic */ | ||
53 | |||
54 | /* CTL2 register defines */ | ||
55 | #define MCI_CTL2_CMCI_EN (1ULL << 30) | ||
56 | #define MCI_CTL2_CMCI_THRESHOLD_MASK 0x7fffULL | ||
57 | |||
58 | #define MCJ_CTX_MASK 3 | ||
59 | #define MCJ_CTX(flags) ((flags) & MCJ_CTX_MASK) | ||
60 | #define MCJ_CTX_RANDOM 0 /* inject context: random */ | ||
61 | #define MCJ_CTX_PROCESS 0x1 /* inject context: process */ | ||
62 | #define MCJ_CTX_IRQ 0x2 /* inject context: IRQ */ | ||
63 | #define MCJ_NMI_BROADCAST 0x4 /* do NMI broadcasting */ | ||
64 | #define MCJ_EXCEPTION 0x8 /* raise as exception */ | ||
65 | #define MCJ_IRQ_BRAODCAST 0x10 /* do IRQ broadcasting */ | ||
66 | |||
67 | /* Fields are zero when not available */ | 7 | /* Fields are zero when not available */ |
68 | struct mce { | 8 | struct mce { |
69 | __u64 status; | 9 | __u64 status; |
@@ -87,35 +27,8 @@ struct mce { | |||
87 | __u64 mcgcap; /* MCGCAP MSR: machine check capabilities of CPU */ | 27 | __u64 mcgcap; /* MCGCAP MSR: machine check capabilities of CPU */ |
88 | }; | 28 | }; |
89 | 29 | ||
90 | /* | ||
91 | * This structure contains all data related to the MCE log. Also | ||
92 | * carries a signature to make it easier to find from external | ||
93 | * debugging tools. Each entry is only valid when its finished flag | ||
94 | * is set. | ||
95 | */ | ||
96 | |||
97 | #define MCE_LOG_LEN 32 | ||
98 | |||
99 | struct mce_log { | ||
100 | char signature[12]; /* "MACHINECHECK" */ | ||
101 | unsigned len; /* = MCE_LOG_LEN */ | ||
102 | unsigned next; | ||
103 | unsigned flags; | ||
104 | unsigned recordlen; /* length of struct mce */ | ||
105 | struct mce entry[MCE_LOG_LEN]; | ||
106 | }; | ||
107 | |||
108 | #define MCE_OVERFLOW 0 /* bit 0 in flags means overflow */ | ||
109 | |||
110 | #define MCE_LOG_SIGNATURE "MACHINECHECK" | ||
111 | |||
112 | #define MCE_GET_RECORD_LEN _IOR('M', 1, int) | 30 | #define MCE_GET_RECORD_LEN _IOR('M', 1, int) |
113 | #define MCE_GET_LOG_LEN _IOR('M', 2, int) | 31 | #define MCE_GET_LOG_LEN _IOR('M', 2, int) |
114 | #define MCE_GETCLEAR_FLAGS _IOR('M', 3, int) | 32 | #define MCE_GETCLEAR_FLAGS _IOR('M', 3, int) |
115 | 33 | ||
116 | /* Software defined banks */ | ||
117 | #define MCE_EXTENDED_BANK 128 | ||
118 | #define MCE_THERMAL_BANK MCE_EXTENDED_BANK + 0 | ||
119 | #define K8_MCE_THRESHOLD_BASE (MCE_EXTENDED_BANK + 1) | ||
120 | |||
121 | #endif /* _UAPI_ASM_X86_MCE_H */ | 34 | #endif /* _UAPI_ASM_X86_MCE_H */ |
diff --git a/arch/x86/include/uapi/asm/msr-index.h b/arch/x86/include/uapi/asm/msr-index.h index 433a59fb1a74..f26d2771846f 100644 --- a/arch/x86/include/uapi/asm/msr-index.h +++ b/arch/x86/include/uapi/asm/msr-index.h | |||
@@ -103,6 +103,8 @@ | |||
103 | #define DEBUGCTLMSR_BTS_OFF_USR (1UL << 10) | 103 | #define DEBUGCTLMSR_BTS_OFF_USR (1UL << 10) |
104 | #define DEBUGCTLMSR_FREEZE_LBRS_ON_PMI (1UL << 11) | 104 | #define DEBUGCTLMSR_FREEZE_LBRS_ON_PMI (1UL << 11) |
105 | 105 | ||
106 | #define MSR_IA32_POWER_CTL 0x000001fc | ||
107 | |||
106 | #define MSR_IA32_MC0_CTL 0x00000400 | 108 | #define MSR_IA32_MC0_CTL 0x00000400 |
107 | #define MSR_IA32_MC0_STATUS 0x00000401 | 109 | #define MSR_IA32_MC0_STATUS 0x00000401 |
108 | #define MSR_IA32_MC0_ADDR 0x00000402 | 110 | #define MSR_IA32_MC0_ADDR 0x00000402 |
@@ -194,6 +196,8 @@ | |||
194 | /* Fam 15h MSRs */ | 196 | /* Fam 15h MSRs */ |
195 | #define MSR_F15H_PERF_CTL 0xc0010200 | 197 | #define MSR_F15H_PERF_CTL 0xc0010200 |
196 | #define MSR_F15H_PERF_CTR 0xc0010201 | 198 | #define MSR_F15H_PERF_CTR 0xc0010201 |
199 | #define MSR_F15H_NB_PERF_CTL 0xc0010240 | ||
200 | #define MSR_F15H_NB_PERF_CTR 0xc0010241 | ||
197 | 201 | ||
198 | /* Fam 10h MSRs */ | 202 | /* Fam 10h MSRs */ |
199 | #define MSR_FAM10H_MMIO_CONF_BASE 0xc0010058 | 203 | #define MSR_FAM10H_MMIO_CONF_BASE 0xc0010058 |
@@ -272,6 +276,7 @@ | |||
272 | #define MSR_IA32_PLATFORM_ID 0x00000017 | 276 | #define MSR_IA32_PLATFORM_ID 0x00000017 |
273 | #define MSR_IA32_EBL_CR_POWERON 0x0000002a | 277 | #define MSR_IA32_EBL_CR_POWERON 0x0000002a |
274 | #define MSR_EBC_FREQUENCY_ID 0x0000002c | 278 | #define MSR_EBC_FREQUENCY_ID 0x0000002c |
279 | #define MSR_SMI_COUNT 0x00000034 | ||
275 | #define MSR_IA32_FEATURE_CONTROL 0x0000003a | 280 | #define MSR_IA32_FEATURE_CONTROL 0x0000003a |
276 | #define MSR_IA32_TSC_ADJUST 0x0000003b | 281 | #define MSR_IA32_TSC_ADJUST 0x0000003b |
277 | 282 | ||