diff options
Diffstat (limited to 'include/acpi/actbl2.h')
-rw-r--r-- | include/acpi/actbl2.h | 260 |
1 files changed, 124 insertions, 136 deletions
diff --git a/include/acpi/actbl2.h b/include/acpi/actbl2.h index e1729c967e05..50305ce2681a 100644 --- a/include/acpi/actbl2.h +++ b/include/acpi/actbl2.h | |||
@@ -64,62 +64,56 @@ | |||
64 | #define FADT2_REVISION_ID 3 | 64 | #define FADT2_REVISION_ID 3 |
65 | #define FADT2_MINUS_REVISION_ID 2 | 65 | #define FADT2_MINUS_REVISION_ID 2 |
66 | 66 | ||
67 | |||
68 | #pragma pack(1) | 67 | #pragma pack(1) |
69 | 68 | ||
70 | /* | 69 | /* |
71 | * ACPI 2.0 Root System Description Table (RSDT) | 70 | * ACPI 2.0 Root System Description Table (RSDT) |
72 | */ | 71 | */ |
73 | struct rsdt_descriptor_rev2 | 72 | struct rsdt_descriptor_rev2 { |
74 | { | 73 | ACPI_TABLE_HEADER_DEF /* ACPI common table header */ |
75 | ACPI_TABLE_HEADER_DEF /* ACPI common table header */ | 74 | u32 table_offset_entry[1]; /* Array of pointers to ACPI tables */ |
76 | u32 table_offset_entry [1]; /* Array of pointers to */ | ||
77 | /* ACPI table headers */ | ||
78 | }; | 75 | }; |
79 | 76 | ||
80 | |||
81 | /* | 77 | /* |
82 | * ACPI 2.0 Extended System Description Table (XSDT) | 78 | * ACPI 2.0 Extended System Description Table (XSDT) |
83 | */ | 79 | */ |
84 | struct xsdt_descriptor_rev2 | 80 | struct xsdt_descriptor_rev2 { |
85 | { | 81 | ACPI_TABLE_HEADER_DEF /* ACPI common table header */ |
86 | ACPI_TABLE_HEADER_DEF /* ACPI common table header */ | 82 | u64 table_offset_entry[1]; /* Array of pointers to ACPI tables */ |
87 | u64 table_offset_entry [1]; /* Array of pointers to */ | ||
88 | /* ACPI table headers */ | ||
89 | }; | 83 | }; |
90 | 84 | ||
91 | |||
92 | /* | 85 | /* |
93 | * ACPI 2.0 Firmware ACPI Control Structure (FACS) | 86 | * ACPI 2.0 Firmware ACPI Control Structure (FACS) |
94 | */ | 87 | */ |
95 | struct facs_descriptor_rev2 | 88 | struct facs_descriptor_rev2 { |
96 | { | 89 | char signature[4]; /* ASCII table signature */ |
97 | char signature[4]; /* ACPI signature */ | 90 | u32 length; /* Length of structure, in bytes */ |
98 | u32 length; /* Length of structure, in bytes */ | 91 | u32 hardware_signature; /* Hardware configuration signature */ |
99 | u32 hardware_signature; /* Hardware configuration signature */ | 92 | u32 firmware_waking_vector; /* 32-bit physical address of the Firmware Waking Vector. */ |
100 | u32 firmware_waking_vector; /* 32bit physical address of the Firmware Waking Vector. */ | 93 | u32 global_lock; /* Global Lock used to synchronize access to shared hardware resources */ |
101 | u32 global_lock; /* Global Lock used to synchronize access to shared hardware resources */ | 94 | |
102 | u32 S4bios_f : 1; /* S4Bios_f - Indicates if S4BIOS support is present */ | 95 | /* Flags (32 bits) */ |
103 | u32 reserved1 : 31; /* Must be 0 */ | 96 | |
104 | u64 xfirmware_waking_vector; /* 64bit physical address of the Firmware Waking Vector. */ | 97 | u8 S4bios_f:1; /* 00: S4BIOS support is present */ |
105 | u8 version; /* Version of this table */ | 98 | u8:7; /* 01-07: Reserved, must be zero */ |
106 | u8 reserved3 [31]; /* Reserved - must be zero */ | 99 | u8 reserved1[3]; /* 08-31: Reserved, must be zero */ |
100 | |||
101 | u64 xfirmware_waking_vector; /* 64-bit physical address of the Firmware Waking Vector. */ | ||
102 | u8 version; /* Version of this table */ | ||
103 | u8 reserved3[31]; /* Reserved, must be zero */ | ||
107 | }; | 104 | }; |
108 | 105 | ||
109 | |||
110 | /* | 106 | /* |
111 | * ACPI 2.0+ Generic Address Structure (GAS) | 107 | * ACPI 2.0+ Generic Address Structure (GAS) |
112 | */ | 108 | */ |
113 | struct acpi_generic_address | 109 | struct acpi_generic_address { |
114 | { | 110 | u8 address_space_id; /* Address space where struct or register exists. */ |
115 | u8 address_space_id; /* Address space where struct or register exists. */ | 111 | u8 register_bit_width; /* Size in bits of given register */ |
116 | u8 register_bit_width; /* Size in bits of given register */ | 112 | u8 register_bit_offset; /* Bit offset within the register */ |
117 | u8 register_bit_offset; /* Bit offset within the register */ | 113 | u8 access_width; /* Minimum Access size (ACPI 3.0) */ |
118 | u8 access_width; /* Minimum Access size (ACPI 3.0) */ | 114 | u64 address; /* 64-bit address of struct or register */ |
119 | u64 address; /* 64-bit address of struct or register */ | ||
120 | }; | 115 | }; |
121 | 116 | ||
122 | |||
123 | #define FADT_REV2_COMMON \ | 117 | #define FADT_REV2_COMMON \ |
124 | u32 V1_firmware_ctrl; /* 32-bit physical address of FACS */ \ | 118 | u32 V1_firmware_ctrl; /* 32-bit physical address of FACS */ \ |
125 | u32 V1_dsdt; /* 32-bit physical address of DSDT */ \ | 119 | u32 V1_dsdt; /* 32-bit physical address of DSDT */ \ |
@@ -161,129 +155,123 @@ struct acpi_generic_address | |||
161 | /* | 155 | /* |
162 | * ACPI 2.0+ Fixed ACPI Description Table (FADT) | 156 | * ACPI 2.0+ Fixed ACPI Description Table (FADT) |
163 | */ | 157 | */ |
164 | struct fadt_descriptor_rev2 | 158 | struct fadt_descriptor_rev2 { |
165 | { | 159 | ACPI_TABLE_HEADER_DEF /* ACPI common table header */ |
166 | ACPI_TABLE_HEADER_DEF /* ACPI common table header */ | 160 | FADT_REV2_COMMON u8 reserved2; /* Reserved, must be zero */ |
167 | FADT_REV2_COMMON | 161 | |
168 | u8 reserved2; /* Reserved */ | 162 | /* Flags (32 bits) */ |
169 | u32 wb_invd : 1; /* The wbinvd instruction works properly */ | 163 | |
170 | u32 wb_invd_flush : 1; /* The wbinvd flushes but does not invalidate */ | 164 | u8 wb_invd:1; /* 00: The wbinvd instruction works properly */ |
171 | u32 proc_c1 : 1; /* All processors support C1 state */ | 165 | u8 wb_invd_flush:1; /* 01: The wbinvd flushes but does not invalidate */ |
172 | u32 plvl2_up : 1; /* C2 state works on MP system */ | 166 | u8 proc_c1:1; /* 02: All processors support C1 state */ |
173 | u32 pwr_button : 1; /* Power button is handled as a generic feature */ | 167 | u8 plvl2_up:1; /* 03: C2 state works on MP system */ |
174 | u32 sleep_button : 1; /* Sleep button is handled as a generic feature, or not present */ | 168 | u8 pwr_button:1; /* 04: Power button is handled as a generic feature */ |
175 | u32 fixed_rTC : 1; /* RTC wakeup stat not in fixed register space */ | 169 | u8 sleep_button:1; /* 05: Sleep button is handled as a generic feature, or not present */ |
176 | u32 rtcs4 : 1; /* RTC wakeup stat not possible from S4 */ | 170 | u8 fixed_rTC:1; /* 06: RTC wakeup stat not in fixed register space */ |
177 | u32 tmr_val_ext : 1; /* Indicates tmr_val is 32 bits 0=24-bits */ | 171 | u8 rtcs4:1; /* 07: RTC wakeup stat not possible from S4 */ |
178 | u32 dock_cap : 1; /* Supports Docking */ | 172 | u8 tmr_val_ext:1; /* 08: tmr_val is 32 bits 0=24-bits */ |
179 | u32 reset_reg_sup : 1; /* Indicates system supports system reset via the FADT RESET_REG */ | 173 | u8 dock_cap:1; /* 09: Docking supported */ |
180 | u32 sealed_case : 1; /* Indicates system has no internal expansion capabilities and case is sealed */ | 174 | u8 reset_reg_sup:1; /* 10: System reset via the FADT RESET_REG supported */ |
181 | u32 headless : 1; /* Indicates system does not have local video capabilities or local input devices */ | 175 | u8 sealed_case:1; /* 11: No internal expansion capabilities and case is sealed */ |
182 | u32 cpu_sw_sleep : 1; /* Indicates to OSPM that a processor native instruction */ | 176 | u8 headless:1; /* 12: No local video capabilities or local input devices */ |
183 | /* must be executed after writing the SLP_TYPx register */ | 177 | u8 cpu_sw_sleep:1; /* 13: Must execute native instruction after writing SLP_TYPx register */ |
184 | /* ACPI 3.0 flag bits */ | 178 | |
185 | 179 | u8 pci_exp_wak:1; /* 14: System supports PCIEXP_WAKE (STS/EN) bits (ACPI 3.0) */ | |
186 | u32 pci_exp_wak : 1; /* System supports PCIEXP_WAKE (STS/EN) bits */ | 180 | u8 use_platform_clock:1; /* 15: OSPM should use platform-provided timer (ACPI 3.0) */ |
187 | u32 use_platform_clock : 1; /* OSPM should use platform-provided timer */ | 181 | u8 S4rtc_sts_valid:1; /* 16: Contents of RTC_STS valid after S4 wake (ACPI 3.0) */ |
188 | u32 S4rtc_sts_valid : 1; /* Contents of RTC_STS valid after S4 wake */ | 182 | u8 remote_power_on_capable:1; /* 17: System is compatible with remote power on (ACPI 3.0) */ |
189 | u32 remote_power_on_capable : 1; /* System is compatible with remote power on */ | 183 | u8 force_apic_cluster_model:1; /* 18: All local APICs must use cluster model (ACPI 3.0) */ |
190 | u32 force_apic_cluster_model : 1; /* All local APICs must use cluster model */ | 184 | u8 force_apic_physical_destination_mode:1; /* 19: all local x_aPICs must use physical dest mode (ACPI 3.0) */ |
191 | u32 force_apic_physical_destination_mode : 1; /* all local x_aPICs must use physical dest mode */ | 185 | u8:4; /* 20-23: Reserved, must be zero */ |
192 | u32 reserved6 : 12;/* Reserved - must be zero */ | 186 | u8 reserved3; /* 24-31: Reserved, must be zero */ |
193 | 187 | ||
194 | struct acpi_generic_address reset_register; /* Reset register address in GAS format */ | 188 | struct acpi_generic_address reset_register; /* Reset register address in GAS format */ |
195 | u8 reset_value; /* Value to write to the reset_register port to reset the system */ | 189 | u8 reset_value; /* Value to write to the reset_register port to reset the system */ |
196 | u8 reserved7[3]; /* These three bytes must be zero */ | 190 | u8 reserved4[3]; /* These three bytes must be zero */ |
197 | u64 xfirmware_ctrl; /* 64-bit physical address of FACS */ | 191 | u64 xfirmware_ctrl; /* 64-bit physical address of FACS */ |
198 | u64 Xdsdt; /* 64-bit physical address of DSDT */ | 192 | u64 Xdsdt; /* 64-bit physical address of DSDT */ |
199 | struct acpi_generic_address xpm1a_evt_blk; /* Extended Power Mgt 1a acpi_event Reg Blk address */ | 193 | struct acpi_generic_address xpm1a_evt_blk; /* Extended Power Mgt 1a acpi_event Reg Blk address */ |
200 | struct acpi_generic_address xpm1b_evt_blk; /* Extended Power Mgt 1b acpi_event Reg Blk address */ | 194 | struct acpi_generic_address xpm1b_evt_blk; /* Extended Power Mgt 1b acpi_event Reg Blk address */ |
201 | struct acpi_generic_address xpm1a_cnt_blk; /* Extended Power Mgt 1a Control Reg Blk address */ | 195 | struct acpi_generic_address xpm1a_cnt_blk; /* Extended Power Mgt 1a Control Reg Blk address */ |
202 | struct acpi_generic_address xpm1b_cnt_blk; /* Extended Power Mgt 1b Control Reg Blk address */ | 196 | struct acpi_generic_address xpm1b_cnt_blk; /* Extended Power Mgt 1b Control Reg Blk address */ |
203 | struct acpi_generic_address xpm2_cnt_blk; /* Extended Power Mgt 2 Control Reg Blk address */ | 197 | struct acpi_generic_address xpm2_cnt_blk; /* Extended Power Mgt 2 Control Reg Blk address */ |
204 | struct acpi_generic_address xpm_tmr_blk; /* Extended Power Mgt Timer Ctrl Reg Blk address */ | 198 | struct acpi_generic_address xpm_tmr_blk; /* Extended Power Mgt Timer Ctrl Reg Blk address */ |
205 | struct acpi_generic_address xgpe0_blk; /* Extended General Purpose acpi_event 0 Reg Blk address */ | 199 | struct acpi_generic_address xgpe0_blk; /* Extended General Purpose acpi_event 0 Reg Blk address */ |
206 | struct acpi_generic_address xgpe1_blk; /* Extended General Purpose acpi_event 1 Reg Blk address */ | 200 | struct acpi_generic_address xgpe1_blk; /* Extended General Purpose acpi_event 1 Reg Blk address */ |
207 | }; | 201 | }; |
208 | 202 | ||
209 | |||
210 | /* "Down-revved" ACPI 2.0 FADT descriptor */ | 203 | /* "Down-revved" ACPI 2.0 FADT descriptor */ |
211 | 204 | ||
212 | struct fadt_descriptor_rev2_minus | 205 | struct fadt_descriptor_rev2_minus { |
213 | { | 206 | ACPI_TABLE_HEADER_DEF /* ACPI common table header */ |
214 | ACPI_TABLE_HEADER_DEF /* ACPI common table header */ | 207 | FADT_REV2_COMMON u8 reserved2; /* Reserved, must be zero */ |
215 | FADT_REV2_COMMON | 208 | u32 flags; |
216 | u8 reserved2; /* Reserved */ | 209 | struct acpi_generic_address reset_register; /* Reset register address in GAS format */ |
217 | u32 flags; | 210 | u8 reset_value; /* Value to write to the reset_register port to reset the system. */ |
218 | struct acpi_generic_address reset_register; /* Reset register address in GAS format */ | 211 | u8 reserved7[3]; /* Reserved, must be zero */ |
219 | u8 reset_value; /* Value to write to the reset_register port to reset the system. */ | ||
220 | u8 reserved7[3]; /* These three bytes must be zero */ | ||
221 | }; | 212 | }; |
222 | 213 | ||
223 | |||
224 | /* ECDT - Embedded Controller Boot Resources Table */ | 214 | /* ECDT - Embedded Controller Boot Resources Table */ |
225 | 215 | ||
226 | struct ec_boot_resources | 216 | struct ec_boot_resources { |
227 | { | 217 | ACPI_TABLE_HEADER_DEF struct acpi_generic_address ec_control; /* Address of EC command/status register */ |
228 | ACPI_TABLE_HEADER_DEF | 218 | struct acpi_generic_address ec_data; /* Address of EC data register */ |
229 | struct acpi_generic_address ec_control; /* Address of EC command/status register */ | 219 | u32 uid; /* Unique ID - must be same as the EC _UID method */ |
230 | struct acpi_generic_address ec_data; /* Address of EC data register */ | 220 | u8 gpe_bit; /* The GPE for the EC */ |
231 | u32 uid; /* Unique ID - must be same as the EC _UID method */ | 221 | u8 ec_id[1]; /* Full namepath of the EC in the ACPI namespace */ |
232 | u8 gpe_bit; /* The GPE for the EC */ | ||
233 | u8 ec_id[1]; /* Full namepath of the EC in the ACPI namespace */ | ||
234 | }; | 222 | }; |
235 | 223 | ||
236 | |||
237 | /* SRAT - System Resource Affinity Table */ | 224 | /* SRAT - System Resource Affinity Table */ |
238 | 225 | ||
239 | struct static_resource_alloc | 226 | struct static_resource_alloc { |
240 | { | 227 | u8 type; |
241 | u8 type; | 228 | u8 length; |
242 | u8 length; | 229 | u8 proximity_domain_lo; |
243 | u8 proximity_domain_lo; | 230 | u8 apic_id; |
244 | u8 apic_id; | ||
245 | u32 enabled :1; | ||
246 | u32 reserved3 :31; | ||
247 | u8 local_sapic_eid; | ||
248 | u8 proximity_domain_hi[3]; | ||
249 | u32 reserved4; | ||
250 | }; | ||
251 | 231 | ||
252 | struct memory_affinity | 232 | /* Flags (32 bits) */ |
253 | { | 233 | |
254 | u8 type; | 234 | u8 enabled:1; /* 00: Use affinity structure */ |
255 | u8 length; | 235 | u8:7; /* 01-07: Reserved, must be zero */ |
256 | u32 proximity_domain; | 236 | u8 reserved3[3]; /* 08-31: Reserved, must be zero */ |
257 | u16 reserved3; | 237 | |
258 | u64 base_address; | 238 | u8 local_sapic_eid; |
259 | u64 address_length; | 239 | u8 proximity_domain_hi[3]; |
260 | u32 reserved4; | 240 | u32 reserved4; /* Reserved, must be zero */ |
261 | u32 enabled :1; | ||
262 | u32 hot_pluggable :1; | ||
263 | u32 non_volatile :1; | ||
264 | u32 reserved5 :29; | ||
265 | u64 reserved6; | ||
266 | }; | 241 | }; |
267 | 242 | ||
268 | struct system_resource_affinity | 243 | struct memory_affinity { |
269 | { | 244 | u8 type; |
270 | ACPI_TABLE_HEADER_DEF | 245 | u8 length; |
271 | u32 reserved1; /* Must be value '1' */ | 246 | u32 proximity_domain; |
272 | u64 reserved2; | 247 | u16 reserved3; |
248 | u64 base_address; | ||
249 | u64 address_length; | ||
250 | u32 reserved4; | ||
251 | |||
252 | /* Flags (32 bits) */ | ||
253 | |||
254 | u8 enabled:1; /* 00: Use affinity structure */ | ||
255 | u8 hot_pluggable:1; /* 01: Memory region is hot pluggable */ | ||
256 | u8 non_volatile:1; /* 02: Memory is non-volatile */ | ||
257 | u8:5; /* 03-07: Reserved, must be zero */ | ||
258 | u8 reserved5[3]; /* 08-31: Reserved, must be zero */ | ||
259 | |||
260 | u64 reserved6; /* Reserved, must be zero */ | ||
273 | }; | 261 | }; |
274 | 262 | ||
263 | struct system_resource_affinity { | ||
264 | ACPI_TABLE_HEADER_DEF u32 reserved1; /* Must be value '1' */ | ||
265 | u64 reserved2; /* Reserved, must be zero */ | ||
266 | }; | ||
275 | 267 | ||
276 | /* SLIT - System Locality Distance Information Table */ | 268 | /* SLIT - System Locality Distance Information Table */ |
277 | 269 | ||
278 | struct system_locality_info | 270 | struct system_locality_info { |
279 | { | 271 | ACPI_TABLE_HEADER_DEF u64 locality_count; |
280 | ACPI_TABLE_HEADER_DEF | 272 | u8 entry[1][1]; |
281 | u64 locality_count; | ||
282 | u8 entry[1][1]; | ||
283 | }; | 273 | }; |
284 | 274 | ||
285 | |||
286 | #pragma pack() | 275 | #pragma pack() |
287 | 276 | ||
288 | #endif /* __ACTBL2_H__ */ | 277 | #endif /* __ACTBL2_H__ */ |
289 | |||