Path: blob/main/sys/contrib/dev/acpica/include/actbl1.h
105319 views
/******************************************************************************1*2* Name: actbl1.h - Additional ACPI table definitions3*4*****************************************************************************/56/******************************************************************************7*8* 1. Copyright Notice9*10* Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp.11* All rights reserved.12*13* 2. License14*15* 2.1. This is your license from Intel Corp. under its intellectual property16* rights. You may have additional license terms from the party that provided17* you this software, covering your right to use that party's intellectual18* property rights.19*20* 2.2. Intel grants, free of charge, to any person ("Licensee") obtaining a21* copy of the source code appearing in this file ("Covered Code") an22* irrevocable, perpetual, worldwide license under Intel's copyrights in the23* base code distributed originally by Intel ("Original Intel Code") to copy,24* make derivatives, distribute, use and display any portion of the Covered25* Code in any form, with the right to sublicense such rights; and26*27* 2.3. Intel grants Licensee a non-exclusive and non-transferable patent28* license (with the right to sublicense), under only those claims of Intel29* patents that are infringed by the Original Intel Code, to make, use, sell,30* offer to sell, and import the Covered Code and derivative works thereof31* solely to the minimum extent necessary to exercise the above copyright32* license, and in no event shall the patent license extend to any additions33* to or modifications of the Original Intel Code. No other license or right34* is granted directly or by implication, estoppel or otherwise;35*36* The above copyright and patent license is granted only if the following37* conditions are met:38*39* 3. Conditions40*41* 3.1. Redistribution of Source with Rights to Further Distribute Source.42* Redistribution of source code of any substantial portion of the Covered43* Code or modification with rights to further distribute source must include44* the above Copyright Notice, the above License, this list of Conditions,45* and the following Disclaimer and Export Compliance provision. In addition,46* Licensee must cause all Covered Code to which Licensee contributes to47* contain a file documenting the changes Licensee made to create that Covered48* Code and the date of any change. Licensee must include in that file the49* documentation of any changes made by any predecessor Licensee. Licensee50* must include a prominent statement that the modification is derived,51* directly or indirectly, from Original Intel Code.52*53* 3.2. Redistribution of Source with no Rights to Further Distribute Source.54* Redistribution of source code of any substantial portion of the Covered55* Code or modification without rights to further distribute source must56* include the following Disclaimer and Export Compliance provision in the57* documentation and/or other materials provided with distribution. In58* addition, Licensee may not authorize further sublicense of source of any59* portion of the Covered Code, and must include terms to the effect that the60* license from Licensee to its licensee is limited to the intellectual61* property embodied in the software Licensee provides to its licensee, and62* not to intellectual property embodied in modifications its licensee may63* make.64*65* 3.3. Redistribution of Executable. Redistribution in executable form of any66* substantial portion of the Covered Code or modification must reproduce the67* above Copyright Notice, and the following Disclaimer and Export Compliance68* provision in the documentation and/or other materials provided with the69* distribution.70*71* 3.4. Intel retains all right, title, and interest in and to the Original72* Intel Code.73*74* 3.5. Neither the name Intel nor any other trademark owned or controlled by75* Intel shall be used in advertising or otherwise to promote the sale, use or76* other dealings in products derived from or relating to the Covered Code77* without prior written authorization from Intel.78*79* 4. Disclaimer and Export Compliance80*81* 4.1. INTEL MAKES NO WARRANTY OF ANY KIND REGARDING ANY SOFTWARE PROVIDED82* HERE. ANY SOFTWARE ORIGINATING FROM INTEL OR DERIVED FROM INTEL SOFTWARE83* IS PROVIDED "AS IS," AND INTEL WILL NOT PROVIDE ANY SUPPORT, ASSISTANCE,84* INSTALLATION, TRAINING OR OTHER SERVICES. INTEL WILL NOT PROVIDE ANY85* UPDATES, ENHANCEMENTS OR EXTENSIONS. INTEL SPECIFICALLY DISCLAIMS ANY86* IMPLIED WARRANTIES OF MERCHANTABILITY, NONINFRINGEMENT AND FITNESS FOR A87* PARTICULAR PURPOSE.88*89* 4.2. IN NO EVENT SHALL INTEL HAVE ANY LIABILITY TO LICENSEE, ITS LICENSEES90* OR ANY OTHER THIRD PARTY, FOR ANY LOST PROFITS, LOST DATA, LOSS OF USE OR91* COSTS OF PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES, OR FOR ANY INDIRECT,92* SPECIAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THIS AGREEMENT, UNDER ANY93* CAUSE OF ACTION OR THEORY OF LIABILITY, AND IRRESPECTIVE OF WHETHER INTEL94* HAS ADVANCE NOTICE OF THE POSSIBILITY OF SUCH DAMAGES. THESE LIMITATIONS95* SHALL APPLY NOTWITHSTANDING THE FAILURE OF THE ESSENTIAL PURPOSE OF ANY96* LIMITED REMEDY.97*98* 4.3. Licensee shall not export, either directly or indirectly, any of this99* software or system incorporating such software without first obtaining any100* required license or other approval from the U. S. Department of Commerce or101* any other agency or department of the United States Government. In the102* event Licensee exports any such software from the United States or103* re-exports any such software from a foreign destination, Licensee shall104* ensure that the distribution and export/re-export of the software is in105* compliance with all laws, regulations, orders, or other restrictions of the106* U.S. Export Administration Regulations. Licensee agrees that neither it nor107* any of its subsidiaries will export/re-export any technical data, process,108* software, or service, directly or indirectly, to any country for which the109* United States government or any agency thereof requires an export license,110* other governmental approval, or letter of assurance, without first obtaining111* such license, approval or letter.112*113*****************************************************************************114*115* Alternatively, you may choose to be licensed under the terms of the116* following license:117*118* Redistribution and use in source and binary forms, with or without119* modification, are permitted provided that the following conditions120* are met:121* 1. Redistributions of source code must retain the above copyright122* notice, this list of conditions, and the following disclaimer,123* without modification.124* 2. Redistributions in binary form must reproduce at minimum a disclaimer125* substantially similar to the "NO WARRANTY" disclaimer below126* ("Disclaimer") and any redistribution must be conditioned upon127* including a substantially similar Disclaimer requirement for further128* binary redistribution.129* 3. Neither the names of the above-listed copyright holders nor the names130* of any contributors may be used to endorse or promote products derived131* from this software without specific prior written permission.132*133* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS134* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT135* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR136* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT137* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,138* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT139* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,140* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY141* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT142* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE143* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.144*145* Alternatively, you may choose to be licensed under the terms of the146* GNU General Public License ("GPL") version 2 as published by the Free147* Software Foundation.148*149*****************************************************************************/150151#ifndef __ACTBL1_H__152#define __ACTBL1_H__153154155/*******************************************************************************156*157* Additional ACPI Tables158*159* These tables are not consumed directly by the ACPICA subsystem, but are160* included here to support device drivers and the AML disassembler.161*162******************************************************************************/163164165/*166* Values for description table header signatures for tables defined in this167* file. Useful because they make it more difficult to inadvertently type in168* the wrong signature.169*/170#define ACPI_SIG_AEST "AEST" /* Arm Error Source Table */171#define ACPI_SIG_ASF "ASF!" /* Alert Standard Format table */172#define ACPI_SIG_ASPT "ASPT" /* AMD Secure Processor Table */173#define ACPI_SIG_BERT "BERT" /* Boot Error Record Table */174#define ACPI_SIG_BGRT "BGRT" /* Boot Graphics Resource Table */175#define ACPI_SIG_BOOT "BOOT" /* Simple Boot Flag Table */176#define ACPI_SIG_CEDT "CEDT" /* CXL Early Discovery Table */177#define ACPI_SIG_CPEP "CPEP" /* Corrected Platform Error Polling table */178#define ACPI_SIG_CSRT "CSRT" /* Core System Resource Table */179#define ACPI_SIG_DBG2 "DBG2" /* Debug Port table type 2 */180#define ACPI_SIG_DBGP "DBGP" /* Debug Port table */181#define ACPI_SIG_DMAR "DMAR" /* DMA Remapping table */182#define ACPI_SIG_DRTM "DRTM" /* Dynamic Root of Trust for Measurement table */183#define ACPI_SIG_ECDT "ECDT" /* Embedded Controller Boot Resources Table */184#define ACPI_SIG_EINJ "EINJ" /* Error Injection table */185#define ACPI_SIG_ERST "ERST" /* Error Record Serialization Table */186#define ACPI_SIG_FPDT "FPDT" /* Firmware Performance Data Table */187#define ACPI_SIG_GTDT "GTDT" /* Generic Timer Description Table */188#define ACPI_SIG_HEST "HEST" /* Hardware Error Source Table */189#define ACPI_SIG_HMAT "HMAT" /* Heterogeneous Memory Attributes Table */190#define ACPI_SIG_HPET "HPET" /* High Precision Event Timer table */191#define ACPI_SIG_IBFT "IBFT" /* iSCSI Boot Firmware Table */192#define ACPI_SIG_MSCT "MSCT" /* Maximum System Characteristics Table*/193194#define ACPI_SIG_S3PT "S3PT" /* S3 Performance (sub)Table */195#define ACPI_SIG_PCCS "PCC" /* PCC Shared Memory Region */196197198/* Reserved table signatures */199200#define ACPI_SIG_MATR "MATR" /* Memory Address Translation Table */201#define ACPI_SIG_MSDM "MSDM" /* Microsoft Data Management Table */202203/*204* These tables have been seen in the field, but no definition has been found205*/206#ifdef ACPI_UNDEFINED_TABLES207#define ACPI_SIG_ATKG "ATKG"208#define ACPI_SIG_GSCI "GSCI" /* GMCH SCI table */209#define ACPI_SIG_IEIT "IEIT"210#endif211212/*213* All tables must be byte-packed to match the ACPI specification, since214* the tables are provided by the system BIOS.215*/216#pragma pack(1)217218/*219* Note: C bitfields are not used for this reason:220*221* "Bitfields are great and easy to read, but unfortunately the C language222* does not specify the layout of bitfields in memory, which means they are223* essentially useless for dealing with packed data in on-disk formats or224* binary wire protocols." (Or ACPI tables and buffers.) "If you ask me,225* this decision was a design error in C. Ritchie could have picked an order226* and stuck with it." Norman Ramsey.227* See http://stackoverflow.com/a/1053662/41661228*/229230231/*******************************************************************************232*233* Common subtable headers234*235******************************************************************************/236237/* Generic subtable header (used in MADT, SRAT, etc.) */238239typedef struct acpi_subtable_header240{241UINT8 Type;242UINT8 Length;243244} ACPI_SUBTABLE_HEADER;245246247/* Subtable header for WHEA tables (EINJ, ERST, WDAT) */248249typedef struct acpi_whea_header250{251UINT8 Action;252UINT8 Instruction;253UINT8 Flags;254UINT8 Reserved;255ACPI_GENERIC_ADDRESS RegisterRegion;256UINT64 Value; /* Value used with Read/Write register */257UINT64 Mask; /* Bitmask required for this register instruction */258259} ACPI_WHEA_HEADER;260261262/* Larger subtable header (when Length can exceed 255) */263264typedef struct acpi_subtbl_hdr_16265{266UINT16 Type;267UINT16 Length;268269} ACPI_SUBTBL_HDR_16;270271272/*******************************************************************************273*274* ASF - Alert Standard Format table (Signature "ASF!")275* Revision 0x10276*277* Conforms to the Alert Standard Format Specification V2.0, 23 April 2003278*279******************************************************************************/280281typedef struct acpi_table_asf282{283ACPI_TABLE_HEADER Header; /* Common ACPI table header */284285} ACPI_TABLE_ASF;286287288/* ASF subtable header */289290typedef struct acpi_asf_header291{292UINT8 Type;293UINT8 Reserved;294UINT16 Length;295296} ACPI_ASF_HEADER;297298299/* Values for Type field above */300301enum AcpiAsfType302{303ACPI_ASF_TYPE_INFO = 0,304ACPI_ASF_TYPE_ALERT = 1,305ACPI_ASF_TYPE_CONTROL = 2,306ACPI_ASF_TYPE_BOOT = 3,307ACPI_ASF_TYPE_ADDRESS = 4,308ACPI_ASF_TYPE_RESERVED = 5309};310311/*312* ASF subtables313*/314315/* 0: ASF Information */316317typedef struct acpi_asf_info318{319ACPI_ASF_HEADER Header;320UINT8 MinResetValue;321UINT8 MinPollInterval;322UINT16 SystemId;323UINT32 MfgId;324UINT8 Flags;325UINT8 Reserved2[3];326327} ACPI_ASF_INFO;328329/* Masks for Flags field above */330331#define ACPI_ASF_SMBUS_PROTOCOLS (1)332333334/* 1: ASF Alerts */335336typedef struct acpi_asf_alert337{338ACPI_ASF_HEADER Header;339UINT8 AssertMask;340UINT8 DeassertMask;341UINT8 Alerts;342UINT8 DataLength;343344} ACPI_ASF_ALERT;345346typedef struct acpi_asf_alert_data347{348UINT8 Address;349UINT8 Command;350UINT8 Mask;351UINT8 Value;352UINT8 SensorType;353UINT8 Type;354UINT8 Offset;355UINT8 SourceType;356UINT8 Severity;357UINT8 SensorNumber;358UINT8 Entity;359UINT8 Instance;360361} ACPI_ASF_ALERT_DATA;362363364/* 2: ASF Remote Control */365366typedef struct acpi_asf_remote367{368ACPI_ASF_HEADER Header;369UINT8 Controls;370UINT8 DataLength;371UINT16 Reserved2;372373} ACPI_ASF_REMOTE;374375typedef struct acpi_asf_control_data376{377UINT8 Function;378UINT8 Address;379UINT8 Command;380UINT8 Value;381382} ACPI_ASF_CONTROL_DATA;383384385/* 3: ASF RMCP Boot Options */386387typedef struct acpi_asf_rmcp388{389ACPI_ASF_HEADER Header;390UINT8 Capabilities[7];391UINT8 CompletionCode;392UINT32 EnterpriseId;393UINT8 Command;394UINT16 Parameter;395UINT16 BootOptions;396UINT16 OemParameters;397398} ACPI_ASF_RMCP;399400401/* 4: ASF Address */402403typedef struct acpi_asf_address404{405ACPI_ASF_HEADER Header;406UINT8 EpromAddress;407UINT8 Devices;408409} ACPI_ASF_ADDRESS;410411/*******************************************************************************412*413* ASPT - AMD Secure Processor Table (Signature "ASPT")414* Revision 0x1415*416* Conforms to AMD Socket SP5/SP6 Platform ASPT Rev1 Specification,417* 12 September 2022418*419******************************************************************************/420421typedef struct acpi_table_aspt422{423ACPI_TABLE_HEADER Header; /* Common ACPI table header */424UINT32 NumEntries;425426} ACPI_TABLE_ASPT;427428429/* ASPT subtable header */430431typedef struct acpi_aspt_header432{433UINT16 Type;434UINT16 Length;435436} ACPI_ASPT_HEADER;437438439/* Values for Type field above */440441enum AcpiAsptType442{443ACPI_ASPT_TYPE_GLOBAL_REGS = 0,444ACPI_ASPT_TYPE_SEV_MBOX_REGS = 1,445ACPI_ASPT_TYPE_ACPI_MBOX_REGS = 2,446ACPI_ASPT_TYPE_UNKNOWN = 3,447};448449/*450* ASPT subtables451*/452453/* 0: ASPT Global Registers */454455typedef struct acpi_aspt_global_regs456{457ACPI_ASPT_HEADER Header;458UINT32 Reserved;459UINT64 FeatureRegAddr;460UINT64 IrqEnRegAddr;461UINT64 IrqStRegAddr;462463} ACPI_ASPT_GLOBAL_REGS;464465466/* 1: ASPT SEV Mailbox Registers */467468typedef struct acpi_aspt_sev_mbox_regs469{470ACPI_ASPT_HEADER Header;471UINT8 MboxIrqId;472UINT8 Reserved[3];473UINT64 CmdRespRegAddr;474UINT64 CmdBufLoRegAddr;475UINT64 CmdBufHiRegAddr;476477} ACPI_ASPT_SEV_MBOX_REGS;478479480/* 2: ASPT ACPI Mailbox Registers */481482typedef struct acpi_aspt_acpi_mbox_regs483{484ACPI_ASPT_HEADER Header;485UINT32 Reserved1;486UINT64 CmdRespRegAddr;487UINT64 Reserved2[2];488489} ACPI_ASPT_ACPI_MBOX_REGS;490491492/*******************************************************************************493*494* BERT - Boot Error Record Table (ACPI 4.0)495* Version 1496*497******************************************************************************/498499typedef struct acpi_table_bert500{501ACPI_TABLE_HEADER Header; /* Common ACPI table header */502UINT32 RegionLength; /* Length of the boot error region */503UINT64 Address; /* Physical address of the error region */504505} ACPI_TABLE_BERT;506507508/* Boot Error Region (not a subtable, pointed to by Address field above) */509510typedef struct acpi_bert_region511{512UINT32 BlockStatus; /* Type of error information */513UINT32 RawDataOffset; /* Offset to raw error data */514UINT32 RawDataLength; /* Length of raw error data */515UINT32 DataLength; /* Length of generic error data */516UINT32 ErrorSeverity; /* Severity code */517518} ACPI_BERT_REGION;519520/* Values for BlockStatus flags above */521522#define ACPI_BERT_UNCORRECTABLE (1)523#define ACPI_BERT_CORRECTABLE (1<<1)524#define ACPI_BERT_MULTIPLE_UNCORRECTABLE (1<<2)525#define ACPI_BERT_MULTIPLE_CORRECTABLE (1<<3)526#define ACPI_BERT_ERROR_ENTRY_COUNT (0xFF<<4) /* 8 bits, error count */527528/* Values for ErrorSeverity above */529530enum AcpiBertErrorSeverity531{532ACPI_BERT_ERROR_CORRECTABLE = 0,533ACPI_BERT_ERROR_FATAL = 1,534ACPI_BERT_ERROR_CORRECTED = 2,535ACPI_BERT_ERROR_NONE = 3,536ACPI_BERT_ERROR_RESERVED = 4 /* 4 and greater are reserved */537};538539/*540* Note: The generic error data that follows the ErrorSeverity field above541* uses the ACPI_HEST_GENERIC_DATA defined under the HEST table below542*/543544545/*******************************************************************************546*547* BGRT - Boot Graphics Resource Table (ACPI 5.0)548* Version 1549*550******************************************************************************/551552typedef struct acpi_table_bgrt553{554ACPI_TABLE_HEADER Header; /* Common ACPI table header */555UINT16 Version;556UINT8 Status;557UINT8 ImageType;558UINT64 ImageAddress;559UINT32 ImageOffsetX;560UINT32 ImageOffsetY;561562} ACPI_TABLE_BGRT;563564/* Flags for Status field above */565566#define ACPI_BGRT_DISPLAYED (1)567#define ACPI_BGRT_ORIENTATION_OFFSET (3 << 1)568569570/*******************************************************************************571*572* BOOT - Simple Boot Flag Table573* Version 1574*575* Conforms to the "Simple Boot Flag Specification", Version 2.1576*577******************************************************************************/578579typedef struct acpi_table_boot580{581ACPI_TABLE_HEADER Header; /* Common ACPI table header */582UINT8 CmosIndex; /* Index in CMOS RAM for the boot register */583UINT8 Reserved[3];584585} ACPI_TABLE_BOOT;586587588/*******************************************************************************589*590* CDAT - Coherent Device Attribute Table591* Version 1592*593* Conforms to the "Coherent Device Attribute Table (CDAT) Specification594" (Revision 1.01, October 2020.)595*596******************************************************************************/597598typedef struct acpi_table_cdat599{600UINT32 Length; /* Length of table in bytes, including this header */601UINT8 Revision; /* ACPI Specification minor version number */602UINT8 Checksum; /* To make sum of entire table == 0 */603UINT8 Reserved[6];604UINT32 Sequence; /* Used to detect runtime CDAT table changes */605606} ACPI_TABLE_CDAT;607608609/* CDAT common subtable header */610611typedef struct acpi_cdat_header612{613UINT8 Type;614UINT8 Reserved;615UINT16 Length;616617} ACPI_CDAT_HEADER;618619/* Values for Type field above */620621enum AcpiCdatType622{623ACPI_CDAT_TYPE_DSMAS = 0,624ACPI_CDAT_TYPE_DSLBIS = 1,625ACPI_CDAT_TYPE_DSMSCIS = 2,626ACPI_CDAT_TYPE_DSIS = 3,627ACPI_CDAT_TYPE_DSEMTS = 4,628ACPI_CDAT_TYPE_SSLBIS = 5,629ACPI_CDAT_TYPE_RESERVED = 6 /* 6 through 0xFF are reserved */630};631632633/* Subtable 0: Device Scoped Memory Affinity Structure (DSMAS) */634635typedef struct acpi_cdat_dsmas636{637UINT8 DsmadHandle;638UINT8 Flags;639UINT16 Reserved;640UINT64 DpaBaseAddress;641UINT64 DpaLength;642643} ACPI_CDAT_DSMAS;644645/* Flags for subtable above */646647#define ACPI_CDAT_DSMAS_NON_VOLATILE (1 << 2)648#define ACPI_CDAT_DSMAS_SHAREABLE (1 << 3)649#define ACPI_CDAT_DSMAS_READ_ONLY (1 << 6)650651652/* Subtable 1: Device scoped Latency and Bandwidth Information Structure (DSLBIS) */653654typedef struct acpi_cdat_dslbis655{656UINT8 Handle;657UINT8 Flags; /* If Handle matches a DSMAS handle, the definition of this field matches658* Flags field in HMAT System Locality Latency */659UINT8 DataType;660UINT8 Reserved;661UINT64 EntryBaseUnit;662UINT16 Entry[3];663UINT16 Reserved2;664665} ACPI_CDAT_DSLBIS;666667668/* Subtable 2: Device Scoped Memory Side Cache Information Structure (DSMSCIS) */669670typedef struct acpi_cdat_dsmscis671{672UINT8 DsmasHandle;673UINT8 Reserved[3];674UINT64 SideCacheSize;675UINT32 CacheAttributes;676677} ACPI_CDAT_DSMSCIS;678679680/* Subtable 3: Device Scoped Initiator Structure (DSIS) */681682typedef struct acpi_cdat_dsis683{684UINT8 Flags;685UINT8 Handle;686UINT16 Reserved;687688} ACPI_CDAT_DSIS;689690/* Flags for above subtable */691692#define ACPI_CDAT_DSIS_MEM_ATTACHED (1 << 0)693694695/* Subtable 4: Device Scoped EFI Memory Type Structure (DSEMTS) */696697typedef struct acpi_cdat_dsemts698{699UINT8 DsmasHandle;700UINT8 MemoryType;701UINT16 Reserved;702UINT64 DpaOffset;703UINT64 RangeLength;704705} ACPI_CDAT_DSEMTS;706707708/* Subtable 5: Switch Scoped Latency and Bandwidth Information Structure (SSLBIS) */709710typedef struct acpi_cdat_sslbis711{712UINT8 DataType;713UINT8 Reserved[3];714UINT64 EntryBaseUnit;715716} ACPI_CDAT_SSLBIS;717718719/* Sub-subtable for above, SslbeEntries field */720721typedef struct acpi_cdat_sslbe722{723UINT16 PortxId;724UINT16 PortyId;725UINT16 LatencyOrBandwidth;726UINT16 Reserved;727728} ACPI_CDAT_SSLBE;729730#define ACPI_CDAT_SSLBIS_US_PORT 0x0100731#define ACPI_CDAT_SSLBIS_ANY_PORT 0xffff732733/*******************************************************************************734*735* CEDT - CXL Early Discovery Table736* Version 1737*738* Conforms to the "CXL Early Discovery Table" (CXL 2.0, October 2020)739*740******************************************************************************/741742typedef struct acpi_table_cedt743{744ACPI_TABLE_HEADER Header; /* Common ACPI table header */745746} ACPI_TABLE_CEDT;747748/* CEDT subtable header (Performance Record Structure) */749750typedef struct acpi_cedt_header751{752UINT8 Type;753UINT8 Reserved;754UINT16 Length;755756} ACPI_CEDT_HEADER;757758/* Values for Type field above */759760enum AcpiCedtType761{762ACPI_CEDT_TYPE_CHBS = 0,763ACPI_CEDT_TYPE_CFMWS = 1,764ACPI_CEDT_TYPE_CXIMS = 2,765ACPI_CEDT_TYPE_RDPAS = 3,766ACPI_CEDT_TYPE_RESERVED = 4,767};768769/* Values for version field above */770771#define ACPI_CEDT_CHBS_VERSION_CXL11 (0)772#define ACPI_CEDT_CHBS_VERSION_CXL20 (1)773774/* Values for length field above */775776#define ACPI_CEDT_CHBS_LENGTH_CXL11 (0x2000)777#define ACPI_CEDT_CHBS_LENGTH_CXL20 (0x10000)778779/*780* CEDT subtables781*/782783/* 0: CXL Host Bridge Structure */784785typedef struct acpi_cedt_chbs786{787ACPI_CEDT_HEADER Header;788UINT32 Uid;789UINT32 CxlVersion;790UINT32 Reserved;791UINT64 Base;792UINT64 Length;793794} ACPI_CEDT_CHBS;795796797/* 1: CXL Fixed Memory Window Structure */798799typedef struct acpi_cedt_cfmws800{801ACPI_CEDT_HEADER Header;802UINT32 Reserved1;803UINT64 BaseHpa;804UINT64 WindowSize;805UINT8 InterleaveWays;806UINT8 InterleaveArithmetic;807UINT16 Reserved2;808UINT32 Granularity;809UINT16 Restrictions;810UINT16 QtgId;811UINT32 InterleaveTargets[];812813} ACPI_CEDT_CFMWS;814815typedef struct acpi_cedt_cfmws_target_element816{817UINT32 InterleaveTarget;818819} ACPI_CEDT_CFMWS_TARGET_ELEMENT;820821/* Values for Interleave Arithmetic field above */822823#define ACPI_CEDT_CFMWS_ARITHMETIC_MODULO (0)824#define ACPI_CEDT_CFMWS_ARITHMETIC_XOR (1)825826/* Values for Restrictions field above */827828#define ACPI_CEDT_CFMWS_RESTRICT_DEVMEM (1)829#define ACPI_CEDT_CFMWS_RESTRICT_HOSTONLYMEM (1<<1)830#define ACPI_CEDT_CFMWS_RESTRICT_VOLATILE (1<<2)831#define ACPI_CEDT_CFMWS_RESTRICT_PMEM (1<<3)832#define ACPI_CEDT_CFMWS_RESTRICT_FIXED (1<<4)833#define ACPI_CEDT_CFMWS_RESTRICT_BI (1<<5)834835/* 2: CXL XOR Interleave Math Structure */836837typedef struct acpi_cedt_cxims {838ACPI_CEDT_HEADER Header;839UINT16 Reserved1;840UINT8 Hbig;841UINT8 NrXormaps;842UINT64 XormapList[];843} ACPI_CEDT_CXIMS;844845typedef struct acpi_cedt_cxims_target_element846{847UINT64 Xormap;848849} ACPI_CEDT_CXIMS_TARGET_ELEMENT;850851852/* 3: CXL RCEC Downstream Port Association Structure */853854struct acpi_cedt_rdpas {855ACPI_CEDT_HEADER Header;856UINT16 Segment;857UINT16 Bdf;858UINT8 Protocol;859UINT64 Address;860};861862/* Masks for bdf field above */863#define ACPI_CEDT_RDPAS_BUS_MASK 0xff00864#define ACPI_CEDT_RDPAS_DEVICE_MASK 0x00f8865#define ACPI_CEDT_RDPAS_FUNCTION_MASK 0x0007866867#define ACPI_CEDT_RDPAS_PROTOCOL_IO (0)868#define ACPI_CEDT_RDPAS_PROTOCOL_CACHEMEM (1)869870/*******************************************************************************871*872* CPEP - Corrected Platform Error Polling table (ACPI 4.0)873* Version 1874*875******************************************************************************/876877typedef struct acpi_table_cpep878{879ACPI_TABLE_HEADER Header; /* Common ACPI table header */880UINT64 Reserved;881882} ACPI_TABLE_CPEP;883884885/* Subtable */886887typedef struct acpi_cpep_polling888{889ACPI_SUBTABLE_HEADER Header;890UINT8 Id; /* Processor ID */891UINT8 Eid; /* Processor EID */892UINT32 Interval; /* Polling interval (msec) */893894} ACPI_CPEP_POLLING;895896897/*******************************************************************************898*899* CSRT - Core System Resource Table900* Version 0901*902* Conforms to the "Core System Resource Table (CSRT)", November 14, 2011903*904******************************************************************************/905906typedef struct acpi_table_csrt907{908ACPI_TABLE_HEADER Header; /* Common ACPI table header */909910} ACPI_TABLE_CSRT;911912913/* Resource Group subtable */914915typedef struct acpi_csrt_group916{917UINT32 Length;918UINT32 VendorId;919UINT32 SubvendorId;920UINT16 DeviceId;921UINT16 SubdeviceId;922UINT16 Revision;923UINT16 Reserved;924UINT32 SharedInfoLength;925926/* Shared data immediately follows (Length = SharedInfoLength) */927928} ACPI_CSRT_GROUP;929930/* Shared Info subtable */931932typedef struct acpi_csrt_shared_info933{934UINT16 MajorVersion;935UINT16 MinorVersion;936UINT32 MmioBaseLow;937UINT32 MmioBaseHigh;938UINT32 GsiInterrupt;939UINT8 InterruptPolarity;940UINT8 InterruptMode;941UINT8 NumChannels;942UINT8 DmaAddressWidth;943UINT16 BaseRequestLine;944UINT16 NumHandshakeSignals;945UINT32 MaxBlockSize;946947/* Resource descriptors immediately follow (Length = Group Length - SharedInfoLength) */948949} ACPI_CSRT_SHARED_INFO;950951/* Resource Descriptor subtable */952953typedef struct acpi_csrt_descriptor954{955UINT32 Length;956UINT16 Type;957UINT16 Subtype;958UINT32 Uid;959960/* Resource-specific information immediately follows */961962} ACPI_CSRT_DESCRIPTOR;963964965/* Resource Types */966967#define ACPI_CSRT_TYPE_INTERRUPT 0x0001968#define ACPI_CSRT_TYPE_TIMER 0x0002969#define ACPI_CSRT_TYPE_DMA 0x0003970971/* Resource Subtypes */972973#define ACPI_CSRT_XRUPT_LINE 0x0000974#define ACPI_CSRT_XRUPT_CONTROLLER 0x0001975#define ACPI_CSRT_TIMER 0x0000976#define ACPI_CSRT_DMA_CHANNEL 0x0000977#define ACPI_CSRT_DMA_CONTROLLER 0x0001978979980/*******************************************************************************981*982* DBG2 - Debug Port Table 2983* Version 0 (Both main table and subtables)984*985* Conforms to "Microsoft Debug Port Table 2 (DBG2)", September 21, 2020986*987******************************************************************************/988989typedef struct acpi_table_dbg2990{991ACPI_TABLE_HEADER Header; /* Common ACPI table header */992UINT32 InfoOffset;993UINT32 InfoCount;994995} ACPI_TABLE_DBG2;996997998typedef struct acpi_dbg2_header999{1000UINT32 InfoOffset;1001UINT32 InfoCount;10021003} ACPI_DBG2_HEADER;100410051006/* Debug Device Information Subtable */10071008typedef struct acpi_dbg2_device1009{1010UINT8 Revision;1011UINT16 Length;1012UINT8 RegisterCount; /* Number of BaseAddress registers */1013UINT16 NamepathLength;1014UINT16 NamepathOffset;1015UINT16 OemDataLength;1016UINT16 OemDataOffset;1017UINT16 PortType;1018UINT16 PortSubtype;1019UINT16 Reserved;1020UINT16 BaseAddressOffset;1021UINT16 AddressSizeOffset;1022/*1023* Data that follows:1024* BaseAddress (required) - Each in 12-byte Generic Address Structure format.1025* AddressSize (required) - Array of UINT32 sizes corresponding to each BaseAddress register.1026* Namepath (required) - Null terminated string. Single dot if not supported.1027* OemData (optional) - Length is OemDataLength.1028*/1029} ACPI_DBG2_DEVICE;10301031/* Types for PortType field above */10321033#define ACPI_DBG2_SERIAL_PORT 0x80001034#define ACPI_DBG2_1394_PORT 0x80011035#define ACPI_DBG2_USB_PORT 0x80021036#define ACPI_DBG2_NET_PORT 0x800310371038/* Subtypes for PortSubtype field above */10391040#define ACPI_DBG2_16550_COMPATIBLE 0x00001041#define ACPI_DBG2_16550_SUBSET 0x00011042#define ACPI_DBG2_MAX311XE_SPI 0x00021043#define ACPI_DBG2_ARM_PL011 0x00031044#define ACPI_DBG2_MSM8X60 0x00041045#define ACPI_DBG2_16550_NVIDIA 0x00051046#define ACPI_DBG2_TI_OMAP 0x00061047#define ACPI_DBG2_APM88XXXX 0x00081048#define ACPI_DBG2_MSM8974 0x00091049#define ACPI_DBG2_SAM5250 0x000A1050#define ACPI_DBG2_INTEL_USIF 0x000B1051#define ACPI_DBG2_IMX6 0x000C1052#define ACPI_DBG2_ARM_SBSA_32BIT 0x000D1053#define ACPI_DBG2_ARM_SBSA_GENERIC 0x000E1054#define ACPI_DBG2_ARM_DCC 0x000F1055#define ACPI_DBG2_BCM2835 0x00101056#define ACPI_DBG2_SDM845_1_8432MHZ 0x00111057#define ACPI_DBG2_16550_WITH_GAS 0x00121058#define ACPI_DBG2_SDM845_7_372MHZ 0x00131059#define ACPI_DBG2_INTEL_LPSS 0x00141060#define ACPI_DBG2_RISCV_SBI_CON 0x001510611062#define ACPI_DBG2_1394_STANDARD 0x000010631064#define ACPI_DBG2_USB_XHCI 0x00001065#define ACPI_DBG2_USB_EHCI 0x0001106610671068/*******************************************************************************1069*1070* DBGP - Debug Port table1071* Version 11072*1073* Conforms to the "Debug Port Specification", Version 1.00, 2/9/20001074*1075******************************************************************************/10761077typedef struct acpi_table_dbgp1078{1079ACPI_TABLE_HEADER Header; /* Common ACPI table header */1080UINT8 Type; /* 0=full 16550, 1=subset of 16550 */1081UINT8 Reserved[3];1082ACPI_GENERIC_ADDRESS DebugPort;10831084} ACPI_TABLE_DBGP;108510861087/*******************************************************************************1088*1089* DMAR - DMA Remapping table1090* Version 11091*1092* Conforms to "Intel Virtualization Technology for Directed I/O",1093* Version 2.3, October 20141094*1095******************************************************************************/10961097typedef struct acpi_table_dmar1098{1099ACPI_TABLE_HEADER Header; /* Common ACPI table header */1100UINT8 Width; /* Host Address Width */1101UINT8 Flags;1102UINT8 Reserved[10];11031104} ACPI_TABLE_DMAR;11051106/* Masks for Flags field above */11071108#define ACPI_DMAR_INTR_REMAP (1)1109#define ACPI_DMAR_X2APIC_OPT_OUT (1<<1)1110#define ACPI_DMAR_X2APIC_MODE (1<<2)111111121113/* DMAR subtable header */11141115typedef struct acpi_dmar_header1116{1117UINT16 Type;1118UINT16 Length;11191120} ACPI_DMAR_HEADER;11211122/* Values for subtable type in ACPI_DMAR_HEADER */11231124enum AcpiDmarType1125{1126ACPI_DMAR_TYPE_HARDWARE_UNIT = 0,1127ACPI_DMAR_TYPE_RESERVED_MEMORY = 1,1128ACPI_DMAR_TYPE_ROOT_ATS = 2,1129ACPI_DMAR_TYPE_HARDWARE_AFFINITY = 3,1130ACPI_DMAR_TYPE_NAMESPACE = 4,1131ACPI_DMAR_TYPE_SATC = 5,1132ACPI_DMAR_TYPE_SIDP = 6,1133ACPI_DMAR_TYPE_RESERVED = 7 /* 7 and greater are reserved */1134};113511361137/* DMAR Device Scope structure */11381139typedef struct acpi_dmar_device_scope1140{1141UINT8 EntryType;1142UINT8 Length;1143UINT8 Flags;1144UINT8 Reserved;1145UINT8 EnumerationId;1146UINT8 Bus;11471148} ACPI_DMAR_DEVICE_SCOPE;11491150/* Values for EntryType in ACPI_DMAR_DEVICE_SCOPE - device types */11511152enum AcpiDmarScopeType1153{1154ACPI_DMAR_SCOPE_TYPE_NOT_USED = 0,1155ACPI_DMAR_SCOPE_TYPE_ENDPOINT = 1,1156ACPI_DMAR_SCOPE_TYPE_BRIDGE = 2,1157ACPI_DMAR_SCOPE_TYPE_IOAPIC = 3,1158ACPI_DMAR_SCOPE_TYPE_HPET = 4,1159ACPI_DMAR_SCOPE_TYPE_NAMESPACE = 5,1160ACPI_DMAR_SCOPE_TYPE_RESERVED = 6 /* 6 and greater are reserved */1161};11621163typedef struct acpi_dmar_pci_path1164{1165UINT8 Device;1166UINT8 Function;11671168} ACPI_DMAR_PCI_PATH;116911701171/*1172* DMAR Subtables, correspond to Type in ACPI_DMAR_HEADER1173*/11741175/* 0: Hardware Unit Definition */11761177typedef struct acpi_dmar_hardware_unit1178{1179ACPI_DMAR_HEADER Header;1180UINT8 Flags;1181UINT8 Size;1182UINT16 Segment;1183UINT64 Address; /* Register Base Address */11841185} ACPI_DMAR_HARDWARE_UNIT;11861187/* Masks for Flags field above */11881189#define ACPI_DMAR_INCLUDE_ALL (1)119011911192/* 1: Reserved Memory Definition */11931194typedef struct acpi_dmar_reserved_memory1195{1196ACPI_DMAR_HEADER Header;1197UINT16 Reserved;1198UINT16 Segment;1199UINT64 BaseAddress; /* 4K aligned base address */1200UINT64 EndAddress; /* 4K aligned limit address */12011202} ACPI_DMAR_RESERVED_MEMORY;12031204/* Masks for Flags field above */12051206#define ACPI_DMAR_ALLOW_ALL (1)120712081209/* 2: Root Port ATS Capability Reporting Structure */12101211typedef struct acpi_dmar_atsr1212{1213ACPI_DMAR_HEADER Header;1214UINT8 Flags;1215UINT8 Reserved;1216UINT16 Segment;12171218} ACPI_DMAR_ATSR;12191220/* Masks for Flags field above */12211222#define ACPI_DMAR_ALL_PORTS (1)122312241225/* 3: Remapping Hardware Static Affinity Structure */12261227typedef struct acpi_dmar_rhsa1228{1229ACPI_DMAR_HEADER Header;1230UINT32 Reserved;1231UINT64 BaseAddress;1232UINT32 ProximityDomain;12331234} ACPI_DMAR_RHSA;123512361237/* 4: ACPI Namespace Device Declaration Structure */12381239typedef struct acpi_dmar_andd1240{1241ACPI_DMAR_HEADER Header;1242UINT8 Reserved[3];1243UINT8 DeviceNumber;1244union {1245char __pad;1246ACPI_FLEX_ARRAY(char, DeviceName);1247};12481249} ACPI_DMAR_ANDD;125012511252/* 5: SoC Integrated Address Translation Cache (SATC) */12531254typedef struct acpi_dmar_satc1255{1256ACPI_DMAR_HEADER Header;1257UINT8 Flags;1258UINT8 Reserved;1259UINT16 Segment;12601261} ACPI_DMAR_SATC;126212631264/* 6: SoC Integrated Device Property Reporting Structure */12651266typedef struct acpi_dmar_sidp1267{1268ACPI_DMAR_HEADER Header;1269UINT16 Reserved;1270UINT16 Segment;12711272} ACPI_DMAR_SIDP;127312741275/*******************************************************************************1276*1277* DRTM - Dynamic Root of Trust for Measurement table1278* Conforms to "TCG D-RTM Architecture" June 17 2013, Version 1.0.01279* Table version 11280*1281******************************************************************************/12821283typedef struct acpi_table_drtm1284{1285ACPI_TABLE_HEADER Header; /* Common ACPI table header */1286UINT64 EntryBaseAddress;1287UINT64 EntryLength;1288UINT32 EntryAddress32;1289UINT64 EntryAddress64;1290UINT64 ExitAddress;1291UINT64 LogAreaAddress;1292UINT32 LogAreaLength;1293UINT64 ArchDependentAddress;1294UINT32 Flags;12951296} ACPI_TABLE_DRTM;12971298/* Flag Definitions for above */12991300#define ACPI_DRTM_ACCESS_ALLOWED (1)1301#define ACPI_DRTM_ENABLE_GAP_CODE (1<<1)1302#define ACPI_DRTM_INCOMPLETE_MEASUREMENTS (1<<2)1303#define ACPI_DRTM_AUTHORITY_ORDER (1<<3)130413051306/* 1) Validated Tables List (64-bit addresses) */13071308typedef struct acpi_drtm_vtable_list1309{1310UINT32 ValidatedTableCount;1311UINT64 ValidatedTables[];13121313} ACPI_DRTM_VTABLE_LIST;13141315/* 2) Resources List (of Resource Descriptors) */13161317/* Resource Descriptor */13181319typedef struct acpi_drtm_resource1320{1321UINT8 Size[7];1322UINT8 Type;1323UINT64 Address;13241325} ACPI_DRTM_RESOURCE;13261327typedef struct acpi_drtm_resource_list1328{1329UINT32 ResourceCount;1330ACPI_DRTM_RESOURCE Resources[];13311332} ACPI_DRTM_RESOURCE_LIST;13331334/* 3) Platform-specific Identifiers List */13351336typedef struct acpi_drtm_dps_id1337{1338UINT32 DpsIdLength;1339UINT8 DpsId[16];13401341} ACPI_DRTM_DPS_ID;134213431344/*******************************************************************************1345*1346* ECDT - Embedded Controller Boot Resources Table1347* Version 11348*1349******************************************************************************/13501351typedef struct acpi_table_ecdt1352{1353ACPI_TABLE_HEADER Header; /* Common ACPI table header */1354ACPI_GENERIC_ADDRESS Control; /* Address of EC command/status register */1355ACPI_GENERIC_ADDRESS Data; /* Address of EC data register */1356UINT32 Uid; /* Unique ID - must be same as the EC _UID method */1357UINT8 Gpe; /* The GPE for the EC */1358UINT8 Id[]; /* Full namepath of the EC in the ACPI namespace */13591360} ACPI_TABLE_ECDT;136113621363/*******************************************************************************1364*1365* EINJ - Error Injection Table (ACPI 4.0)1366* Version 11367*1368******************************************************************************/13691370typedef struct acpi_table_einj1371{1372ACPI_TABLE_HEADER Header; /* Common ACPI table header */1373UINT32 HeaderLength;1374UINT8 Flags;1375UINT8 Reserved[3];1376UINT32 Entries;13771378} ACPI_TABLE_EINJ;137913801381/* EINJ Injection Instruction Entries (actions) */13821383typedef struct acpi_einj_entry1384{1385ACPI_WHEA_HEADER WheaHeader; /* Common header for WHEA tables */13861387} ACPI_EINJ_ENTRY;13881389/* Masks for Flags field above */13901391#define ACPI_EINJ_PRESERVE (1)13921393/* Values for Action field above */13941395enum AcpiEinjActions1396{1397ACPI_EINJ_BEGIN_OPERATION = 0x0,1398ACPI_EINJ_GET_TRIGGER_TABLE = 0x1,1399ACPI_EINJ_SET_ERROR_TYPE = 0x2,1400ACPI_EINJ_GET_ERROR_TYPE = 0x3,1401ACPI_EINJ_END_OPERATION = 0x4,1402ACPI_EINJ_EXECUTE_OPERATION = 0x5,1403ACPI_EINJ_CHECK_BUSY_STATUS = 0x6,1404ACPI_EINJ_GET_COMMAND_STATUS = 0x7,1405ACPI_EINJ_SET_ERROR_TYPE_WITH_ADDRESS = 0x8,1406ACPI_EINJ_GET_EXECUTE_TIMINGS = 0x9,1407ACPI_EINJV2_GET_ERROR_TYPE = 0x11,1408ACPI_EINJ_ACTION_RESERVED = 0x12, /* 0x12 and greater are reserved */1409ACPI_EINJ_TRIGGER_ERROR = 0xFF /* Except for this value */1410};14111412/* Values for Instruction field above */14131414enum AcpiEinjInstructions1415{1416ACPI_EINJ_READ_REGISTER = 0,1417ACPI_EINJ_READ_REGISTER_VALUE = 1,1418ACPI_EINJ_WRITE_REGISTER = 2,1419ACPI_EINJ_WRITE_REGISTER_VALUE = 3,1420ACPI_EINJ_NOOP = 4,1421ACPI_EINJ_FLUSH_CACHELINE = 5,1422ACPI_EINJ_INSTRUCTION_RESERVED = 6 /* 6 and greater are reserved */1423};14241425typedef struct acpi_einj_error_type_with_addr1426{1427UINT32 ErrorType;1428UINT32 VendorStructOffset;1429UINT32 Flags;1430UINT32 ApicId;1431UINT64 Address;1432UINT64 Range;1433UINT32 PcieId;14341435} ACPI_EINJ_ERROR_TYPE_WITH_ADDR;14361437typedef struct acpi_einj_vendor1438{1439UINT32 Length;1440UINT32 PcieId;1441UINT16 VendorId;1442UINT16 DeviceId;1443UINT8 RevisionId;1444UINT8 Reserved[3];14451446} ACPI_EINJ_VENDOR;144714481449/* EINJ Trigger Error Action Table */14501451typedef struct acpi_einj_trigger1452{1453UINT32 HeaderSize;1454UINT32 Revision;1455UINT32 TableSize;1456UINT32 EntryCount;14571458} ACPI_EINJ_TRIGGER;14591460/* Command status return values */14611462enum AcpiEinjCommandStatus1463{1464ACPI_EINJ_SUCCESS = 0,1465ACPI_EINJ_FAILURE = 1,1466ACPI_EINJ_INVALID_ACCESS = 2,1467ACPI_EINJ_STATUS_RESERVED = 3 /* 3 and greater are reserved */1468};146914701471/* Error types returned from ACPI_EINJ_GET_ERROR_TYPE (bitfield) */14721473#define ACPI_EINJ_PROCESSOR_CORRECTABLE (1)1474#define ACPI_EINJ_PROCESSOR_UNCORRECTABLE (1<<1)1475#define ACPI_EINJ_PROCESSOR_FATAL (1<<2)1476#define ACPI_EINJ_MEMORY_CORRECTABLE (1<<3)1477#define ACPI_EINJ_MEMORY_UNCORRECTABLE (1<<4)1478#define ACPI_EINJ_MEMORY_FATAL (1<<5)1479#define ACPI_EINJ_PCIX_CORRECTABLE (1<<6)1480#define ACPI_EINJ_PCIX_UNCORRECTABLE (1<<7)1481#define ACPI_EINJ_PCIX_FATAL (1<<8)1482#define ACPI_EINJ_PLATFORM_CORRECTABLE (1<<9)1483#define ACPI_EINJ_PLATFORM_UNCORRECTABLE (1<<10)1484#define ACPI_EINJ_PLATFORM_FATAL (1<<11)1485#define ACPI_EINJ_CXL_CACHE_CORRECTABLE (1<<12)1486#define ACPI_EINJ_CXL_CACHE_UNCORRECTABLE (1<<13)1487#define ACPI_EINJ_CXL_CACHE_FATAL (1<<14)1488#define ACPI_EINJ_CXL_MEM_CORRECTABLE (1<<15)1489#define ACPI_EINJ_CXL_MEM_UNCORRECTABLE (1<<16)1490#define ACPI_EINJ_CXL_MEM_FATAL (1<<17)1491#define ACPI_EINJ_VENDOR_DEFINED (1<<31)149214931494/*******************************************************************************1495*1496* ERST - Error Record Serialization Table (ACPI 4.0)1497* Version 11498*1499******************************************************************************/15001501typedef struct acpi_table_erst1502{1503ACPI_TABLE_HEADER Header; /* Common ACPI table header */1504UINT32 HeaderLength;1505UINT32 Reserved;1506UINT32 Entries;15071508} ACPI_TABLE_ERST;150915101511/* ERST Serialization Entries (actions) */15121513typedef struct acpi_erst_entry1514{1515ACPI_WHEA_HEADER WheaHeader; /* Common header for WHEA tables */15161517} ACPI_ERST_ENTRY;15181519/* Masks for Flags field above */15201521#define ACPI_ERST_PRESERVE (1)15221523/* Values for Action field above */15241525enum AcpiErstActions1526{1527ACPI_ERST_BEGIN_WRITE = 0,1528ACPI_ERST_BEGIN_READ = 1,1529ACPI_ERST_BEGIN_CLEAR = 2,1530ACPI_ERST_END = 3,1531ACPI_ERST_SET_RECORD_OFFSET = 4,1532ACPI_ERST_EXECUTE_OPERATION = 5,1533ACPI_ERST_CHECK_BUSY_STATUS = 6,1534ACPI_ERST_GET_COMMAND_STATUS = 7,1535ACPI_ERST_GET_RECORD_ID = 8,1536ACPI_ERST_SET_RECORD_ID = 9,1537ACPI_ERST_GET_RECORD_COUNT = 10,1538ACPI_ERST_BEGIN_DUMMY_WRIITE = 11,1539ACPI_ERST_NOT_USED = 12,1540ACPI_ERST_GET_ERROR_RANGE = 13,1541ACPI_ERST_GET_ERROR_LENGTH = 14,1542ACPI_ERST_GET_ERROR_ATTRIBUTES = 15,1543ACPI_ERST_EXECUTE_TIMINGS = 16,1544ACPI_ERST_ACTION_RESERVED = 17 /* 17 and greater are reserved */1545};15461547/* Values for Instruction field above */15481549enum AcpiErstInstructions1550{1551ACPI_ERST_READ_REGISTER = 0,1552ACPI_ERST_READ_REGISTER_VALUE = 1,1553ACPI_ERST_WRITE_REGISTER = 2,1554ACPI_ERST_WRITE_REGISTER_VALUE = 3,1555ACPI_ERST_NOOP = 4,1556ACPI_ERST_LOAD_VAR1 = 5,1557ACPI_ERST_LOAD_VAR2 = 6,1558ACPI_ERST_STORE_VAR1 = 7,1559ACPI_ERST_ADD = 8,1560ACPI_ERST_SUBTRACT = 9,1561ACPI_ERST_ADD_VALUE = 10,1562ACPI_ERST_SUBTRACT_VALUE = 11,1563ACPI_ERST_STALL = 12,1564ACPI_ERST_STALL_WHILE_TRUE = 13,1565ACPI_ERST_SKIP_NEXT_IF_TRUE = 14,1566ACPI_ERST_GOTO = 15,1567ACPI_ERST_SET_SRC_ADDRESS_BASE = 16,1568ACPI_ERST_SET_DST_ADDRESS_BASE = 17,1569ACPI_ERST_MOVE_DATA = 18,1570ACPI_ERST_INSTRUCTION_RESERVED = 19 /* 19 and greater are reserved */1571};15721573/* Command status return values */15741575enum AcpiErstCommandStatus1576{1577ACPI_ERST_SUCCESS = 0,1578ACPI_ERST_NO_SPACE = 1,1579ACPI_ERST_NOT_AVAILABLE = 2,1580ACPI_ERST_FAILURE = 3,1581ACPI_ERST_RECORD_EMPTY = 4,1582ACPI_ERST_NOT_FOUND = 5,1583ACPI_ERST_STATUS_RESERVED = 6 /* 6 and greater are reserved */1584};158515861587/* Error Record Serialization Information */15881589typedef struct acpi_erst_info1590{1591UINT16 Signature; /* Should be "ER" */1592UINT8 Data[48];15931594} ACPI_ERST_INFO;159515961597/*******************************************************************************1598*1599* FPDT - Firmware Performance Data Table (ACPI 5.0)1600* Version 11601*1602******************************************************************************/16031604typedef struct acpi_table_fpdt1605{1606ACPI_TABLE_HEADER Header; /* Common ACPI table header */16071608} ACPI_TABLE_FPDT;160916101611/* FPDT subtable header (Performance Record Structure) */16121613typedef struct acpi_fpdt_header1614{1615UINT16 Type;1616UINT8 Length;1617UINT8 Revision;16181619} ACPI_FPDT_HEADER;16201621/* Values for Type field above */16221623enum AcpiFpdtType1624{1625ACPI_FPDT_TYPE_BOOT = 0,1626ACPI_FPDT_TYPE_S3PERF = 11627};162816291630/*1631* FPDT subtables1632*/16331634/* 0: Firmware Basic Boot Performance Record */16351636typedef struct acpi_fpdt_boot_pointer1637{1638ACPI_FPDT_HEADER Header;1639UINT8 Reserved[4];1640UINT64 Address;16411642} ACPI_FPDT_BOOT_POINTER;164316441645/* 1: S3 Performance Table Pointer Record */16461647typedef struct acpi_fpdt_s3pt_pointer1648{1649ACPI_FPDT_HEADER Header;1650UINT8 Reserved[4];1651UINT64 Address;16521653} ACPI_FPDT_S3PT_POINTER;165416551656/*1657* S3PT - S3 Performance Table. This table is pointed to by the1658* S3 Pointer Record above.1659*/1660typedef struct acpi_table_s3pt1661{1662UINT8 Signature[4]; /* "S3PT" */1663UINT32 Length;16641665} ACPI_TABLE_S3PT;166616671668/*1669* S3PT Subtables (Not part of the actual FPDT)1670*/16711672/* Values for Type field in S3PT header */16731674enum AcpiS3ptType1675{1676ACPI_S3PT_TYPE_RESUME = 0,1677ACPI_S3PT_TYPE_SUSPEND = 1,1678ACPI_FPDT_BOOT_PERFORMANCE = 21679};16801681typedef struct acpi_s3pt_resume1682{1683ACPI_FPDT_HEADER Header;1684UINT32 ResumeCount;1685UINT64 FullResume;1686UINT64 AverageResume;16871688} ACPI_S3PT_RESUME;16891690typedef struct acpi_s3pt_suspend1691{1692ACPI_FPDT_HEADER Header;1693UINT64 SuspendStart;1694UINT64 SuspendEnd;16951696} ACPI_S3PT_SUSPEND;169716981699/*1700* FPDT Boot Performance Record (Not part of the actual FPDT)1701*/1702typedef struct acpi_fpdt_boot1703{1704ACPI_FPDT_HEADER Header;1705UINT8 Reserved[4];1706UINT64 ResetEnd;1707UINT64 LoadStart;1708UINT64 StartupStart;1709UINT64 ExitServicesEntry;1710UINT64 ExitServicesExit;17111712} ACPI_FPDT_BOOT;171317141715/*******************************************************************************1716*1717* GTDT - Generic Timer Description Table (ACPI 5.1)1718* Version 21719*1720******************************************************************************/17211722typedef struct acpi_table_gtdt1723{1724ACPI_TABLE_HEADER Header; /* Common ACPI table header */1725UINT64 CounterBlockAddresss;1726UINT32 Reserved;1727UINT32 SecureEl1Interrupt;1728UINT32 SecureEl1Flags;1729UINT32 NonSecureEl1Interrupt;1730UINT32 NonSecureEl1Flags;1731UINT32 VirtualTimerInterrupt;1732UINT32 VirtualTimerFlags;1733UINT32 NonSecureEl2Interrupt;1734UINT32 NonSecureEl2Flags;1735UINT64 CounterReadBlockAddress;1736UINT32 PlatformTimerCount;1737UINT32 PlatformTimerOffset;17381739} ACPI_TABLE_GTDT;17401741/* Flag Definitions: Timer Block Physical Timers and Virtual timers */17421743#define ACPI_GTDT_INTERRUPT_MODE (1)1744#define ACPI_GTDT_INTERRUPT_POLARITY (1<<1)1745#define ACPI_GTDT_ALWAYS_ON (1<<2)17461747typedef struct acpi_gtdt_el21748{1749UINT32 VirtualEL2TimerGsiv;1750UINT32 VirtualEL2TimerFlags;1751} ACPI_GTDT_EL2;175217531754/* Common GTDT subtable header */17551756typedef struct acpi_gtdt_header1757{1758UINT8 Type;1759UINT16 Length;17601761} ACPI_GTDT_HEADER;17621763/* Values for GTDT subtable type above */17641765enum AcpiGtdtType1766{1767ACPI_GTDT_TYPE_TIMER_BLOCK = 0,1768ACPI_GTDT_TYPE_WATCHDOG = 1,1769ACPI_GTDT_TYPE_RESERVED = 2 /* 2 and greater are reserved */1770};177117721773/* GTDT Subtables, correspond to Type in acpi_gtdt_header */17741775/* 0: Generic Timer Block */17761777typedef struct acpi_gtdt_timer_block1778{1779ACPI_GTDT_HEADER Header;1780UINT8 Reserved;1781UINT64 BlockAddress;1782UINT32 TimerCount;1783UINT32 TimerOffset;17841785} ACPI_GTDT_TIMER_BLOCK;17861787/* Timer Sub-Structure, one per timer */17881789typedef struct acpi_gtdt_timer_entry1790{1791UINT8 FrameNumber;1792UINT8 Reserved[3];1793UINT64 BaseAddress;1794UINT64 El0BaseAddress;1795UINT32 TimerInterrupt;1796UINT32 TimerFlags;1797UINT32 VirtualTimerInterrupt;1798UINT32 VirtualTimerFlags;1799UINT32 CommonFlags;18001801} ACPI_GTDT_TIMER_ENTRY;18021803/* Flag Definitions: TimerFlags and VirtualTimerFlags above */18041805#define ACPI_GTDT_GT_IRQ_MODE (1)1806#define ACPI_GTDT_GT_IRQ_POLARITY (1<<1)18071808/* Flag Definitions: CommonFlags above */18091810#define ACPI_GTDT_GT_IS_SECURE_TIMER (1)1811#define ACPI_GTDT_GT_ALWAYS_ON (1<<1)181218131814/* 1: SBSA Generic Watchdog Structure */18151816typedef struct acpi_gtdt_watchdog1817{1818ACPI_GTDT_HEADER Header;1819UINT8 Reserved;1820UINT64 RefreshFrameAddress;1821UINT64 ControlFrameAddress;1822UINT32 TimerInterrupt;1823UINT32 TimerFlags;18241825} ACPI_GTDT_WATCHDOG;18261827/* Flag Definitions: TimerFlags above */18281829#define ACPI_GTDT_WATCHDOG_IRQ_MODE (1)1830#define ACPI_GTDT_WATCHDOG_IRQ_POLARITY (1<<1)1831#define ACPI_GTDT_WATCHDOG_SECURE (1<<2)183218331834/*******************************************************************************1835*1836* HEST - Hardware Error Source Table (ACPI 4.0)1837* Version 11838*1839******************************************************************************/18401841typedef struct acpi_table_hest1842{1843ACPI_TABLE_HEADER Header; /* Common ACPI table header */1844UINT32 ErrorSourceCount;18451846} ACPI_TABLE_HEST;184718481849/* HEST subtable header */18501851typedef struct acpi_hest_header1852{1853UINT16 Type;1854UINT16 SourceId;18551856} ACPI_HEST_HEADER;185718581859/* Values for Type field above for subtables */18601861enum AcpiHestTypes1862{1863ACPI_HEST_TYPE_IA32_CHECK = 0,1864ACPI_HEST_TYPE_IA32_CORRECTED_CHECK = 1,1865ACPI_HEST_TYPE_IA32_NMI = 2,1866ACPI_HEST_TYPE_NOT_USED3 = 3,1867ACPI_HEST_TYPE_NOT_USED4 = 4,1868ACPI_HEST_TYPE_NOT_USED5 = 5,1869ACPI_HEST_TYPE_AER_ROOT_PORT = 6,1870ACPI_HEST_TYPE_AER_ENDPOINT = 7,1871ACPI_HEST_TYPE_AER_BRIDGE = 8,1872ACPI_HEST_TYPE_GENERIC_ERROR = 9,1873ACPI_HEST_TYPE_GENERIC_ERROR_V2 = 10,1874ACPI_HEST_TYPE_IA32_DEFERRED_CHECK = 11,1875ACPI_HEST_TYPE_RESERVED = 12 /* 12 and greater are reserved */1876};187718781879/*1880* HEST substructures contained in subtables1881*/18821883/*1884* IA32 Error Bank(s) - Follows the ACPI_HEST_IA_MACHINE_CHECK and1885* ACPI_HEST_IA_CORRECTED structures.1886*/1887typedef struct acpi_hest_ia_error_bank1888{1889UINT8 BankNumber;1890UINT8 ClearStatusOnInit;1891UINT8 StatusFormat;1892UINT8 Reserved;1893UINT32 ControlRegister;1894UINT64 ControlData;1895UINT32 StatusRegister;1896UINT32 AddressRegister;1897UINT32 MiscRegister;18981899} ACPI_HEST_IA_ERROR_BANK;190019011902/* Common HEST sub-structure for PCI/AER structures below (6,7,8) */19031904typedef struct acpi_hest_aer_common1905{1906UINT16 Reserved1;1907UINT8 Flags;1908UINT8 Enabled;1909UINT32 RecordsToPreallocate;1910UINT32 MaxSectionsPerRecord;1911UINT32 Bus; /* Bus and Segment numbers */1912UINT16 Device;1913UINT16 Function;1914UINT16 DeviceControl;1915UINT16 Reserved2;1916UINT32 UncorrectableMask;1917UINT32 UncorrectableSeverity;1918UINT32 CorrectableMask;1919UINT32 AdvancedCapabilities;19201921} ACPI_HEST_AER_COMMON;19221923/* Masks for HEST Flags fields */19241925#define ACPI_HEST_FIRMWARE_FIRST (1)1926#define ACPI_HEST_GLOBAL (1<<1)1927#define ACPI_HEST_GHES_ASSIST (1<<2)19281929/*1930* Macros to access the bus/segment numbers in Bus field above:1931* Bus number is encoded in bits 7:01932* Segment number is encoded in bits 23:81933*/1934#define ACPI_HEST_BUS(Bus) ((Bus) & 0xFF)1935#define ACPI_HEST_SEGMENT(Bus) (((Bus) >> 8) & 0xFFFF)193619371938/* Hardware Error Notification */19391940typedef struct acpi_hest_notify1941{1942UINT8 Type;1943UINT8 Length;1944UINT16 ConfigWriteEnable;1945UINT32 PollInterval;1946UINT32 Vector;1947UINT32 PollingThresholdValue;1948UINT32 PollingThresholdWindow;1949UINT32 ErrorThresholdValue;1950UINT32 ErrorThresholdWindow;19511952} ACPI_HEST_NOTIFY;19531954/* Values for Notify Type field above */19551956enum AcpiHestNotifyTypes1957{1958ACPI_HEST_NOTIFY_POLLED = 0,1959ACPI_HEST_NOTIFY_EXTERNAL = 1,1960ACPI_HEST_NOTIFY_LOCAL = 2,1961ACPI_HEST_NOTIFY_SCI = 3,1962ACPI_HEST_NOTIFY_NMI = 4,1963ACPI_HEST_NOTIFY_CMCI = 5, /* ACPI 5.0 */1964ACPI_HEST_NOTIFY_MCE = 6, /* ACPI 5.0 */1965ACPI_HEST_NOTIFY_GPIO = 7, /* ACPI 6.0 */1966ACPI_HEST_NOTIFY_SEA = 8, /* ACPI 6.1 */1967ACPI_HEST_NOTIFY_SEI = 9, /* ACPI 6.1 */1968ACPI_HEST_NOTIFY_GSIV = 10, /* ACPI 6.1 */1969ACPI_HEST_NOTIFY_SOFTWARE_DELEGATED = 11, /* ACPI 6.2 */1970ACPI_HEST_NOTIFY_RESERVED = 12 /* 12 and greater are reserved */1971};19721973/* Values for ConfigWriteEnable bitfield above */19741975#define ACPI_HEST_TYPE (1)1976#define ACPI_HEST_POLL_INTERVAL (1<<1)1977#define ACPI_HEST_POLL_THRESHOLD_VALUE (1<<2)1978#define ACPI_HEST_POLL_THRESHOLD_WINDOW (1<<3)1979#define ACPI_HEST_ERR_THRESHOLD_VALUE (1<<4)1980#define ACPI_HEST_ERR_THRESHOLD_WINDOW (1<<5)198119821983/*1984* HEST subtables1985*/19861987/* 0: IA32 Machine Check Exception */19881989typedef struct acpi_hest_ia_machine_check1990{1991ACPI_HEST_HEADER Header;1992UINT16 Reserved1;1993UINT8 Flags; /* See flags ACPI_HEST_GLOBAL, etc. above */1994UINT8 Enabled;1995UINT32 RecordsToPreallocate;1996UINT32 MaxSectionsPerRecord;1997UINT64 GlobalCapabilityData;1998UINT64 GlobalControlData;1999UINT8 NumHardwareBanks;2000UINT8 Reserved3[7];20012002} ACPI_HEST_IA_MACHINE_CHECK;200320042005/* 1: IA32 Corrected Machine Check */20062007typedef struct acpi_hest_ia_corrected2008{2009ACPI_HEST_HEADER Header;2010UINT16 Reserved1;2011UINT8 Flags; /* See flags ACPI_HEST_GLOBAL, etc. above */2012UINT8 Enabled;2013UINT32 RecordsToPreallocate;2014UINT32 MaxSectionsPerRecord;2015ACPI_HEST_NOTIFY Notify;2016UINT8 NumHardwareBanks;2017UINT8 Reserved2[3];20182019} ACPI_HEST_IA_CORRECTED;202020212022/* 2: IA32 Non-Maskable Interrupt */20232024typedef struct acpi_hest_ia_nmi2025{2026ACPI_HEST_HEADER Header;2027UINT32 Reserved;2028UINT32 RecordsToPreallocate;2029UINT32 MaxSectionsPerRecord;2030UINT32 MaxRawDataLength;20312032} ACPI_HEST_IA_NMI;203320342035/* 3,4,5: Not used */20362037/* 6: PCI Express Root Port AER */20382039typedef struct acpi_hest_aer_root2040{2041ACPI_HEST_HEADER Header;2042ACPI_HEST_AER_COMMON Aer;2043UINT32 RootErrorCommand;20442045} ACPI_HEST_AER_ROOT;204620472048/* 7: PCI Express AER (AER Endpoint) */20492050typedef struct acpi_hest_aer2051{2052ACPI_HEST_HEADER Header;2053ACPI_HEST_AER_COMMON Aer;20542055} ACPI_HEST_AER;205620572058/* 8: PCI Express/PCI-X Bridge AER */20592060typedef struct acpi_hest_aer_bridge2061{2062ACPI_HEST_HEADER Header;2063ACPI_HEST_AER_COMMON Aer;2064UINT32 UncorrectableMask2;2065UINT32 UncorrectableSeverity2;2066UINT32 AdvancedCapabilities2;20672068} ACPI_HEST_AER_BRIDGE;206920702071/* 9: Generic Hardware Error Source */20722073typedef struct acpi_hest_generic2074{2075ACPI_HEST_HEADER Header;2076UINT16 RelatedSourceId;2077UINT8 Reserved;2078UINT8 Enabled;2079UINT32 RecordsToPreallocate;2080UINT32 MaxSectionsPerRecord;2081UINT32 MaxRawDataLength;2082ACPI_GENERIC_ADDRESS ErrorStatusAddress;2083ACPI_HEST_NOTIFY Notify;2084UINT32 ErrorBlockLength;20852086} ACPI_HEST_GENERIC;208720882089/* 10: Generic Hardware Error Source, version 2 */20902091typedef struct acpi_hest_generic_v22092{2093ACPI_HEST_HEADER Header;2094UINT16 RelatedSourceId;2095UINT8 Reserved;2096UINT8 Enabled;2097UINT32 RecordsToPreallocate;2098UINT32 MaxSectionsPerRecord;2099UINT32 MaxRawDataLength;2100ACPI_GENERIC_ADDRESS ErrorStatusAddress;2101ACPI_HEST_NOTIFY Notify;2102UINT32 ErrorBlockLength;2103ACPI_GENERIC_ADDRESS ReadAckRegister;2104UINT64 ReadAckPreserve;2105UINT64 ReadAckWrite;21062107} ACPI_HEST_GENERIC_V2;210821092110/* Generic Error Status block */21112112typedef struct acpi_hest_generic_status2113{2114UINT32 BlockStatus;2115UINT32 RawDataOffset;2116UINT32 RawDataLength;2117UINT32 DataLength;2118UINT32 ErrorSeverity;21192120} ACPI_HEST_GENERIC_STATUS;21212122/* Values for BlockStatus flags above */21232124#define ACPI_HEST_UNCORRECTABLE (1)2125#define ACPI_HEST_CORRECTABLE (1<<1)2126#define ACPI_HEST_MULTIPLE_UNCORRECTABLE (1<<2)2127#define ACPI_HEST_MULTIPLE_CORRECTABLE (1<<3)2128#define ACPI_HEST_ERROR_ENTRY_COUNT (0xFF<<4) /* 8 bits, error count */212921302131/* Generic Error Data entry */21322133typedef struct acpi_hest_generic_data2134{2135UINT8 SectionType[16];2136UINT32 ErrorSeverity;2137UINT16 Revision;2138UINT8 ValidationBits;2139UINT8 Flags;2140UINT32 ErrorDataLength;2141UINT8 FruId[16];2142UINT8 FruText[20];21432144} ACPI_HEST_GENERIC_DATA;21452146/* Extension for revision 0x0300 */21472148typedef struct acpi_hest_generic_data_v3002149{2150UINT8 SectionType[16];2151UINT32 ErrorSeverity;2152UINT16 Revision;2153UINT8 ValidationBits;2154UINT8 Flags;2155UINT32 ErrorDataLength;2156UINT8 FruId[16];2157UINT8 FruText[20];2158UINT64 TimeStamp;21592160} ACPI_HEST_GENERIC_DATA_V300;21612162/* Values for ErrorSeverity above */21632164#define ACPI_HEST_GEN_ERROR_RECOVERABLE 02165#define ACPI_HEST_GEN_ERROR_FATAL 12166#define ACPI_HEST_GEN_ERROR_CORRECTED 22167#define ACPI_HEST_GEN_ERROR_NONE 321682169/* Flags for ValidationBits above */21702171#define ACPI_HEST_GEN_VALID_FRU_ID (1)2172#define ACPI_HEST_GEN_VALID_FRU_STRING (1<<1)2173#define ACPI_HEST_GEN_VALID_TIMESTAMP (1<<2)217421752176/* 11: IA32 Deferred Machine Check Exception (ACPI 6.2) */21772178typedef struct acpi_hest_ia_deferred_check2179{2180ACPI_HEST_HEADER Header;2181UINT16 Reserved1;2182UINT8 Flags; /* See flags ACPI_HEST_GLOBAL, etc. above */2183UINT8 Enabled;2184UINT32 RecordsToPreallocate;2185UINT32 MaxSectionsPerRecord;2186ACPI_HEST_NOTIFY Notify;2187UINT8 NumHardwareBanks;2188UINT8 Reserved2[3];21892190} ACPI_HEST_IA_DEFERRED_CHECK;219121922193/*******************************************************************************2194*2195* HMAT - Heterogeneous Memory Attributes Table (ACPI 6.3)2196*2197******************************************************************************/21982199typedef struct acpi_table_hmat2200{2201ACPI_TABLE_HEADER Header; /* Common ACPI table header */2202UINT32 Reserved;22032204} ACPI_TABLE_HMAT;220522062207/* Values for HMAT structure types */22082209enum AcpiHmatType2210{2211ACPI_HMAT_TYPE_ADDRESS_RANGE = 0, /* Memory subsystem address range */2212ACPI_HMAT_TYPE_LOCALITY = 1, /* System locality latency and bandwidth information */2213ACPI_HMAT_TYPE_CACHE = 2, /* Memory side cache information */2214ACPI_HMAT_TYPE_RESERVED = 3 /* 3 and greater are reserved */2215};22162217typedef struct acpi_hmat_structure2218{2219UINT16 Type;2220UINT16 Reserved;2221UINT32 Length;22222223} ACPI_HMAT_STRUCTURE;222422252226/*2227* HMAT Structures, correspond to Type in ACPI_HMAT_STRUCTURE2228*/22292230/* 0: Memory proximity domain attributes */22312232typedef struct acpi_hmat_proximity_domain2233{2234ACPI_HMAT_STRUCTURE Header;2235UINT16 Flags;2236UINT16 Reserved1;2237UINT32 InitiatorPD; /* Attached Initiator proximity domain */2238UINT32 MemoryPD; /* Memory proximity domain */2239UINT32 Reserved2;2240UINT64 Reserved3;2241UINT64 Reserved4;22422243} ACPI_HMAT_PROXIMITY_DOMAIN;22442245/* Masks for Flags field above */22462247#define ACPI_HMAT_INITIATOR_PD_VALID (1) /* 1: InitiatorPD field is valid */224822492250/* 1: System locality latency and bandwidth information */22512252typedef struct acpi_hmat_locality2253{2254ACPI_HMAT_STRUCTURE Header;2255UINT8 Flags;2256UINT8 DataType;2257UINT8 MinTransferSize;2258UINT8 Reserved1;2259UINT32 NumberOfInitiatorPDs;2260UINT32 NumberOfTargetPDs;2261UINT32 Reserved2;2262UINT64 EntryBaseUnit;22632264} ACPI_HMAT_LOCALITY;22652266/* Masks for Flags field above */22672268#define ACPI_HMAT_MEMORY_HIERARCHY (0x0F) /* Bits 0-3 */22692270/* Values for Memory Hierarchy flags */22712272#define ACPI_HMAT_MEMORY 02273#define ACPI_HMAT_1ST_LEVEL_CACHE 12274#define ACPI_HMAT_2ND_LEVEL_CACHE 22275#define ACPI_HMAT_3RD_LEVEL_CACHE 32276#define ACPI_HMAT_MINIMUM_XFER_SIZE 0x10 /* Bit 4: ACPI 6.4 */2277#define ACPI_HMAT_NON_SEQUENTIAL_XFERS 0x20 /* Bit 5: ACPI 6.4 */227822792280/* Values for DataType field above */22812282#define ACPI_HMAT_ACCESS_LATENCY 02283#define ACPI_HMAT_READ_LATENCY 12284#define ACPI_HMAT_WRITE_LATENCY 22285#define ACPI_HMAT_ACCESS_BANDWIDTH 32286#define ACPI_HMAT_READ_BANDWIDTH 42287#define ACPI_HMAT_WRITE_BANDWIDTH 5228822892290/* 2: Memory side cache information */22912292typedef struct acpi_hmat_cache2293{2294ACPI_HMAT_STRUCTURE Header;2295UINT32 MemoryPD;2296UINT32 Reserved1;2297UINT64 CacheSize;2298UINT32 CacheAttributes;2299UINT16 AddressMode;2300UINT16 NumberOfSMBIOSHandles;23012302} ACPI_HMAT_CACHE;23032304/* Masks for CacheAttributes field above */23052306#define ACPI_HMAT_TOTAL_CACHE_LEVEL (0x0000000F)2307#define ACPI_HMAT_CACHE_LEVEL (0x000000F0)2308#define ACPI_HMAT_CACHE_ASSOCIATIVITY (0x00000F00)2309#define ACPI_HMAT_WRITE_POLICY (0x0000F000)2310#define ACPI_HMAT_CACHE_LINE_SIZE (0xFFFF0000)23112312#define ACPI_HMAT_CACHE_MODE_UNKNOWN (0)2313#define ACPI_HMAT_CACHE_MODE_EXTENDED_LINEAR (1)23142315/* Values for cache associativity flag */23162317#define ACPI_HMAT_CA_NONE (0)2318#define ACPI_HMAT_CA_DIRECT_MAPPED (1)2319#define ACPI_HMAT_CA_COMPLEX_CACHE_INDEXING (2)23202321/* Values for write policy flag */23222323#define ACPI_HMAT_CP_NONE (0)2324#define ACPI_HMAT_CP_WB (1)2325#define ACPI_HMAT_CP_WT (2)232623272328/*******************************************************************************2329*2330* HPET - High Precision Event Timer table2331* Version 12332*2333* Conforms to "IA-PC HPET (High Precision Event Timers) Specification",2334* Version 1.0a, October 20042335*2336******************************************************************************/23372338typedef struct acpi_table_hpet2339{2340ACPI_TABLE_HEADER Header; /* Common ACPI table header */2341UINT32 Id; /* Hardware ID of event timer block */2342ACPI_GENERIC_ADDRESS Address; /* Address of event timer block */2343UINT8 Sequence; /* HPET sequence number */2344UINT16 MinimumTick; /* Main counter min tick, periodic mode */2345UINT8 Flags;23462347} ACPI_TABLE_HPET;23482349/* Masks for Flags field above */23502351#define ACPI_HPET_PAGE_PROTECT_MASK (3)23522353/* Values for Page Protect flags */23542355enum AcpiHpetPageProtect2356{2357ACPI_HPET_NO_PAGE_PROTECT = 0,2358ACPI_HPET_PAGE_PROTECT4 = 1,2359ACPI_HPET_PAGE_PROTECT64 = 22360};236123622363/*******************************************************************************2364*2365* IBFT - Boot Firmware Table2366* Version 12367*2368* Conforms to "iSCSI Boot Firmware Table (iBFT) as Defined in ACPI 3.0b2369* Specification", Version 1.01, March 1, 20072370*2371* Note: It appears that this table is not intended to appear in the RSDT/XSDT.2372* Therefore, it is not currently supported by the disassembler.2373*2374******************************************************************************/23752376typedef struct acpi_table_ibft2377{2378ACPI_TABLE_HEADER Header; /* Common ACPI table header */2379UINT8 Reserved[12];23802381} ACPI_TABLE_IBFT;238223832384/* IBFT common subtable header */23852386typedef struct acpi_ibft_header2387{2388UINT8 Type;2389UINT8 Version;2390UINT16 Length;2391UINT8 Index;2392UINT8 Flags;23932394} ACPI_IBFT_HEADER;23952396/* Values for Type field above */23972398enum AcpiIbftType2399{2400ACPI_IBFT_TYPE_NOT_USED = 0,2401ACPI_IBFT_TYPE_CONTROL = 1,2402ACPI_IBFT_TYPE_INITIATOR = 2,2403ACPI_IBFT_TYPE_NIC = 3,2404ACPI_IBFT_TYPE_TARGET = 4,2405ACPI_IBFT_TYPE_EXTENSIONS = 5,2406ACPI_IBFT_TYPE_RESERVED = 6 /* 6 and greater are reserved */2407};240824092410/* IBFT subtables */24112412typedef struct acpi_ibft_control2413{2414ACPI_IBFT_HEADER Header;2415UINT16 Extensions;2416UINT16 InitiatorOffset;2417UINT16 Nic0Offset;2418UINT16 Target0Offset;2419UINT16 Nic1Offset;2420UINT16 Target1Offset;24212422} ACPI_IBFT_CONTROL;24232424typedef struct acpi_ibft_initiator2425{2426ACPI_IBFT_HEADER Header;2427UINT8 SnsServer[16];2428UINT8 SlpServer[16];2429UINT8 PrimaryServer[16];2430UINT8 SecondaryServer[16];2431UINT16 NameLength;2432UINT16 NameOffset;24332434} ACPI_IBFT_INITIATOR;24352436typedef struct acpi_ibft_nic2437{2438ACPI_IBFT_HEADER Header;2439UINT8 IpAddress[16];2440UINT8 SubnetMaskPrefix;2441UINT8 Origin;2442UINT8 Gateway[16];2443UINT8 PrimaryDns[16];2444UINT8 SecondaryDns[16];2445UINT8 Dhcp[16];2446UINT16 Vlan;2447UINT8 MacAddress[6];2448UINT16 PciAddress;2449UINT16 NameLength;2450UINT16 NameOffset;24512452} ACPI_IBFT_NIC;24532454typedef struct acpi_ibft_target2455{2456ACPI_IBFT_HEADER Header;2457UINT8 TargetIpAddress[16];2458UINT16 TargetIpSocket;2459UINT8 TargetBootLun[8];2460UINT8 ChapType;2461UINT8 NicAssociation;2462UINT16 TargetNameLength;2463UINT16 TargetNameOffset;2464UINT16 ChapNameLength;2465UINT16 ChapNameOffset;2466UINT16 ChapSecretLength;2467UINT16 ChapSecretOffset;2468UINT16 ReverseChapNameLength;2469UINT16 ReverseChapNameOffset;2470UINT16 ReverseChapSecretLength;2471UINT16 ReverseChapSecretOffset;24722473} ACPI_IBFT_TARGET;247424752476/* Reset to default packing */24772478#pragma pack()24792480#endif /* __ACTBL1_H__ */248124822483