10Sstevel@tonic-gate 20Sstevel@tonic-gate /****************************************************************************** 30Sstevel@tonic-gate * 40Sstevel@tonic-gate * Module Name: amlresrc.h - AML resource descriptors 50Sstevel@tonic-gate * 60Sstevel@tonic-gate *****************************************************************************/ 70Sstevel@tonic-gate 80Sstevel@tonic-gate /****************************************************************************** 90Sstevel@tonic-gate * 100Sstevel@tonic-gate * 1. Copyright Notice 110Sstevel@tonic-gate * 12*9980SDana.Myers@Sun.COM * Some or all of this work - Copyright (c) 1999 - 2009, Intel Corp. 130Sstevel@tonic-gate * All rights reserved. 140Sstevel@tonic-gate * 150Sstevel@tonic-gate * 2. License 160Sstevel@tonic-gate * 170Sstevel@tonic-gate * 2.1. This is your license from Intel Corp. under its intellectual property 180Sstevel@tonic-gate * rights. You may have additional license terms from the party that provided 190Sstevel@tonic-gate * you this software, covering your right to use that party's intellectual 200Sstevel@tonic-gate * property rights. 210Sstevel@tonic-gate * 220Sstevel@tonic-gate * 2.2. Intel grants, free of charge, to any person ("Licensee") obtaining a 230Sstevel@tonic-gate * copy of the source code appearing in this file ("Covered Code") an 240Sstevel@tonic-gate * irrevocable, perpetual, worldwide license under Intel's copyrights in the 250Sstevel@tonic-gate * base code distributed originally by Intel ("Original Intel Code") to copy, 260Sstevel@tonic-gate * make derivatives, distribute, use and display any portion of the Covered 270Sstevel@tonic-gate * Code in any form, with the right to sublicense such rights; and 280Sstevel@tonic-gate * 290Sstevel@tonic-gate * 2.3. Intel grants Licensee a non-exclusive and non-transferable patent 300Sstevel@tonic-gate * license (with the right to sublicense), under only those claims of Intel 310Sstevel@tonic-gate * patents that are infringed by the Original Intel Code, to make, use, sell, 320Sstevel@tonic-gate * offer to sell, and import the Covered Code and derivative works thereof 330Sstevel@tonic-gate * solely to the minimum extent necessary to exercise the above copyright 340Sstevel@tonic-gate * license, and in no event shall the patent license extend to any additions 350Sstevel@tonic-gate * to or modifications of the Original Intel Code. No other license or right 360Sstevel@tonic-gate * is granted directly or by implication, estoppel or otherwise; 370Sstevel@tonic-gate * 380Sstevel@tonic-gate * The above copyright and patent license is granted only if the following 390Sstevel@tonic-gate * conditions are met: 400Sstevel@tonic-gate * 410Sstevel@tonic-gate * 3. Conditions 420Sstevel@tonic-gate * 430Sstevel@tonic-gate * 3.1. Redistribution of Source with Rights to Further Distribute Source. 440Sstevel@tonic-gate * Redistribution of source code of any substantial portion of the Covered 450Sstevel@tonic-gate * Code or modification with rights to further distribute source must include 460Sstevel@tonic-gate * the above Copyright Notice, the above License, this list of Conditions, 470Sstevel@tonic-gate * and the following Disclaimer and Export Compliance provision. In addition, 480Sstevel@tonic-gate * Licensee must cause all Covered Code to which Licensee contributes to 490Sstevel@tonic-gate * contain a file documenting the changes Licensee made to create that Covered 500Sstevel@tonic-gate * Code and the date of any change. Licensee must include in that file the 510Sstevel@tonic-gate * documentation of any changes made by any predecessor Licensee. Licensee 520Sstevel@tonic-gate * must include a prominent statement that the modification is derived, 530Sstevel@tonic-gate * directly or indirectly, from Original Intel Code. 540Sstevel@tonic-gate * 550Sstevel@tonic-gate * 3.2. Redistribution of Source with no Rights to Further Distribute Source. 560Sstevel@tonic-gate * Redistribution of source code of any substantial portion of the Covered 570Sstevel@tonic-gate * Code or modification without rights to further distribute source must 580Sstevel@tonic-gate * include the following Disclaimer and Export Compliance provision in the 590Sstevel@tonic-gate * documentation and/or other materials provided with distribution. In 600Sstevel@tonic-gate * addition, Licensee may not authorize further sublicense of source of any 610Sstevel@tonic-gate * portion of the Covered Code, and must include terms to the effect that the 620Sstevel@tonic-gate * license from Licensee to its licensee is limited to the intellectual 630Sstevel@tonic-gate * property embodied in the software Licensee provides to its licensee, and 640Sstevel@tonic-gate * not to intellectual property embodied in modifications its licensee may 650Sstevel@tonic-gate * make. 660Sstevel@tonic-gate * 670Sstevel@tonic-gate * 3.3. Redistribution of Executable. Redistribution in executable form of any 680Sstevel@tonic-gate * substantial portion of the Covered Code or modification must reproduce the 690Sstevel@tonic-gate * above Copyright Notice, and the following Disclaimer and Export Compliance 700Sstevel@tonic-gate * provision in the documentation and/or other materials provided with the 710Sstevel@tonic-gate * distribution. 720Sstevel@tonic-gate * 730Sstevel@tonic-gate * 3.4. Intel retains all right, title, and interest in and to the Original 740Sstevel@tonic-gate * Intel Code. 750Sstevel@tonic-gate * 760Sstevel@tonic-gate * 3.5. Neither the name Intel nor any other trademark owned or controlled by 770Sstevel@tonic-gate * Intel shall be used in advertising or otherwise to promote the sale, use or 780Sstevel@tonic-gate * other dealings in products derived from or relating to the Covered Code 790Sstevel@tonic-gate * without prior written authorization from Intel. 800Sstevel@tonic-gate * 810Sstevel@tonic-gate * 4. Disclaimer and Export Compliance 820Sstevel@tonic-gate * 830Sstevel@tonic-gate * 4.1. INTEL MAKES NO WARRANTY OF ANY KIND REGARDING ANY SOFTWARE PROVIDED 840Sstevel@tonic-gate * HERE. ANY SOFTWARE ORIGINATING FROM INTEL OR DERIVED FROM INTEL SOFTWARE 850Sstevel@tonic-gate * IS PROVIDED "AS IS," AND INTEL WILL NOT PROVIDE ANY SUPPORT, ASSISTANCE, 860Sstevel@tonic-gate * INSTALLATION, TRAINING OR OTHER SERVICES. INTEL WILL NOT PROVIDE ANY 870Sstevel@tonic-gate * UPDATES, ENHANCEMENTS OR EXTENSIONS. INTEL SPECIFICALLY DISCLAIMS ANY 880Sstevel@tonic-gate * IMPLIED WARRANTIES OF MERCHANTABILITY, NONINFRINGEMENT AND FITNESS FOR A 890Sstevel@tonic-gate * PARTICULAR PURPOSE. 900Sstevel@tonic-gate * 910Sstevel@tonic-gate * 4.2. IN NO EVENT SHALL INTEL HAVE ANY LIABILITY TO LICENSEE, ITS LICENSEES 920Sstevel@tonic-gate * OR ANY OTHER THIRD PARTY, FOR ANY LOST PROFITS, LOST DATA, LOSS OF USE OR 930Sstevel@tonic-gate * COSTS OF PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES, OR FOR ANY INDIRECT, 940Sstevel@tonic-gate * SPECIAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THIS AGREEMENT, UNDER ANY 950Sstevel@tonic-gate * CAUSE OF ACTION OR THEORY OF LIABILITY, AND IRRESPECTIVE OF WHETHER INTEL 960Sstevel@tonic-gate * HAS ADVANCE NOTICE OF THE POSSIBILITY OF SUCH DAMAGES. THESE LIMITATIONS 970Sstevel@tonic-gate * SHALL APPLY NOTWITHSTANDING THE FAILURE OF THE ESSENTIAL PURPOSE OF ANY 980Sstevel@tonic-gate * LIMITED REMEDY. 990Sstevel@tonic-gate * 1000Sstevel@tonic-gate * 4.3. Licensee shall not export, either directly or indirectly, any of this 1010Sstevel@tonic-gate * software or system incorporating such software without first obtaining any 1020Sstevel@tonic-gate * required license or other approval from the U. S. Department of Commerce or 1030Sstevel@tonic-gate * any other agency or department of the United States Government. In the 1040Sstevel@tonic-gate * event Licensee exports any such software from the United States or 1050Sstevel@tonic-gate * re-exports any such software from a foreign destination, Licensee shall 1060Sstevel@tonic-gate * ensure that the distribution and export/re-export of the software is in 1070Sstevel@tonic-gate * compliance with all laws, regulations, orders, or other restrictions of the 1080Sstevel@tonic-gate * U.S. Export Administration Regulations. Licensee agrees that neither it nor 1090Sstevel@tonic-gate * any of its subsidiaries will export/re-export any technical data, process, 1100Sstevel@tonic-gate * software, or service, directly or indirectly, to any country for which the 1110Sstevel@tonic-gate * United States government or any agency thereof requires an export license, 1120Sstevel@tonic-gate * other governmental approval, or letter of assurance, without first obtaining 1130Sstevel@tonic-gate * such license, approval or letter. 1140Sstevel@tonic-gate * 1150Sstevel@tonic-gate *****************************************************************************/ 1160Sstevel@tonic-gate 1172623Smyers /* acpisrc:StructDefs -- for acpisrc conversion */ 1180Sstevel@tonic-gate 1190Sstevel@tonic-gate #ifndef __AMLRESRC_H 1200Sstevel@tonic-gate #define __AMLRESRC_H 1210Sstevel@tonic-gate 1220Sstevel@tonic-gate 1232623Smyers /* 1242623Smyers * Resource descriptor tags, as defined in the ACPI specification. 1252623Smyers * Used to symbolically reference fields within a descriptor. 1262623Smyers */ 1272623Smyers #define ACPI_RESTAG_ADDRESS "_ADR" 1282623Smyers #define ACPI_RESTAG_ALIGNMENT "_ALN" 1292623Smyers #define ACPI_RESTAG_ADDRESSSPACE "_ASI" 1302623Smyers #define ACPI_RESTAG_ACCESSSIZE "_ASZ" 1312623Smyers #define ACPI_RESTAG_TYPESPECIFICATTRIBUTES "_ATT" 1322623Smyers #define ACPI_RESTAG_BASEADDRESS "_BAS" 1332623Smyers #define ACPI_RESTAG_BUSMASTER "_BM_" /* Master(1), Slave(0) */ 1342623Smyers #define ACPI_RESTAG_DECODE "_DEC" 1352623Smyers #define ACPI_RESTAG_DMA "_DMA" 1362623Smyers #define ACPI_RESTAG_DMATYPE "_TYP" /* Compatible(0), A(1), B(2), F(3) */ 1372623Smyers #define ACPI_RESTAG_GRANULARITY "_GRA" 1382623Smyers #define ACPI_RESTAG_INTERRUPT "_INT" 1392623Smyers #define ACPI_RESTAG_INTERRUPTLEVEL "_LL_" /* ActiveLo(1), ActiveHi(0) */ 1402623Smyers #define ACPI_RESTAG_INTERRUPTSHARE "_SHR" /* Shareable(1), NoShare(0) */ 1412623Smyers #define ACPI_RESTAG_INTERRUPTTYPE "_HE_" /* Edge(1), Level(0) */ 1422623Smyers #define ACPI_RESTAG_LENGTH "_LEN" 1432623Smyers #define ACPI_RESTAG_MEMATTRIBUTES "_MTP" /* Memory(0), Reserved(1), ACPI(2), NVS(3) */ 1442623Smyers #define ACPI_RESTAG_MEMTYPE "_MEM" /* NonCache(0), Cacheable(1) Cache+combine(2), Cache+prefetch(3) */ 1452623Smyers #define ACPI_RESTAG_MAXADDR "_MAX" 1462623Smyers #define ACPI_RESTAG_MINADDR "_MIN" 1472623Smyers #define ACPI_RESTAG_MAXTYPE "_MAF" 1482623Smyers #define ACPI_RESTAG_MINTYPE "_MIF" 1492623Smyers #define ACPI_RESTAG_REGISTERBITOFFSET "_RBO" 1502623Smyers #define ACPI_RESTAG_REGISTERBITWIDTH "_RBW" 1512623Smyers #define ACPI_RESTAG_RANGETYPE "_RNG" 1522623Smyers #define ACPI_RESTAG_READWRITETYPE "_RW_" /* ReadOnly(0), Writeable (1) */ 1532623Smyers #define ACPI_RESTAG_TRANSLATION "_TRA" 1542623Smyers #define ACPI_RESTAG_TRANSTYPE "_TRS" /* Sparse(1), Dense(0) */ 1552623Smyers #define ACPI_RESTAG_TYPE "_TTP" /* Translation(1), Static (0) */ 1562623Smyers #define ACPI_RESTAG_XFERTYPE "_SIZ" /* 8(0), 8And16(1), 16(2) */ 1570Sstevel@tonic-gate 1580Sstevel@tonic-gate 1590Sstevel@tonic-gate /* Default sizes for "small" resource descriptors */ 1600Sstevel@tonic-gate 1610Sstevel@tonic-gate #define ASL_RDESC_IRQ_SIZE 0x02 1620Sstevel@tonic-gate #define ASL_RDESC_DMA_SIZE 0x02 1630Sstevel@tonic-gate #define ASL_RDESC_ST_DEPEND_SIZE 0x00 1640Sstevel@tonic-gate #define ASL_RDESC_END_DEPEND_SIZE 0x00 1650Sstevel@tonic-gate #define ASL_RDESC_IO_SIZE 0x07 1660Sstevel@tonic-gate #define ASL_RDESC_FIXED_IO_SIZE 0x03 1670Sstevel@tonic-gate #define ASL_RDESC_END_TAG_SIZE 0x01 1680Sstevel@tonic-gate 1690Sstevel@tonic-gate 1700Sstevel@tonic-gate typedef struct asl_resource_node 1710Sstevel@tonic-gate { 1722623Smyers UINT32 BufferLength; 1732623Smyers void *Buffer; 1742623Smyers struct asl_resource_node *Next; 1750Sstevel@tonic-gate 1760Sstevel@tonic-gate } ASL_RESOURCE_NODE; 1770Sstevel@tonic-gate 1780Sstevel@tonic-gate 1791560Smyers /* Macros used to generate AML resource length fields */ 1801560Smyers 1811560Smyers #define ACPI_AML_SIZE_LARGE(r) (sizeof (r) - sizeof (AML_RESOURCE_LARGE_HEADER)) 1821560Smyers #define ACPI_AML_SIZE_SMALL(r) (sizeof (r) - sizeof (AML_RESOURCE_SMALL_HEADER)) 1831560Smyers 1840Sstevel@tonic-gate /* 1850Sstevel@tonic-gate * Resource descriptors defined in the ACPI specification. 1860Sstevel@tonic-gate * 1870Sstevel@tonic-gate * Packing/alignment must be BYTE because these descriptors 188941Smyers * are used to overlay the raw AML byte stream. 1890Sstevel@tonic-gate */ 1900Sstevel@tonic-gate #pragma pack(1) 1910Sstevel@tonic-gate 192941Smyers /* 193941Smyers * SMALL descriptors 194941Smyers */ 195941Smyers #define AML_RESOURCE_SMALL_HEADER_COMMON \ 1962623Smyers UINT8 DescriptorType; 197941Smyers 198941Smyers typedef struct aml_resource_small_header 1990Sstevel@tonic-gate { 200941Smyers AML_RESOURCE_SMALL_HEADER_COMMON 201941Smyers 202941Smyers } AML_RESOURCE_SMALL_HEADER; 203941Smyers 204941Smyers 205941Smyers typedef struct aml_resource_irq 206941Smyers { 207941Smyers AML_RESOURCE_SMALL_HEADER_COMMON 2082623Smyers UINT16 IrqMask; 2092623Smyers UINT8 Flags; 2100Sstevel@tonic-gate 211941Smyers } AML_RESOURCE_IRQ; 2120Sstevel@tonic-gate 2130Sstevel@tonic-gate 214941Smyers typedef struct aml_resource_irq_noflags 2150Sstevel@tonic-gate { 216941Smyers AML_RESOURCE_SMALL_HEADER_COMMON 2172623Smyers UINT16 IrqMask; 2180Sstevel@tonic-gate 219941Smyers } AML_RESOURCE_IRQ_NOFLAGS; 2200Sstevel@tonic-gate 2210Sstevel@tonic-gate 222941Smyers typedef struct aml_resource_dma 2230Sstevel@tonic-gate { 224941Smyers AML_RESOURCE_SMALL_HEADER_COMMON 2252623Smyers UINT8 DmaChannelMask; 2262623Smyers UINT8 Flags; 2270Sstevel@tonic-gate 228941Smyers } AML_RESOURCE_DMA; 2290Sstevel@tonic-gate 2300Sstevel@tonic-gate 231941Smyers typedef struct aml_resource_start_dependent 2320Sstevel@tonic-gate { 233941Smyers AML_RESOURCE_SMALL_HEADER_COMMON 2342623Smyers UINT8 Flags; 2350Sstevel@tonic-gate 236941Smyers } AML_RESOURCE_START_DEPENDENT; 2370Sstevel@tonic-gate 2380Sstevel@tonic-gate 239941Smyers typedef struct aml_resource_start_dependent_noprio 2400Sstevel@tonic-gate { 241941Smyers AML_RESOURCE_SMALL_HEADER_COMMON 2420Sstevel@tonic-gate 243941Smyers } AML_RESOURCE_START_DEPENDENT_NOPRIO; 2440Sstevel@tonic-gate 2450Sstevel@tonic-gate 246941Smyers typedef struct aml_resource_end_dependent 2470Sstevel@tonic-gate { 248941Smyers AML_RESOURCE_SMALL_HEADER_COMMON 2490Sstevel@tonic-gate 250941Smyers } AML_RESOURCE_END_DEPENDENT; 2510Sstevel@tonic-gate 2520Sstevel@tonic-gate 253941Smyers typedef struct aml_resource_io 2540Sstevel@tonic-gate { 255941Smyers AML_RESOURCE_SMALL_HEADER_COMMON 2562623Smyers UINT8 Flags; 2572623Smyers UINT16 Minimum; 2582623Smyers UINT16 Maximum; 2592623Smyers UINT8 Alignment; 2602623Smyers UINT8 AddressLength; 2610Sstevel@tonic-gate 262941Smyers } AML_RESOURCE_IO; 2630Sstevel@tonic-gate 2640Sstevel@tonic-gate 265941Smyers typedef struct aml_resource_fixed_io 2660Sstevel@tonic-gate { 267941Smyers AML_RESOURCE_SMALL_HEADER_COMMON 2682623Smyers UINT16 Address; 2692623Smyers UINT8 AddressLength; 2700Sstevel@tonic-gate 271941Smyers } AML_RESOURCE_FIXED_IO; 2720Sstevel@tonic-gate 2730Sstevel@tonic-gate 274941Smyers typedef struct aml_resource_vendor_small 2750Sstevel@tonic-gate { 276941Smyers AML_RESOURCE_SMALL_HEADER_COMMON 2770Sstevel@tonic-gate 278941Smyers } AML_RESOURCE_VENDOR_SMALL; 2790Sstevel@tonic-gate 2800Sstevel@tonic-gate 281941Smyers typedef struct aml_resource_end_tag 2820Sstevel@tonic-gate { 283941Smyers AML_RESOURCE_SMALL_HEADER_COMMON 2842623Smyers UINT8 Checksum; 2850Sstevel@tonic-gate 286941Smyers } AML_RESOURCE_END_TAG; 287941Smyers 288941Smyers 289941Smyers /* 290941Smyers * LARGE descriptors 291941Smyers */ 292941Smyers #define AML_RESOURCE_LARGE_HEADER_COMMON \ 2932623Smyers UINT8 DescriptorType;\ 2942623Smyers UINT16 ResourceLength; 295941Smyers 296941Smyers typedef struct aml_resource_large_header 297941Smyers { 298941Smyers AML_RESOURCE_LARGE_HEADER_COMMON 299941Smyers 300941Smyers } AML_RESOURCE_LARGE_HEADER; 3010Sstevel@tonic-gate 3020Sstevel@tonic-gate 303941Smyers typedef struct aml_resource_memory24 3040Sstevel@tonic-gate { 305941Smyers AML_RESOURCE_LARGE_HEADER_COMMON 3062623Smyers UINT8 Flags; 3072623Smyers UINT16 Minimum; 3082623Smyers UINT16 Maximum; 3092623Smyers UINT16 Alignment; 3102623Smyers UINT16 AddressLength; 3110Sstevel@tonic-gate 312941Smyers } AML_RESOURCE_MEMORY24; 3130Sstevel@tonic-gate 3140Sstevel@tonic-gate 315941Smyers typedef struct aml_resource_vendor_large 3160Sstevel@tonic-gate { 317941Smyers AML_RESOURCE_LARGE_HEADER_COMMON 3180Sstevel@tonic-gate 319941Smyers } AML_RESOURCE_VENDOR_LARGE; 3200Sstevel@tonic-gate 3210Sstevel@tonic-gate 322941Smyers typedef struct aml_resource_memory32 3230Sstevel@tonic-gate { 324941Smyers AML_RESOURCE_LARGE_HEADER_COMMON 3252623Smyers UINT8 Flags; 3262623Smyers UINT32 Minimum; 3272623Smyers UINT32 Maximum; 3282623Smyers UINT32 Alignment; 3292623Smyers UINT32 AddressLength; 3300Sstevel@tonic-gate 331941Smyers } AML_RESOURCE_MEMORY32; 3320Sstevel@tonic-gate 3330Sstevel@tonic-gate 334941Smyers typedef struct aml_resource_fixed_memory32 3350Sstevel@tonic-gate { 336941Smyers AML_RESOURCE_LARGE_HEADER_COMMON 3372623Smyers UINT8 Flags; 3382623Smyers UINT32 Address; 3392623Smyers UINT32 AddressLength; 3400Sstevel@tonic-gate 341941Smyers } AML_RESOURCE_FIXED_MEMORY32; 3420Sstevel@tonic-gate 3430Sstevel@tonic-gate 344941Smyers #define AML_RESOURCE_ADDRESS_COMMON \ 3452623Smyers UINT8 ResourceType; \ 3462623Smyers UINT8 Flags; \ 3472623Smyers UINT8 SpecificFlags; 348941Smyers 349941Smyers 350941Smyers typedef struct aml_resource_address 3510Sstevel@tonic-gate { 352941Smyers AML_RESOURCE_LARGE_HEADER_COMMON 353941Smyers AML_RESOURCE_ADDRESS_COMMON 354941Smyers 355941Smyers } AML_RESOURCE_ADDRESS; 356941Smyers 357941Smyers 358941Smyers typedef struct aml_resource_extended_address64 359941Smyers { 360941Smyers AML_RESOURCE_LARGE_HEADER_COMMON 361941Smyers AML_RESOURCE_ADDRESS_COMMON 3622623Smyers UINT8 RevisionID; 3632623Smyers UINT8 Reserved; 3642623Smyers UINT64 Granularity; 3652623Smyers UINT64 Minimum; 3662623Smyers UINT64 Maximum; 3672623Smyers UINT64 TranslationOffset; 3682623Smyers UINT64 AddressLength; 3692623Smyers UINT64 TypeSpecific; 3700Sstevel@tonic-gate 371941Smyers } AML_RESOURCE_EXTENDED_ADDRESS64; 3720Sstevel@tonic-gate 373941Smyers #define AML_RESOURCE_EXTENDED_ADDRESS_REVISION 1 /* ACPI 3.0 */ 3740Sstevel@tonic-gate 3750Sstevel@tonic-gate 376941Smyers typedef struct aml_resource_address64 3770Sstevel@tonic-gate { 378941Smyers AML_RESOURCE_LARGE_HEADER_COMMON 379941Smyers AML_RESOURCE_ADDRESS_COMMON 3802623Smyers UINT64 Granularity; 3812623Smyers UINT64 Minimum; 3822623Smyers UINT64 Maximum; 3832623Smyers UINT64 TranslationOffset; 3842623Smyers UINT64 AddressLength; 3850Sstevel@tonic-gate 386941Smyers } AML_RESOURCE_ADDRESS64; 3870Sstevel@tonic-gate 3880Sstevel@tonic-gate 389941Smyers typedef struct aml_resource_address32 3900Sstevel@tonic-gate { 391941Smyers AML_RESOURCE_LARGE_HEADER_COMMON 392941Smyers AML_RESOURCE_ADDRESS_COMMON 3932623Smyers UINT32 Granularity; 3942623Smyers UINT32 Minimum; 3952623Smyers UINT32 Maximum; 3962623Smyers UINT32 TranslationOffset; 3972623Smyers UINT32 AddressLength; 3980Sstevel@tonic-gate 399941Smyers } AML_RESOURCE_ADDRESS32; 4000Sstevel@tonic-gate 4010Sstevel@tonic-gate 402941Smyers typedef struct aml_resource_address16 4030Sstevel@tonic-gate { 404941Smyers AML_RESOURCE_LARGE_HEADER_COMMON 405941Smyers AML_RESOURCE_ADDRESS_COMMON 4062623Smyers UINT16 Granularity; 4072623Smyers UINT16 Minimum; 4082623Smyers UINT16 Maximum; 4092623Smyers UINT16 TranslationOffset; 4102623Smyers UINT16 AddressLength; 4110Sstevel@tonic-gate 412941Smyers } AML_RESOURCE_ADDRESS16; 4130Sstevel@tonic-gate 4140Sstevel@tonic-gate 415941Smyers typedef struct aml_resource_extended_irq 4160Sstevel@tonic-gate { 417941Smyers AML_RESOURCE_LARGE_HEADER_COMMON 4182623Smyers UINT8 Flags; 4192623Smyers UINT8 InterruptCount; 4202623Smyers UINT32 Interrupts[1]; 4210Sstevel@tonic-gate /* ResSourceIndex, ResSource optional fields follow */ 4220Sstevel@tonic-gate 423941Smyers } AML_RESOURCE_EXTENDED_IRQ; 4240Sstevel@tonic-gate 4250Sstevel@tonic-gate 426941Smyers typedef struct aml_resource_generic_register 4270Sstevel@tonic-gate { 428941Smyers AML_RESOURCE_LARGE_HEADER_COMMON 4292623Smyers UINT8 AddressSpaceId; 4302623Smyers UINT8 BitWidth; 4312623Smyers UINT8 BitOffset; 4322623Smyers UINT8 AccessSize; /* ACPI 3.0, was previously Reserved */ 4332623Smyers UINT64 Address; 4340Sstevel@tonic-gate 435941Smyers } AML_RESOURCE_GENERIC_REGISTER; 4360Sstevel@tonic-gate 4370Sstevel@tonic-gate /* restore default alignment */ 4380Sstevel@tonic-gate 4390Sstevel@tonic-gate #pragma pack() 4400Sstevel@tonic-gate 4410Sstevel@tonic-gate /* Union of all resource descriptors, so we can allocate the worst case */ 4420Sstevel@tonic-gate 443941Smyers typedef union aml_resource 4440Sstevel@tonic-gate { 445941Smyers /* Descriptor headers */ 446941Smyers 4472623Smyers UINT8 DescriptorType; 4482623Smyers AML_RESOURCE_SMALL_HEADER SmallHeader; 4492623Smyers AML_RESOURCE_LARGE_HEADER LargeHeader; 450941Smyers 451941Smyers /* Small resource descriptors */ 452941Smyers 4532623Smyers AML_RESOURCE_IRQ Irq; 4542623Smyers AML_RESOURCE_DMA Dma; 4552623Smyers AML_RESOURCE_START_DEPENDENT StartDpf; 4562623Smyers AML_RESOURCE_END_DEPENDENT EndDpf; 4572623Smyers AML_RESOURCE_IO Io; 4582623Smyers AML_RESOURCE_FIXED_IO FixedIo; 4592623Smyers AML_RESOURCE_VENDOR_SMALL VendorSmall; 4602623Smyers AML_RESOURCE_END_TAG EndTag; 461941Smyers 462941Smyers /* Large resource descriptors */ 4630Sstevel@tonic-gate 4642623Smyers AML_RESOURCE_MEMORY24 Memory24; 4652623Smyers AML_RESOURCE_GENERIC_REGISTER GenericReg; 4662623Smyers AML_RESOURCE_VENDOR_LARGE VendorLarge; 4672623Smyers AML_RESOURCE_MEMORY32 Memory32; 4682623Smyers AML_RESOURCE_FIXED_MEMORY32 FixedMemory32; 4692623Smyers AML_RESOURCE_ADDRESS16 Address16; 4702623Smyers AML_RESOURCE_ADDRESS32 Address32; 4712623Smyers AML_RESOURCE_ADDRESS64 Address64; 4722623Smyers AML_RESOURCE_EXTENDED_ADDRESS64 ExtAddress64; 4732623Smyers AML_RESOURCE_EXTENDED_IRQ ExtendedIrq; 4740Sstevel@tonic-gate 475941Smyers /* Utility overlays */ 476941Smyers 4772623Smyers AML_RESOURCE_ADDRESS Address; 4782623Smyers UINT32 DwordItem; 4792623Smyers UINT16 WordItem; 4802623Smyers UINT8 ByteItem; 481941Smyers 482941Smyers } AML_RESOURCE; 4830Sstevel@tonic-gate 4840Sstevel@tonic-gate #endif 4850Sstevel@tonic-gate 486