iPXE
Acpi20.h
Go to the documentation of this file.
1/** @file
2 ACPI 2.0 definitions from the ACPI Specification, revision 2.0
3
4 Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
5 SPDX-License-Identifier: BSD-2-Clause-Patent
6**/
7
8#ifndef _ACPI_2_0_H_
9#define _ACPI_2_0_H_
10
11FILE_LICENCE ( BSD2_PATENT );
12FILE_SECBOOT ( PERMITTED );
13
15
16//
17// Define for Descriptor
18//
19#define ACPI_LARGE_GENERIC_REGISTER_DESCRIPTOR_NAME 0x02
20
21#define ACPI_GENERIC_REGISTER_DESCRIPTOR 0x82
22
23//
24// Ensure proper structure formats
25//
26#pragma pack(1)
27
28///
29/// Generic Register Descriptor
30///
31typedef PACKED struct {
39
40#pragma pack()
41
42//
43// Ensure proper structure formats
44//
45#pragma pack(1)
46
47///
48/// ACPI 2.0 Generic Address Space definition
49///
57
58//
59// Generic Address Space Address IDs
60//
61#define EFI_ACPI_2_0_SYSTEM_MEMORY 0
62#define EFI_ACPI_2_0_SYSTEM_IO 1
63#define EFI_ACPI_2_0_PCI_CONFIGURATION_SPACE 2
64#define EFI_ACPI_2_0_EMBEDDED_CONTROLLER 3
65#define EFI_ACPI_2_0_SMBUS 4
66#define EFI_ACPI_2_0_FUNCTIONAL_FIXED_HARDWARE 0x7F
67
68//
69// ACPI 2.0 table structures
70//
71
72///
73/// Root System Description Pointer Structure
74///
86
87///
88/// RSD_PTR Revision (as defined in ACPI 2.0 spec.)
89///
90#define EFI_ACPI_2_0_ROOT_SYSTEM_DESCRIPTION_POINTER_REVISION 0x02
91
92///
93/// Common table header, this prefaces all ACPI tables, including FACS, but
94/// excluding the RSD PTR structure
95///
100
101//
102// Root System Description Table
103// No definition needed as it is a common description table header, the same with
104// EFI_ACPI_DESCRIPTION_HEADER, followed by a variable number of UINT32 table pointers.
105//
106
107///
108/// RSDT Revision (as defined in ACPI 2.0 spec.)
109///
110#define EFI_ACPI_2_0_ROOT_SYSTEM_DESCRIPTION_TABLE_REVISION 0x01
111
112//
113// Extended System Description Table
114// No definition needed as it is a common description table header, the same with
115// EFI_ACPI_DESCRIPTION_HEADER, followed by a variable number of UINT64 table pointers.
116//
117
118///
119/// XSDT Revision (as defined in ACPI 2.0 spec.)
120///
121#define EFI_ACPI_2_0_EXTENDED_SYSTEM_DESCRIPTION_TABLE_REVISION 0x01
122
123///
124/// Fixed ACPI Description Table Structure (FADT)
125///
126typedef struct {
180
181///
182/// FADT Version (as defined in ACPI 2.0 spec.)
183///
184#define EFI_ACPI_2_0_FIXED_ACPI_DESCRIPTION_TABLE_REVISION 0x03
185
186//
187// Fixed ACPI Description Table Preferred Power Management Profile
188//
189#define EFI_ACPI_2_0_PM_PROFILE_UNSPECIFIED 0
190#define EFI_ACPI_2_0_PM_PROFILE_DESKTOP 1
191#define EFI_ACPI_2_0_PM_PROFILE_MOBILE 2
192#define EFI_ACPI_2_0_PM_PROFILE_WORKSTATION 3
193#define EFI_ACPI_2_0_PM_PROFILE_ENTERPRISE_SERVER 4
194#define EFI_ACPI_2_0_PM_PROFILE_SOHO_SERVER 5
195#define EFI_ACPI_2_0_PM_PROFILE_APPLIANCE_PC 6
196
197//
198// Fixed ACPI Description Table Boot Architecture Flags
199// All other bits are reserved and must be set to 0.
200//
201#define EFI_ACPI_2_0_LEGACY_DEVICES BIT0
202#define EFI_ACPI_2_0_8042 BIT1
203
204//
205// Fixed ACPI Description Table Fixed Feature Flags
206// All other bits are reserved and must be set to 0.
207//
208#define EFI_ACPI_2_0_WBINVD BIT0
209#define EFI_ACPI_2_0_WBINVD_FLUSH BIT1
210#define EFI_ACPI_2_0_PROC_C1 BIT2
211#define EFI_ACPI_2_0_P_LVL2_UP BIT3
212#define EFI_ACPI_2_0_PWR_BUTTON BIT4
213#define EFI_ACPI_2_0_SLP_BUTTON BIT5
214#define EFI_ACPI_2_0_FIX_RTC BIT6
215#define EFI_ACPI_2_0_RTC_S4 BIT7
216#define EFI_ACPI_2_0_TMR_VAL_EXT BIT8
217#define EFI_ACPI_2_0_DCK_CAP BIT9
218#define EFI_ACPI_2_0_RESET_REG_SUP BIT10
219#define EFI_ACPI_2_0_SEALED_CASE BIT11
220#define EFI_ACPI_2_0_HEADLESS BIT12
221#define EFI_ACPI_2_0_CPU_SW_SLP BIT13
222
223///
224/// Firmware ACPI Control Structure
225///
237
238///
239/// FACS Version (as defined in ACPI 2.0 spec.)
240///
241#define EFI_ACPI_2_0_FIRMWARE_ACPI_CONTROL_STRUCTURE_VERSION 0x01
242
243///
244/// Firmware Control Structure Feature Flags
245/// All other bits are reserved and must be set to 0.
246///
247#define EFI_ACPI_2_0_S4BIOS_F BIT0
248
249///
250/// Multiple APIC Description Table header definition. The rest of the table
251/// must be defined in a platform specific manner.
252///
258
259///
260/// MADT Revision (as defined in ACPI 2.0 spec.)
261///
262#define EFI_ACPI_2_0_MULTIPLE_APIC_DESCRIPTION_TABLE_REVISION 0x01
263
264///
265/// Multiple APIC Flags
266/// All other bits are reserved and must be set to 0.
267///
268#define EFI_ACPI_2_0_PCAT_COMPAT BIT0
269
270//
271// Multiple APIC Description Table APIC structure types
272// All other values between 0x09 an 0xFF are reserved and
273// will be ignored by OSPM.
274//
275#define EFI_ACPI_2_0_PROCESSOR_LOCAL_APIC 0x00
276#define EFI_ACPI_2_0_IO_APIC 0x01
277#define EFI_ACPI_2_0_INTERRUPT_SOURCE_OVERRIDE 0x02
278#define EFI_ACPI_2_0_NON_MASKABLE_INTERRUPT_SOURCE 0x03
279#define EFI_ACPI_2_0_LOCAL_APIC_NMI 0x04
280#define EFI_ACPI_2_0_LOCAL_APIC_ADDRESS_OVERRIDE 0x05
281#define EFI_ACPI_2_0_IO_SAPIC 0x06
282#define EFI_ACPI_2_0_PROCESSOR_LOCAL_SAPIC 0x07
283#define EFI_ACPI_2_0_PLATFORM_INTERRUPT_SOURCES 0x08
284
285//
286// APIC Structure Definitions
287//
288
289///
290/// Processor Local APIC Structure Definition
291///
299
300///
301/// Local APIC Flags. All other bits are reserved and must be 0.
302///
303#define EFI_ACPI_2_0_LOCAL_APIC_ENABLED BIT0
304
305///
306/// IO APIC Structure
307///
316
317///
318/// Interrupt Source Override Structure
319///
328
329///
330/// Non-Maskable Interrupt Source Structure
331///
338
339///
340/// Local APIC NMI Structure
341///
349
350///
351/// Local APIC Address Override Structure
352///
359
360///
361/// IO SAPIC Structure
362///
371
372///
373/// Local SAPIC Structure
374///
384
385///
386/// Platform Interrupt Sources Structure
387///
399
400///
401/// Smart Battery Description Table (SBST)
402///
409
410///
411/// SBST Version (as defined in ACPI 2.0 spec.)
412///
413#define EFI_ACPI_2_0_SMART_BATTERY_DESCRIPTION_TABLE_REVISION 0x01
414
415///
416/// Embedded Controller Boot Resources Table (ECDT)
417/// The table is followed by a null terminated ASCII string that contains
418/// a fully qualified reference to the name space object.
419///
427
428///
429/// ECDT Version (as defined in ACPI 2.0 spec.)
430///
431#define EFI_ACPI_2_0_EMBEDDED_CONTROLLER_BOOT_RESOURCES_TABLE_REVISION 0x01
432
433//
434// Known table signatures
435//
436
437///
438/// "RSD PTR " Root System Description Pointer
439///
440#define EFI_ACPI_2_0_ROOT_SYSTEM_DESCRIPTION_POINTER_SIGNATURE SIGNATURE_64('R', 'S', 'D', ' ', 'P', 'T', 'R', ' ')
441
442///
443/// "SPIC" Multiple SAPIC Description Table
444///
445/// BUGBUG: Don't know where this came from except SR870BN4 uses it.
446/// #define EFI_ACPI_2_0_MULTIPLE_SAPIC_DESCRIPTION_TABLE_SIGNATURE 0x43495053
447///
448#define EFI_ACPI_2_0_MULTIPLE_SAPIC_DESCRIPTION_TABLE_SIGNATURE SIGNATURE_32('A', 'P', 'I', 'C')
449
450///
451/// "BOOT" MS Simple Boot Spec
452///
453#define EFI_ACPI_2_0_SIMPLE_BOOT_FLAG_TABLE_SIGNATURE SIGNATURE_32('B', 'O', 'O', 'T')
454
455///
456/// "DBGP" MS Bebug Port Spec
457///
458#define EFI_ACPI_2_0_DEBUG_PORT_TABLE_SIGNATURE SIGNATURE_32('D', 'B', 'G', 'P')
459
460///
461/// "DSDT" Differentiated System Description Table
462///
463#define EFI_ACPI_2_0_DIFFERENTIATED_SYSTEM_DESCRIPTION_TABLE_SIGNATURE SIGNATURE_32('D', 'S', 'D', 'T')
464
465///
466/// "ECDT" Embedded Controller Boot Resources Table
467///
468#define EFI_ACPI_2_0_EMBEDDED_CONTROLLER_BOOT_RESOURCES_TABLE_SIGNATURE SIGNATURE_32('E', 'C', 'D', 'T')
469
470///
471/// "ETDT" Event Timer Description Table
472///
473#define EFI_ACPI_2_0_EVENT_TIMER_DESCRIPTION_TABLE_SIGNATURE SIGNATURE_32('E', 'T', 'D', 'T')
474
475///
476/// "FACS" Firmware ACPI Control Structure
477///
478#define EFI_ACPI_2_0_FIRMWARE_ACPI_CONTROL_STRUCTURE_SIGNATURE SIGNATURE_32('F', 'A', 'C', 'S')
479
480///
481/// "FACP" Fixed ACPI Description Table
482///
483#define EFI_ACPI_2_0_FIXED_ACPI_DESCRIPTION_TABLE_SIGNATURE SIGNATURE_32('F', 'A', 'C', 'P')
484
485///
486/// "APIC" Multiple APIC Description Table
487///
488#define EFI_ACPI_2_0_MULTIPLE_APIC_DESCRIPTION_TABLE_SIGNATURE SIGNATURE_32('A', 'P', 'I', 'C')
489
490///
491/// "PSDT" Persistent System Description Table
492///
493#define EFI_ACPI_2_0_PERSISTENT_SYSTEM_DESCRIPTION_TABLE_SIGNATURE SIGNATURE_32('P', 'S', 'D', 'T')
494
495///
496/// "RSDT" Root System Description Table
497///
498#define EFI_ACPI_2_0_ROOT_SYSTEM_DESCRIPTION_TABLE_SIGNATURE SIGNATURE_32('R', 'S', 'D', 'T')
499
500///
501/// "SBST" Smart Battery Specification Table
502///
503#define EFI_ACPI_2_0_SMART_BATTERY_SPECIFICATION_TABLE_SIGNATURE SIGNATURE_32('S', 'B', 'S', 'T')
504
505///
506/// "SLIT" System Locality Information Table
507///
508#define EFI_ACPI_2_0_SYSTEM_LOCALITY_INFORMATION_TABLE_SIGNATURE SIGNATURE_32('S', 'L', 'I', 'T')
509
510///
511/// "SPCR" Serial Port Console Redirection Table
512///
513#define EFI_ACPI_2_0_SERIAL_PORT_CONSOLE_REDIRECTION_TABLE_SIGNATURE SIGNATURE_32('S', 'P', 'C', 'R')
514
515///
516/// "SRAT" Static Resource Affinity Table
517///
518#define EFI_ACPI_2_0_STATIC_RESOURCE_AFFINITY_TABLE_SIGNATURE SIGNATURE_32('S', 'R', 'A', 'T')
519
520///
521/// "SSDT" Secondary System Description Table
522///
523#define EFI_ACPI_2_0_SECONDARY_SYSTEM_DESCRIPTION_TABLE_SIGNATURE SIGNATURE_32('S', 'S', 'D', 'T')
524
525///
526/// "SPMI" Server Platform Management Interface Table
527///
528#define EFI_ACPI_2_0_SERVER_PLATFORM_MANAGEMENT_INTERFACE_SIGNATURE SIGNATURE_32('S', 'P', 'M', 'I')
529
530///
531/// "XSDT" Extended System Description Table
532///
533#define EFI_ACPI_2_0_EXTENDED_SYSTEM_DESCRIPTION_TABLE_SIGNATURE SIGNATURE_32('X', 'S', 'D', 'T')
534
535///
536/// "MCFG" PCI Express Memory Mapped Configuration Space Base Address Description Table
537///
538#define EFI_ACPI_2_0_MEMORY_MAPPED_CONFIGURATION_BASE_ADDRESS_TABLE_SIGNATURE SIGNATURE_32('M', 'C', 'F', 'G')
539
540#pragma pack()
541
542#endif
unsigned short UINT16
2-byte unsigned value.
unsigned long long UINT64
8-byte unsigned value.
unsigned char UINT8
1-byte unsigned value.
unsigned int UINT32
4-byte unsigned value.
ACPI 1.0b definitions from the ACPI Specification, revision 1.0b.
PACKED struct @165104130223077263224044232125337106163015377141 ACPI_LARGE_RESOURCE_HEADER
PACKED union @165104130223077263224044232125337106163015377141::@273126103036270271166311122320164340317073026312 Header
Definition Acpi10.h:156
UINT64 RegisterAddress
Definition Acpi20.h:37
UINT8 RegisterBitWidth
Definition Acpi20.h:34
UINT8 RegisterBitOffset
Definition Acpi20.h:35
PACKED struct @361334057146262142357026063355075342332166257172 EFI_ACPI_GENERIC_REGISTER_DESCRIPTOR
Generic Register Descriptor.
UINT8 AddressSize
Definition Acpi20.h:36
UINT8 AddressSpaceId
Definition Acpi20.h:33
#define PACKED
Definition Base.h:210
#define FILE_LICENCE(_licence)
Declare a particular licence as applying to a file.
Definition compiler.h:896
#define FILE_SECBOOT(_status)
Declare a file's UEFI Secure Boot permission status.
Definition compiler.h:926
Common table header, this prefaces all ACPI tables, including FACS, but excluding the RSD PTR structu...
Definition Acpi20.h:96
Embedded Controller Boot Resources Table (ECDT) The table is followed by a null terminated ASCII stri...
Definition Acpi20.h:420
EFI_ACPI_2_0_GENERIC_ADDRESS_STRUCTURE EcControl
Definition Acpi20.h:422
EFI_ACPI_2_0_GENERIC_ADDRESS_STRUCTURE EcData
Definition Acpi20.h:423
Firmware ACPI Control Structure.
Definition Acpi20.h:226
Fixed ACPI Description Table Structure (FADT)
Definition Acpi20.h:126
EFI_ACPI_DESCRIPTION_HEADER Header
Definition Acpi20.h:127
EFI_ACPI_2_0_GENERIC_ADDRESS_STRUCTURE XPm2CntBlk
Definition Acpi20.h:175
EFI_ACPI_2_0_GENERIC_ADDRESS_STRUCTURE ResetReg
Definition Acpi20.h:166
EFI_ACPI_2_0_GENERIC_ADDRESS_STRUCTURE XPm1aCntBlk
Definition Acpi20.h:173
EFI_ACPI_2_0_GENERIC_ADDRESS_STRUCTURE XPm1bEvtBlk
Definition Acpi20.h:172
EFI_ACPI_2_0_GENERIC_ADDRESS_STRUCTURE XPm1aEvtBlk
Definition Acpi20.h:171
EFI_ACPI_2_0_GENERIC_ADDRESS_STRUCTURE XGpe0Blk
Definition Acpi20.h:177
EFI_ACPI_2_0_GENERIC_ADDRESS_STRUCTURE XPm1bCntBlk
Definition Acpi20.h:174
EFI_ACPI_2_0_GENERIC_ADDRESS_STRUCTURE XPmTmrBlk
Definition Acpi20.h:176
EFI_ACPI_2_0_GENERIC_ADDRESS_STRUCTURE XGpe1Blk
Definition Acpi20.h:178
ACPI 2.0 Generic Address Space definition.
Definition Acpi20.h:50
Interrupt Source Override Structure.
Definition Acpi20.h:320
IO APIC Structure.
Definition Acpi20.h:308
IO SAPIC Structure.
Definition Acpi20.h:363
Local APIC Address Override Structure.
Definition Acpi20.h:353
Local APIC NMI Structure.
Definition Acpi20.h:342
Multiple APIC Description Table header definition.
Definition Acpi20.h:253
Non-Maskable Interrupt Source Structure.
Definition Acpi20.h:332
Platform Interrupt Sources Structure.
Definition Acpi20.h:388
Processor Local APIC Structure Definition.
Definition Acpi20.h:292
Root System Description Pointer Structure.
Definition Acpi20.h:75
Smart Battery Description Table (SBST)
Definition Acpi20.h:403
EFI_ACPI_DESCRIPTION_HEADER Header
Definition Acpi20.h:404
The common ACPI description table header.
Definition Acpi10.h:30