]>
Commit | Line | Data |
---|---|---|
c5bd6537 BM |
1 | /****************************************************************************** |
2 | * | |
3 | * Name: actbl3.h - ACPI Table Definitions | |
4 | * | |
5 | *****************************************************************************/ | |
6 | ||
7 | /* | |
82a80941 | 8 | * Copyright (C) 2000 - 2015, Intel Corp. |
c5bd6537 BM |
9 | * All rights reserved. |
10 | * | |
11 | * Redistribution and use in source and binary forms, with or without | |
12 | * modification, are permitted provided that the following conditions | |
13 | * are met: | |
14 | * 1. Redistributions of source code must retain the above copyright | |
15 | * notice, this list of conditions, and the following disclaimer, | |
16 | * without modification. | |
17 | * 2. Redistributions in binary form must reproduce at minimum a disclaimer | |
18 | * substantially similar to the "NO WARRANTY" disclaimer below | |
19 | * ("Disclaimer") and any redistribution must be conditioned upon | |
20 | * including a substantially similar Disclaimer requirement for further | |
21 | * binary redistribution. | |
22 | * 3. Neither the names of the above-listed copyright holders nor the names | |
23 | * of any contributors may be used to endorse or promote products derived | |
24 | * from this software without specific prior written permission. | |
25 | * | |
26 | * Alternatively, this software may be distributed under the terms of the | |
27 | * GNU General Public License ("GPL") version 2 as published by the Free | |
28 | * Software Foundation. | |
29 | * | |
30 | * NO WARRANTY | |
31 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS | |
32 | * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT | |
33 | * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR | |
34 | * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT | |
35 | * HOLDERS OR CONTRIBUTORS BE LIABLE FOR SPECIAL, EXEMPLARY, OR CONSEQUENTIAL | |
36 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS | |
37 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) | |
38 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, | |
39 | * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING | |
40 | * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE | |
41 | * POSSIBILITY OF SUCH DAMAGES. | |
42 | */ | |
43 | ||
44 | #ifndef __ACTBL3_H__ | |
45 | #define __ACTBL3_H__ | |
46 | ||
47 | /******************************************************************************* | |
48 | * | |
49 | * Additional ACPI Tables (3) | |
50 | * | |
51 | * These tables are not consumed directly by the ACPICA subsystem, but are | |
52 | * included here to support device drivers and the AML disassembler. | |
53 | * | |
54 | * The tables in this file are fully defined within the ACPI specification. | |
55 | * | |
56 | ******************************************************************************/ | |
57 | ||
58 | /* | |
59 | * Values for description table header signatures for tables defined in this | |
60 | * file. Useful because they make it more difficult to inadvertently type in | |
61 | * the wrong signature. | |
62 | */ | |
63 | #define ACPI_SIG_BGRT "BGRT" /* Boot Graphics Resource Table */ | |
64 | #define ACPI_SIG_DRTM "DRTM" /* Dynamic Root of Trust for Measurement table */ | |
65 | #define ACPI_SIG_FPDT "FPDT" /* Firmware Performance Data Table */ | |
66 | #define ACPI_SIG_GTDT "GTDT" /* Generic Timer Description Table */ | |
67 | #define ACPI_SIG_MPST "MPST" /* Memory Power State Table */ | |
68 | #define ACPI_SIG_PCCT "PCCT" /* Platform Communications Channel Table */ | |
69 | #define ACPI_SIG_PMTT "PMTT" /* Platform Memory Topology Table */ | |
70 | #define ACPI_SIG_RASF "RASF" /* RAS Feature table */ | |
37e12657 | 71 | #define ACPI_SIG_STAO "STAO" /* Status Override table */ |
99c93f55 | 72 | #define ACPI_SIG_TPM2 "TPM2" /* Trusted Platform Module 2.0 H/W interface table */ |
c5bd6537 BM |
73 | |
74 | #define ACPI_SIG_S3PT "S3PT" /* S3 Performance (sub)Table */ | |
75 | #define ACPI_SIG_PCCS "PCC" /* PCC Shared Memory Region */ | |
76 | ||
77 | /* Reserved table signatures */ | |
78 | ||
c5bd6537 BM |
79 | #define ACPI_SIG_MATR "MATR" /* Memory Address Translation Table */ |
80 | #define ACPI_SIG_MSDM "MSDM" /* Microsoft Data Management Table */ | |
81 | #define ACPI_SIG_WPBT "WPBT" /* Windows Platform Binary Table */ | |
82 | ||
83 | /* | |
84 | * All tables must be byte-packed to match the ACPI specification, since | |
85 | * the tables are provided by the system BIOS. | |
86 | */ | |
87 | #pragma pack(1) | |
88 | ||
89 | /* | |
be030a57 BM |
90 | * Note: C bitfields are not used for this reason: |
91 | * | |
92 | * "Bitfields are great and easy to read, but unfortunately the C language | |
93 | * does not specify the layout of bitfields in memory, which means they are | |
94 | * essentially useless for dealing with packed data in on-disk formats or | |
95 | * binary wire protocols." (Or ACPI tables and buffers.) "If you ask me, | |
96 | * this decision was a design error in C. Ritchie could have picked an order | |
97 | * and stuck with it." Norman Ramsey. | |
98 | * See http://stackoverflow.com/a/1053662/41661 | |
c5bd6537 BM |
99 | */ |
100 | ||
101 | /******************************************************************************* | |
102 | * | |
103 | * BGRT - Boot Graphics Resource Table (ACPI 5.0) | |
104 | * Version 1 | |
105 | * | |
106 | ******************************************************************************/ | |
107 | ||
108 | struct acpi_table_bgrt { | |
109 | struct acpi_table_header header; /* Common ACPI table header */ | |
110 | u16 version; | |
111 | u8 status; | |
112 | u8 image_type; | |
113 | u64 image_address; | |
114 | u32 image_offset_x; | |
115 | u32 image_offset_y; | |
116 | }; | |
117 | ||
118 | /******************************************************************************* | |
119 | * | |
120 | * DRTM - Dynamic Root of Trust for Measurement table | |
121 | * | |
122 | ******************************************************************************/ | |
123 | ||
124 | struct acpi_table_drtm { | |
125 | struct acpi_table_header header; /* Common ACPI table header */ | |
126 | u64 entry_base_address; | |
127 | u64 entry_length; | |
128 | u32 entry_address32; | |
129 | u64 entry_address64; | |
130 | u64 exit_address; | |
131 | u64 log_area_address; | |
132 | u32 log_area_length; | |
133 | u64 arch_dependent_address; | |
134 | u32 flags; | |
135 | }; | |
136 | ||
137 | /* 1) Validated Tables List */ | |
138 | ||
139 | struct acpi_drtm_vtl_list { | |
140 | u32 validated_table_list_count; | |
141 | }; | |
142 | ||
143 | /* 2) Resources List */ | |
144 | ||
145 | struct acpi_drtm_resource_list { | |
146 | u32 resource_list_count; | |
147 | }; | |
148 | ||
149 | /* 3) Platform-specific Identifiers List */ | |
150 | ||
151 | struct acpi_drtm_id_list { | |
152 | u32 id_list_count; | |
153 | }; | |
154 | ||
155 | /******************************************************************************* | |
156 | * | |
157 | * FPDT - Firmware Performance Data Table (ACPI 5.0) | |
158 | * Version 1 | |
159 | * | |
160 | ******************************************************************************/ | |
161 | ||
162 | struct acpi_table_fpdt { | |
163 | struct acpi_table_header header; /* Common ACPI table header */ | |
164 | }; | |
165 | ||
166 | /* FPDT subtable header */ | |
167 | ||
168 | struct acpi_fpdt_header { | |
169 | u16 type; | |
170 | u8 length; | |
171 | u8 revision; | |
172 | }; | |
173 | ||
174 | /* Values for Type field above */ | |
175 | ||
176 | enum acpi_fpdt_type { | |
177 | ACPI_FPDT_TYPE_BOOT = 0, | |
6be58e2f | 178 | ACPI_FPDT_TYPE_S3PERF = 1 |
c5bd6537 BM |
179 | }; |
180 | ||
181 | /* | |
182 | * FPDT subtables | |
183 | */ | |
184 | ||
185 | /* 0: Firmware Basic Boot Performance Record */ | |
186 | ||
187 | struct acpi_fpdt_boot { | |
188 | struct acpi_fpdt_header header; | |
189 | u8 reserved[4]; | |
190 | u64 reset_end; | |
191 | u64 load_start; | |
192 | u64 startup_start; | |
193 | u64 exit_services_entry; | |
194 | u64 exit_services_exit; | |
195 | }; | |
196 | ||
197 | /* 1: S3 Performance Table Pointer Record */ | |
198 | ||
199 | struct acpi_fpdt_s3pt_ptr { | |
200 | struct acpi_fpdt_header header; | |
201 | u8 reserved[4]; | |
202 | u64 address; | |
203 | }; | |
204 | ||
205 | /* | |
206 | * S3PT - S3 Performance Table. This table is pointed to by the | |
207 | * FPDT S3 Pointer Record above. | |
208 | */ | |
209 | struct acpi_table_s3pt { | |
210 | u8 signature[4]; /* "S3PT" */ | |
211 | u32 length; | |
212 | }; | |
213 | ||
214 | /* | |
215 | * S3PT Subtables | |
216 | */ | |
217 | struct acpi_s3pt_header { | |
218 | u16 type; | |
219 | u8 length; | |
220 | u8 revision; | |
221 | }; | |
222 | ||
223 | /* Values for Type field above */ | |
224 | ||
225 | enum acpi_s3pt_type { | |
226 | ACPI_S3PT_TYPE_RESUME = 0, | |
6be58e2f | 227 | ACPI_S3PT_TYPE_SUSPEND = 1 |
c5bd6537 BM |
228 | }; |
229 | ||
230 | struct acpi_s3pt_resume { | |
231 | struct acpi_s3pt_header header; | |
232 | u32 resume_count; | |
233 | u64 full_resume; | |
234 | u64 average_resume; | |
235 | }; | |
236 | ||
237 | struct acpi_s3pt_suspend { | |
238 | struct acpi_s3pt_header header; | |
239 | u64 suspend_start; | |
240 | u64 suspend_end; | |
241 | }; | |
242 | ||
243 | /******************************************************************************* | |
244 | * | |
54ea4247 TN |
245 | * GTDT - Generic Timer Description Table (ACPI 5.1) |
246 | * Version 2 | |
c5bd6537 BM |
247 | * |
248 | ******************************************************************************/ | |
249 | ||
250 | struct acpi_table_gtdt { | |
251 | struct acpi_table_header header; /* Common ACPI table header */ | |
54ea4247 TN |
252 | u64 counter_block_addresss; |
253 | u32 reserved; | |
254 | u32 secure_el1_interrupt; | |
255 | u32 secure_el1_flags; | |
256 | u32 non_secure_el1_interrupt; | |
257 | u32 non_secure_el1_flags; | |
c5bd6537 BM |
258 | u32 virtual_timer_interrupt; |
259 | u32 virtual_timer_flags; | |
54ea4247 TN |
260 | u32 non_secure_el2_interrupt; |
261 | u32 non_secure_el2_flags; | |
262 | u64 counter_read_block_address; | |
263 | u32 platform_timer_count; | |
264 | u32 platform_timer_offset; | |
265 | }; | |
266 | ||
267 | /* Flag Definitions: Timer Block Physical Timers and Virtual timers */ | |
268 | ||
269 | #define ACPI_GTDT_INTERRUPT_MODE (1) | |
270 | #define ACPI_GTDT_INTERRUPT_POLARITY (1<<1) | |
271 | #define ACPI_GTDT_ALWAYS_ON (1<<2) | |
272 | ||
273 | /* Common GTDT subtable header */ | |
274 | ||
275 | struct acpi_gtdt_header { | |
276 | u8 type; | |
277 | u16 length; | |
278 | }; | |
279 | ||
280 | /* Values for GTDT subtable type above */ | |
281 | ||
282 | enum acpi_gtdt_type { | |
283 | ACPI_GTDT_TYPE_TIMER_BLOCK = 0, | |
284 | ACPI_GTDT_TYPE_WATCHDOG = 1, | |
285 | ACPI_GTDT_TYPE_RESERVED = 2 /* 2 and greater are reserved */ | |
c5bd6537 BM |
286 | }; |
287 | ||
54ea4247 TN |
288 | /* GTDT Subtables, correspond to Type in struct acpi_gtdt_header */ |
289 | ||
290 | /* 0: Generic Timer Block */ | |
c5bd6537 | 291 | |
54ea4247 TN |
292 | struct acpi_gtdt_timer_block { |
293 | struct acpi_gtdt_header header; | |
294 | u8 reserved; | |
295 | u64 block_address; | |
296 | u32 timer_count; | |
297 | u32 timer_offset; | |
298 | }; | |
299 | ||
300 | /* Timer Sub-Structure, one per timer */ | |
301 | ||
302 | struct acpi_gtdt_timer_entry { | |
303 | u8 frame_number; | |
304 | u8 reserved[3]; | |
305 | u64 base_address; | |
306 | u64 el0_base_address; | |
307 | u32 timer_interrupt; | |
308 | u32 timer_flags; | |
309 | u32 virtual_timer_interrupt; | |
310 | u32 virtual_timer_flags; | |
311 | u32 common_flags; | |
312 | }; | |
313 | ||
34ea065e HG |
314 | /* Flag Definitions: timer_flags and virtual_timer_flags above */ |
315 | ||
316 | #define ACPI_GTDT_GT_IRQ_MODE (1) | |
317 | #define ACPI_GTDT_GT_IRQ_POLARITY (1<<1) | |
318 | ||
54ea4247 TN |
319 | /* Flag Definitions: common_flags above */ |
320 | ||
34ea065e HG |
321 | #define ACPI_GTDT_GT_IS_SECURE_TIMER (1) |
322 | #define ACPI_GTDT_GT_ALWAYS_ON (1<<1) | |
54ea4247 TN |
323 | |
324 | /* 1: SBSA Generic Watchdog Structure */ | |
325 | ||
326 | struct acpi_gtdt_watchdog { | |
327 | struct acpi_gtdt_header header; | |
328 | u8 reserved; | |
329 | u64 refresh_frame_address; | |
330 | u64 control_frame_address; | |
331 | u32 timer_interrupt; | |
332 | u32 timer_flags; | |
333 | }; | |
c5bd6537 | 334 | |
54ea4247 | 335 | /* Flag Definitions: timer_flags above */ |
c5bd6537 | 336 | |
54ea4247 TN |
337 | #define ACPI_GTDT_WATCHDOG_IRQ_MODE (1) |
338 | #define ACPI_GTDT_WATCHDOG_IRQ_POLARITY (1<<1) | |
339 | #define ACPI_GTDT_WATCHDOG_SECURE (1<<2) | |
c5bd6537 BM |
340 | |
341 | /******************************************************************************* | |
342 | * | |
343 | * MPST - Memory Power State Table (ACPI 5.0) | |
344 | * Version 1 | |
345 | * | |
346 | ******************************************************************************/ | |
347 | ||
348 | #define ACPI_MPST_CHANNEL_INFO \ | |
c5bd6537 | 349 | u8 channel_id; \ |
2d2dd508 BM |
350 | u8 reserved1[3]; \ |
351 | u16 power_node_count; \ | |
352 | u16 reserved2; | |
c5bd6537 BM |
353 | |
354 | /* Main table */ | |
355 | ||
356 | struct acpi_table_mpst { | |
357 | struct acpi_table_header header; /* Common ACPI table header */ | |
358 | ACPI_MPST_CHANNEL_INFO /* Platform Communication Channel */ | |
359 | }; | |
360 | ||
361 | /* Memory Platform Communication Channel Info */ | |
362 | ||
363 | struct acpi_mpst_channel { | |
364 | ACPI_MPST_CHANNEL_INFO /* Platform Communication Channel */ | |
365 | }; | |
366 | ||
367 | /* Memory Power Node Structure */ | |
368 | ||
369 | struct acpi_mpst_power_node { | |
370 | u8 flags; | |
371 | u8 reserved1; | |
372 | u16 node_id; | |
373 | u32 length; | |
374 | u64 range_address; | |
375 | u64 range_length; | |
2d2dd508 BM |
376 | u32 num_power_states; |
377 | u32 num_physical_components; | |
c5bd6537 BM |
378 | }; |
379 | ||
380 | /* Values for Flags field above */ | |
381 | ||
382 | #define ACPI_MPST_ENABLED 1 | |
383 | #define ACPI_MPST_POWER_MANAGED 2 | |
384 | #define ACPI_MPST_HOT_PLUG_CAPABLE 4 | |
385 | ||
386 | /* Memory Power State Structure (follows POWER_NODE above) */ | |
387 | ||
388 | struct acpi_mpst_power_state { | |
389 | u8 power_state; | |
390 | u8 info_index; | |
391 | }; | |
392 | ||
393 | /* Physical Component ID Structure (follows POWER_STATE above) */ | |
394 | ||
395 | struct acpi_mpst_component { | |
396 | u16 component_id; | |
397 | }; | |
398 | ||
399 | /* Memory Power State Characteristics Structure (follows all POWER_NODEs) */ | |
400 | ||
401 | struct acpi_mpst_data_hdr { | |
402 | u16 characteristics_count; | |
2d2dd508 | 403 | u16 reserved; |
c5bd6537 BM |
404 | }; |
405 | ||
406 | struct acpi_mpst_power_data { | |
2d2dd508 | 407 | u8 structure_id; |
c5bd6537 BM |
408 | u8 flags; |
409 | u16 reserved1; | |
410 | u32 average_power; | |
411 | u32 power_saving; | |
412 | u64 exit_latency; | |
413 | u64 reserved2; | |
414 | }; | |
415 | ||
416 | /* Values for Flags field above */ | |
417 | ||
418 | #define ACPI_MPST_PRESERVE 1 | |
419 | #define ACPI_MPST_AUTOENTRY 2 | |
420 | #define ACPI_MPST_AUTOEXIT 4 | |
421 | ||
422 | /* Shared Memory Region (not part of an ACPI table) */ | |
423 | ||
424 | struct acpi_mpst_shared { | |
425 | u32 signature; | |
426 | u16 pcc_command; | |
427 | u16 pcc_status; | |
2d2dd508 BM |
428 | u32 command_register; |
429 | u32 status_register; | |
430 | u32 power_state_id; | |
431 | u32 power_node_id; | |
c5bd6537 BM |
432 | u64 energy_consumed; |
433 | u64 average_power; | |
434 | }; | |
435 | ||
436 | /******************************************************************************* | |
437 | * | |
438 | * PCCT - Platform Communications Channel Table (ACPI 5.0) | |
439 | * Version 1 | |
440 | * | |
441 | ******************************************************************************/ | |
442 | ||
443 | struct acpi_table_pcct { | |
444 | struct acpi_table_header header; /* Common ACPI table header */ | |
445 | u32 flags; | |
f0d73664 | 446 | u64 reserved; |
c5bd6537 BM |
447 | }; |
448 | ||
449 | /* Values for Flags field above */ | |
450 | ||
451 | #define ACPI_PCCT_DOORBELL 1 | |
452 | ||
f0d73664 BM |
453 | /* Values for subtable type in struct acpi_subtable_header */ |
454 | ||
455 | enum acpi_pcct_type { | |
456 | ACPI_PCCT_TYPE_GENERIC_SUBSPACE = 0, | |
67a3d620 BM |
457 | ACPI_PCCT_TYPE_HW_REDUCED_SUBSPACE = 1, |
458 | ACPI_PCCT_TYPE_RESERVED = 2 /* 2 and greater are reserved */ | |
f0d73664 BM |
459 | }; |
460 | ||
c5bd6537 | 461 | /* |
f0d73664 | 462 | * PCCT Subtables, correspond to Type in struct acpi_subtable_header |
c5bd6537 BM |
463 | */ |
464 | ||
465 | /* 0: Generic Communications Subspace */ | |
466 | ||
467 | struct acpi_pcct_subspace { | |
468 | struct acpi_subtable_header header; | |
469 | u8 reserved[6]; | |
470 | u64 base_address; | |
471 | u64 length; | |
472 | struct acpi_generic_address doorbell_register; | |
473 | u64 preserve_mask; | |
474 | u64 write_mask; | |
f0d73664 BM |
475 | u32 latency; |
476 | u32 max_access_rate; | |
477 | u16 min_turnaround_time; | |
c5bd6537 BM |
478 | }; |
479 | ||
67a3d620 BM |
480 | /* 1: HW-reduced Communications Subspace (ACPI 5.1) */ |
481 | ||
482 | struct acpi_pcct_hw_reduced { | |
483 | struct acpi_subtable_header header; | |
484 | u32 doorbell_interrupt; | |
485 | u8 flags; | |
486 | u8 reserved; | |
487 | u64 base_address; | |
488 | u64 length; | |
489 | struct acpi_generic_address doorbell_register; | |
490 | u64 preserve_mask; | |
491 | u64 write_mask; | |
492 | u32 latency; | |
493 | u32 max_access_rate; | |
494 | u16 min_turnaround_time; | |
495 | }; | |
496 | ||
497 | /* Values for doorbell flags above */ | |
498 | ||
499 | #define ACPI_PCCT_INTERRUPT_POLARITY (1) | |
500 | #define ACPI_PCCT_INTERRUPT_MODE (1<<1) | |
501 | ||
c5bd6537 BM |
502 | /* |
503 | * PCC memory structures (not part of the ACPI table) | |
504 | */ | |
505 | ||
506 | /* Shared Memory Region */ | |
507 | ||
508 | struct acpi_pcct_shared_memory { | |
509 | u32 signature; | |
510 | u16 command; | |
511 | u16 status; | |
512 | }; | |
513 | ||
514 | /******************************************************************************* | |
515 | * | |
516 | * PMTT - Platform Memory Topology Table (ACPI 5.0) | |
517 | * Version 1 | |
518 | * | |
519 | ******************************************************************************/ | |
520 | ||
521 | struct acpi_table_pmtt { | |
522 | struct acpi_table_header header; /* Common ACPI table header */ | |
523 | u32 reserved; | |
524 | }; | |
525 | ||
526 | /* Common header for PMTT subtables that follow main table */ | |
527 | ||
528 | struct acpi_pmtt_header { | |
529 | u8 type; | |
530 | u8 reserved1; | |
531 | u16 length; | |
532 | u16 flags; | |
533 | u16 reserved2; | |
534 | }; | |
535 | ||
536 | /* Values for Type field above */ | |
537 | ||
538 | #define ACPI_PMTT_TYPE_SOCKET 0 | |
539 | #define ACPI_PMTT_TYPE_CONTROLLER 1 | |
540 | #define ACPI_PMTT_TYPE_DIMM 2 | |
541 | #define ACPI_PMTT_TYPE_RESERVED 3 /* 0x03-0xFF are reserved */ | |
542 | ||
543 | /* Values for Flags field above */ | |
544 | ||
545 | #define ACPI_PMTT_TOP_LEVEL 0x0001 | |
546 | #define ACPI_PMTT_PHYSICAL 0x0002 | |
547 | #define ACPI_PMTT_MEMORY_TYPE 0x000C | |
548 | ||
549 | /* | |
550 | * PMTT subtables, correspond to Type in struct acpi_pmtt_header | |
551 | */ | |
552 | ||
553 | /* 0: Socket Structure */ | |
554 | ||
555 | struct acpi_pmtt_socket { | |
556 | struct acpi_pmtt_header header; | |
557 | u16 socket_id; | |
558 | u16 reserved; | |
559 | }; | |
560 | ||
561 | /* 1: Memory Controller subtable */ | |
562 | ||
563 | struct acpi_pmtt_controller { | |
564 | struct acpi_pmtt_header header; | |
565 | u32 read_latency; | |
566 | u32 write_latency; | |
567 | u32 read_bandwidth; | |
568 | u32 write_bandwidth; | |
569 | u16 access_width; | |
570 | u16 alignment; | |
571 | u16 reserved; | |
572 | u16 domain_count; | |
573 | }; | |
574 | ||
575 | /* 1a: Proximity Domain substructure */ | |
576 | ||
577 | struct acpi_pmtt_domain { | |
578 | u32 proximity_domain; | |
579 | }; | |
580 | ||
581 | /* 2: Physical Component Identifier (DIMM) */ | |
582 | ||
583 | struct acpi_pmtt_physical_component { | |
584 | struct acpi_pmtt_header header; | |
585 | u16 component_id; | |
586 | u16 reserved; | |
587 | u32 memory_size; | |
588 | u32 bios_handle; | |
589 | }; | |
590 | ||
591 | /******************************************************************************* | |
592 | * | |
593 | * RASF - RAS Feature Table (ACPI 5.0) | |
594 | * Version 1 | |
595 | * | |
596 | ******************************************************************************/ | |
597 | ||
598 | struct acpi_table_rasf { | |
599 | struct acpi_table_header header; /* Common ACPI table header */ | |
600 | u8 channel_id[12]; | |
601 | }; | |
602 | ||
603 | /* RASF Platform Communication Channel Shared Memory Region */ | |
604 | ||
605 | struct acpi_rasf_shared_memory { | |
606 | u32 signature; | |
607 | u16 command; | |
608 | u16 status; | |
8c280914 LZ |
609 | u16 version; |
610 | u8 capabilities[16]; | |
611 | u8 set_capabilities[16]; | |
612 | u16 num_parameter_blocks; | |
613 | u32 set_capabilities_status; | |
614 | }; | |
615 | ||
616 | /* RASF Parameter Block Structure Header */ | |
617 | ||
618 | struct acpi_rasf_parameter_block { | |
619 | u16 type; | |
620 | u16 version; | |
621 | u16 length; | |
622 | }; | |
623 | ||
624 | /* RASF Parameter Block Structure for PATROL_SCRUB */ | |
625 | ||
626 | struct acpi_rasf_patrol_scrub_parameter { | |
627 | struct acpi_rasf_parameter_block header; | |
628 | u16 patrol_scrub_command; | |
629 | u64 requested_address_range[2]; | |
630 | u64 actual_address_range[2]; | |
c5bd6537 | 631 | u16 flags; |
8c280914 | 632 | u8 requested_speed; |
c5bd6537 BM |
633 | }; |
634 | ||
635 | /* Masks for Flags and Speed fields above */ | |
636 | ||
637 | #define ACPI_RASF_SCRUBBER_RUNNING 1 | |
638 | #define ACPI_RASF_SPEED (7<<1) | |
8c280914 LZ |
639 | #define ACPI_RASF_SPEED_SLOW (0<<1) |
640 | #define ACPI_RASF_SPEED_MEDIUM (4<<1) | |
641 | #define ACPI_RASF_SPEED_FAST (7<<1) | |
c5bd6537 BM |
642 | |
643 | /* Channel Commands */ | |
644 | ||
645 | enum acpi_rasf_commands { | |
8c280914 LZ |
646 | ACPI_RASF_EXECUTE_RASF_COMMAND = 1 |
647 | }; | |
648 | ||
649 | /* Platform RAS Capabilities */ | |
650 | ||
651 | enum acpi_rasf_capabiliities { | |
652 | ACPI_HW_PATROL_SCRUB_SUPPORTED = 0, | |
653 | ACPI_SW_PATROL_SCRUB_EXPOSED = 1 | |
654 | }; | |
655 | ||
656 | /* Patrol Scrub Commands */ | |
657 | ||
658 | enum acpi_rasf_patrol_scrub_commands { | |
659 | ACPI_RASF_GET_PATROL_PARAMETERS = 1, | |
660 | ACPI_RASF_START_PATROL_SCRUBBER = 2, | |
661 | ACPI_RASF_STOP_PATROL_SCRUBBER = 3 | |
c5bd6537 BM |
662 | }; |
663 | ||
664 | /* Channel Command flags */ | |
665 | ||
666 | #define ACPI_RASF_GENERATE_SCI (1<<15) | |
667 | ||
668 | /* Status values */ | |
669 | ||
670 | enum acpi_rasf_status { | |
671 | ACPI_RASF_SUCCESS = 0, | |
672 | ACPI_RASF_NOT_VALID = 1, | |
673 | ACPI_RASF_NOT_SUPPORTED = 2, | |
674 | ACPI_RASF_BUSY = 3, | |
675 | ACPI_RASF_FAILED = 4, | |
676 | ACPI_RASF_ABORTED = 5, | |
677 | ACPI_RASF_INVALID_DATA = 6 | |
678 | }; | |
679 | ||
680 | /* Status flags */ | |
681 | ||
682 | #define ACPI_RASF_COMMAND_COMPLETE (1) | |
683 | #define ACPI_RASF_SCI_DOORBELL (1<<1) | |
684 | #define ACPI_RASF_ERROR (1<<2) | |
685 | #define ACPI_RASF_STATUS (0x1F<<3) | |
686 | ||
37e12657 BM |
687 | /******************************************************************************* |
688 | * | |
689 | * STAO - Status Override Table (_STA override) - ACPI 6.0 | |
690 | * Version 1 | |
691 | * | |
692 | * Conforms to "ACPI Specification for Status Override Table" | |
693 | * 6 January 2015 | |
694 | * | |
695 | ******************************************************************************/ | |
696 | ||
697 | struct acpi_table_stao { | |
698 | struct acpi_table_header header; /* Common ACPI table header */ | |
699 | u8 ignore_uart; | |
700 | }; | |
701 | ||
99c93f55 BM |
702 | /******************************************************************************* |
703 | * | |
704 | * TPM2 - Trusted Platform Module (TPM) 2.0 Hardware Interface Table | |
705 | * Version 3 | |
706 | * | |
707 | * Conforms to "TPM 2.0 Hardware Interface Table (TPM2)" 29 November 2011 | |
708 | * | |
709 | ******************************************************************************/ | |
710 | ||
711 | struct acpi_table_tpm2 { | |
712 | struct acpi_table_header header; /* Common ACPI table header */ | |
713 | u32 flags; | |
714 | u64 control_address; | |
715 | u32 start_method; | |
716 | }; | |
717 | ||
718 | /* Control area structure (not part of table, pointed to by control_address) */ | |
719 | ||
720 | struct acpi_tpm2_control { | |
721 | u32 reserved; | |
722 | u32 error; | |
723 | u32 cancel; | |
724 | u32 start; | |
725 | u64 interrupt_control; | |
726 | u32 command_size; | |
727 | u64 command_address; | |
728 | u32 response_size; | |
729 | u64 response_address; | |
730 | }; | |
731 | ||
6e596084 RM |
732 | /* Reset to default packing */ |
733 | ||
734 | #pragma pack() | |
c5bd6537 BM |
735 | |
736 | #endif /* __ACTBL3_H__ */ |