Path: blob/main/sys/contrib/dev/acpica/include/acobject.h
48287 views
/******************************************************************************1*2* Name: acobject.h - Definition of ACPI_OPERAND_OBJECT (Internal object only)3*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 _ACOBJECT_H152#define _ACOBJECT_H153154/* acpisrc:StructDefs -- for acpisrc conversion */155156157/*158* The ACPI_OPERAND_OBJECT is used to pass AML operands from the dispatcher159* to the interpreter, and to keep track of the various handlers such as160* address space handlers and notify handlers. The object is a constant161* size in order to allow it to be cached and reused.162*163* Note: The object is optimized to be aligned and will not work if it is164* byte-packed.165*/166#if ACPI_MACHINE_WIDTH == 64167#pragma pack(8)168#else169#pragma pack(4)170#endif171172/*******************************************************************************173*174* Common Descriptors175*176******************************************************************************/177178/*179* Common area for all objects.180*181* DescriptorType is used to differentiate between internal descriptors, and182* must be in the same place across all descriptors183*184* Note: The DescriptorType and Type fields must appear in the identical185* position in both the ACPI_NAMESPACE_NODE and ACPI_OPERAND_OBJECT186* structures.187*/188#define ACPI_OBJECT_COMMON_HEADER \189union acpi_operand_object *NextObject; /* Objects linked to parent NS node */\190UINT8 DescriptorType; /* To differentiate various internal objs */\191UINT8 Type; /* ACPI_OBJECT_TYPE */\192UINT16 ReferenceCount; /* For object deletion management */\193UINT8 Flags194/*195* Note: There are 3 bytes available here before the196* next natural alignment boundary (for both 32/64 cases)197*/198199/* Values for Flag byte above */200201#define AOPOBJ_AML_CONSTANT 0x01 /* Integer is an AML constant */202#define AOPOBJ_STATIC_POINTER 0x02 /* Data is part of an ACPI table, don't delete */203#define AOPOBJ_DATA_VALID 0x04 /* Object is initialized and data is valid */204#define AOPOBJ_OBJECT_INITIALIZED 0x08 /* Region is initialized */205#define AOPOBJ_REG_CONNECTED 0x10 /* _REG was run */206#define AOPOBJ_SETUP_COMPLETE 0x20 /* Region setup is complete */207#define AOPOBJ_INVALID 0x40 /* Host OS won't allow a Region address */208209210/******************************************************************************211*212* Basic data types213*214*****************************************************************************/215216typedef struct acpi_object_common217{218ACPI_OBJECT_COMMON_HEADER;219220} ACPI_OBJECT_COMMON;221222223typedef struct acpi_object_integer224{225ACPI_OBJECT_COMMON_HEADER;226UINT8 Fill[3]; /* Prevent warning on some compilers */227UINT64 Value;228229} ACPI_OBJECT_INTEGER;230231232/*233* Note: The String and Buffer object must be identical through the234* pointer and length elements. There is code that depends on this.235*236* Fields common to both Strings and Buffers237*/238#define ACPI_COMMON_BUFFER_INFO(_Type) \239_Type *Pointer; \240UINT32 Length241242243/* Null terminated, ASCII characters only */244245typedef struct acpi_object_string246{247ACPI_OBJECT_COMMON_HEADER;248ACPI_COMMON_BUFFER_INFO(char); /* String in AML stream or allocated string */249250} ACPI_OBJECT_STRING;251252253typedef struct acpi_object_buffer254{255ACPI_OBJECT_COMMON_HEADER;256ACPI_COMMON_BUFFER_INFO(UINT8); /* Buffer in AML stream or allocated buffer */257UINT32 AmlLength;258UINT8 *AmlStart;259ACPI_NAMESPACE_NODE *Node; /* Link back to parent node */260261} ACPI_OBJECT_BUFFER;262263264typedef struct acpi_object_package265{266ACPI_OBJECT_COMMON_HEADER;267ACPI_NAMESPACE_NODE *Node; /* Link back to parent node */268union acpi_operand_object **Elements; /* Array of pointers to AcpiObjects */269UINT8 *AmlStart;270UINT32 AmlLength;271UINT32 Count; /* # of elements in package */272273} ACPI_OBJECT_PACKAGE;274275276/******************************************************************************277*278* Complex data types279*280*****************************************************************************/281282typedef struct acpi_object_event283{284ACPI_OBJECT_COMMON_HEADER;285ACPI_SEMAPHORE OsSemaphore; /* Actual OS synchronization object */286287} ACPI_OBJECT_EVENT;288289290typedef struct acpi_object_mutex291{292ACPI_OBJECT_COMMON_HEADER;293UINT8 SyncLevel; /* 0-15, specified in Mutex() call */294UINT16 AcquisitionDepth; /* Allow multiple Acquires, same thread */295ACPI_MUTEX OsMutex; /* Actual OS synchronization object */296ACPI_THREAD_ID ThreadId; /* Current owner of the mutex */297struct acpi_thread_state *OwnerThread; /* Current owner of the mutex */298union acpi_operand_object *Prev; /* Link for list of acquired mutexes */299union acpi_operand_object *Next; /* Link for list of acquired mutexes */300ACPI_NAMESPACE_NODE *Node; /* Containing namespace node */301UINT8 OriginalSyncLevel; /* Owner's original sync level (0-15) */302303} ACPI_OBJECT_MUTEX;304305306typedef struct acpi_object_region307{308ACPI_OBJECT_COMMON_HEADER;309UINT8 SpaceId;310ACPI_NAMESPACE_NODE *Node; /* Containing namespace node */311union acpi_operand_object *Handler; /* Handler for region access */312union acpi_operand_object *Next;313ACPI_PHYSICAL_ADDRESS Address;314UINT32 Length;315void *Pointer; /* Only for data table regions */316317} ACPI_OBJECT_REGION;318319320typedef struct acpi_object_method321{322ACPI_OBJECT_COMMON_HEADER;323UINT8 InfoFlags;324UINT8 ParamCount;325UINT8 SyncLevel;326union acpi_operand_object *Mutex;327union acpi_operand_object *Node;328UINT8 *AmlStart;329union330{331ACPI_INTERNAL_METHOD Implementation;332union acpi_operand_object *Handler;333} Dispatch;334335UINT32 AmlLength;336ACPI_OWNER_ID OwnerId;337UINT8 ThreadCount;338339} ACPI_OBJECT_METHOD;340341/* Flags for InfoFlags field above */342343#define ACPI_METHOD_MODULE_LEVEL 0x01 /* Method is actually module-level code */344#define ACPI_METHOD_INTERNAL_ONLY 0x02 /* Method is implemented internally (_OSI) */345#define ACPI_METHOD_SERIALIZED 0x04 /* Method is serialized */346#define ACPI_METHOD_SERIALIZED_PENDING 0x08 /* Method is to be marked serialized */347#define ACPI_METHOD_IGNORE_SYNC_LEVEL 0x10 /* Method was auto-serialized at table load time */348#define ACPI_METHOD_MODIFIED_NAMESPACE 0x20 /* Method modified the namespace */349350351/******************************************************************************352*353* Objects that can be notified. All share a common NotifyInfo area.354*355*****************************************************************************/356357/*358* Common fields for objects that support ASL notifications359*/360#define ACPI_COMMON_NOTIFY_INFO \361union acpi_operand_object *NotifyList[2]; /* Handlers for system/device notifies */\362union acpi_operand_object *Handler /* Handler for Address space */363364/* COMMON NOTIFY for POWER, PROCESSOR, DEVICE, and THERMAL */365366typedef struct acpi_object_notify_common367{368ACPI_OBJECT_COMMON_HEADER;369ACPI_COMMON_NOTIFY_INFO;370371} ACPI_OBJECT_NOTIFY_COMMON;372373374typedef struct acpi_object_device375{376ACPI_OBJECT_COMMON_HEADER;377ACPI_COMMON_NOTIFY_INFO;378ACPI_GPE_BLOCK_INFO *GpeBlock;379380} ACPI_OBJECT_DEVICE;381382383typedef struct acpi_object_power_resource384{385ACPI_OBJECT_COMMON_HEADER;386ACPI_COMMON_NOTIFY_INFO;387UINT32 SystemLevel;388UINT32 ResourceOrder;389390} ACPI_OBJECT_POWER_RESOURCE;391392393typedef struct acpi_object_processor394{395ACPI_OBJECT_COMMON_HEADER;396397/* The next two fields take advantage of the 3-byte space before NOTIFY_INFO */398399UINT8 ProcId;400UINT8 Length;401ACPI_COMMON_NOTIFY_INFO;402ACPI_IO_ADDRESS Address;403404} ACPI_OBJECT_PROCESSOR;405406407typedef struct acpi_object_thermal_zone408{409ACPI_OBJECT_COMMON_HEADER;410ACPI_COMMON_NOTIFY_INFO;411412} ACPI_OBJECT_THERMAL_ZONE;413414415/******************************************************************************416*417* Fields. All share a common header/info field.418*419*****************************************************************************/420421/*422* Common bitfield for the field objects423* "Field Datum" -- a datum from the actual field object424* "Buffer Datum" -- a datum from a user buffer, read from or to be written to the field425*/426#define ACPI_COMMON_FIELD_INFO \427UINT8 FieldFlags; /* Access, update, and lock bits */\428UINT8 Attribute; /* From AccessAs keyword */\429UINT8 AccessByteWidth; /* Read/Write size in bytes */\430ACPI_NAMESPACE_NODE *Node; /* Link back to parent node */\431UINT32 BitLength; /* Length of field in bits */\432UINT32 BaseByteOffset; /* Byte offset within containing object */\433UINT32 Value; /* Value to store into the Bank or Index register */\434UINT8 StartFieldBitOffset;/* Bit offset within first field datum (0-63) */\435UINT8 AccessLength /* For serial regions/fields */436437/* COMMON FIELD (for BUFFER, REGION, BANK, and INDEX fields) */438439typedef struct acpi_object_field_common440{441ACPI_OBJECT_COMMON_HEADER;442ACPI_COMMON_FIELD_INFO;443union acpi_operand_object *RegionObj; /* Parent Operation Region object (REGION/BANK fields only) */444445} ACPI_OBJECT_FIELD_COMMON;446447448typedef struct acpi_object_region_field449{450ACPI_OBJECT_COMMON_HEADER;451ACPI_COMMON_FIELD_INFO;452UINT16 ResourceLength;453union acpi_operand_object *RegionObj; /* Containing OpRegion object */454UINT8 *ResourceBuffer; /* ResourceTemplate for serial regions/fields */455UINT16 PinNumberIndex; /* Index relative to previous Connection/Template */456UINT8 *InternalPccBuffer; /* Internal buffer for fields associated with PCC */457458} ACPI_OBJECT_REGION_FIELD;459460461typedef struct acpi_object_bank_field462{463ACPI_OBJECT_COMMON_HEADER;464ACPI_COMMON_FIELD_INFO;465union acpi_operand_object *RegionObj; /* Containing OpRegion object */466union acpi_operand_object *BankObj; /* BankSelect Register object */467468} ACPI_OBJECT_BANK_FIELD;469470471typedef struct acpi_object_index_field472{473ACPI_OBJECT_COMMON_HEADER;474ACPI_COMMON_FIELD_INFO;475476/*477* No "RegionObj" pointer needed since the Index and Data registers478* are each field definitions unto themselves.479*/480union acpi_operand_object *IndexObj; /* Index register */481union acpi_operand_object *DataObj; /* Data register */482483} ACPI_OBJECT_INDEX_FIELD;484485486/* The BufferField is different in that it is part of a Buffer, not an OpRegion */487488typedef struct acpi_object_buffer_field489{490ACPI_OBJECT_COMMON_HEADER;491ACPI_COMMON_FIELD_INFO;492BOOLEAN IsCreateField; /* Special case for objects created by CreateField() */493union acpi_operand_object *BufferObj; /* Containing Buffer object */494495} ACPI_OBJECT_BUFFER_FIELD;496497498/******************************************************************************499*500* Objects for handlers501*502*****************************************************************************/503504typedef struct acpi_object_notify_handler505{506ACPI_OBJECT_COMMON_HEADER;507ACPI_NAMESPACE_NODE *Node; /* Parent device */508UINT32 HandlerType; /* Type: Device/System/Both */509ACPI_NOTIFY_HANDLER Handler; /* Handler address */510void *Context;511union acpi_operand_object *Next[2]; /* Device and System handler lists */512513} ACPI_OBJECT_NOTIFY_HANDLER;514515516typedef struct acpi_object_addr_handler517{518ACPI_OBJECT_COMMON_HEADER;519UINT8 SpaceId;520UINT8 HandlerFlags;521ACPI_ADR_SPACE_HANDLER Handler;522ACPI_NAMESPACE_NODE *Node; /* Parent device */523void *Context;524ACPI_MUTEX ContextMutex;525ACPI_ADR_SPACE_SETUP Setup;526union acpi_operand_object *RegionList; /* Regions using this handler */527union acpi_operand_object *Next;528529} ACPI_OBJECT_ADDR_HANDLER;530531/* Flags for address handler (HandlerFlags) */532533#define ACPI_ADDR_HANDLER_DEFAULT_INSTALLED 0x01534535536/******************************************************************************537*538* Special internal objects539*540*****************************************************************************/541542/*543* The Reference object is used for these opcodes:544* Arg[0-6], Local[0-7], IndexOp, NameOp, RefOfOp, LoadOp, LoadTableOp, DebugOp545* The Reference.Class differentiates these types.546*/547typedef struct acpi_object_reference548{549ACPI_OBJECT_COMMON_HEADER;550UINT8 Class; /* Reference Class */551UINT8 TargetType; /* Used for Index Op */552UINT8 Resolved; /* Reference has been resolved to a value */553void *Object; /* NameOp=>HANDLE to obj, IndexOp=>ACPI_OPERAND_OBJECT */554ACPI_NAMESPACE_NODE *Node; /* RefOf or Namepath */555union acpi_operand_object **Where; /* Target of Index */556UINT8 *IndexPointer; /* Used for Buffers and Strings */557UINT8 *Aml; /* Used for deferred resolution of the ref */558UINT32 Value; /* Used for Local/Arg/Index/DdbHandle */559560} ACPI_OBJECT_REFERENCE;561562/* Values for Reference.Class above */563564typedef enum565{566ACPI_REFCLASS_LOCAL = 0, /* Method local */567ACPI_REFCLASS_ARG = 1, /* Method argument */568ACPI_REFCLASS_REFOF = 2, /* Result of RefOf() TBD: Split to Ref/Node and Ref/OperandObj? */569ACPI_REFCLASS_INDEX = 3, /* Result of Index() */570ACPI_REFCLASS_TABLE = 4, /* DdbHandle - Load(), LoadTable() */571ACPI_REFCLASS_NAME = 5, /* Reference to a named object */572ACPI_REFCLASS_DEBUG = 6, /* Debug object */573574ACPI_REFCLASS_MAX = 6575576} ACPI_REFERENCE_CLASSES;577578/*579* Extra object is used as additional storage for types that580* have AML code in their declarations (TermArgs) that must be581* evaluated at run time.582*583* Currently: Region and FieldUnit types584*/585typedef struct acpi_object_extra586{587ACPI_OBJECT_COMMON_HEADER;588ACPI_NAMESPACE_NODE *Method_REG; /* _REG method for this region (if any) */589ACPI_NAMESPACE_NODE *ScopeNode;590void *RegionContext; /* Region-specific data */591UINT8 *AmlStart;592UINT32 AmlLength;593594} ACPI_OBJECT_EXTRA;595596597/* Additional data that can be attached to namespace nodes */598599typedef struct acpi_object_data600{601ACPI_OBJECT_COMMON_HEADER;602ACPI_OBJECT_HANDLER Handler;603void *Pointer;604605} ACPI_OBJECT_DATA;606607608/* Structure used when objects are cached for reuse */609610typedef struct acpi_object_cache_list611{612ACPI_OBJECT_COMMON_HEADER;613union acpi_operand_object *Next; /* Link for object cache and internal lists*/614615} ACPI_OBJECT_CACHE_LIST;616617618/******************************************************************************619*620* ACPI_OPERAND_OBJECT Descriptor - a giant union of all of the above621*622*****************************************************************************/623624typedef union acpi_operand_object625{626ACPI_OBJECT_COMMON Common;627ACPI_OBJECT_INTEGER Integer;628ACPI_OBJECT_STRING String;629ACPI_OBJECT_BUFFER Buffer;630ACPI_OBJECT_PACKAGE Package;631ACPI_OBJECT_EVENT Event;632ACPI_OBJECT_METHOD Method;633ACPI_OBJECT_MUTEX Mutex;634ACPI_OBJECT_REGION Region;635ACPI_OBJECT_NOTIFY_COMMON CommonNotify;636ACPI_OBJECT_DEVICE Device;637ACPI_OBJECT_POWER_RESOURCE PowerResource;638ACPI_OBJECT_PROCESSOR Processor;639ACPI_OBJECT_THERMAL_ZONE ThermalZone;640ACPI_OBJECT_FIELD_COMMON CommonField;641ACPI_OBJECT_REGION_FIELD Field;642ACPI_OBJECT_BUFFER_FIELD BufferField;643ACPI_OBJECT_BANK_FIELD BankField;644ACPI_OBJECT_INDEX_FIELD IndexField;645ACPI_OBJECT_NOTIFY_HANDLER Notify;646ACPI_OBJECT_ADDR_HANDLER AddressSpace;647ACPI_OBJECT_REFERENCE Reference;648ACPI_OBJECT_EXTRA Extra;649ACPI_OBJECT_DATA Data;650ACPI_OBJECT_CACHE_LIST Cache;651652/*653* Add namespace node to union in order to simplify code that accepts both654* ACPI_OPERAND_OBJECTs and ACPI_NAMESPACE_NODEs. The structures share655* a common DescriptorType field in order to differentiate them.656*/657ACPI_NAMESPACE_NODE Node;658659} ACPI_OPERAND_OBJECT;660661662/******************************************************************************663*664* ACPI_DESCRIPTOR - objects that share a common descriptor identifier665*666*****************************************************************************/667668/* Object descriptor types */669670#define ACPI_DESC_TYPE_CACHED 0x01 /* Used only when object is cached */671#define ACPI_DESC_TYPE_STATE 0x02672#define ACPI_DESC_TYPE_STATE_UPDATE 0x03673#define ACPI_DESC_TYPE_STATE_PACKAGE 0x04674#define ACPI_DESC_TYPE_STATE_CONTROL 0x05675#define ACPI_DESC_TYPE_STATE_RPSCOPE 0x06676#define ACPI_DESC_TYPE_STATE_PSCOPE 0x07677#define ACPI_DESC_TYPE_STATE_WSCOPE 0x08678#define ACPI_DESC_TYPE_STATE_RESULT 0x09679#define ACPI_DESC_TYPE_STATE_NOTIFY 0x0A680#define ACPI_DESC_TYPE_STATE_THREAD 0x0B681#define ACPI_DESC_TYPE_WALK 0x0C682#define ACPI_DESC_TYPE_PARSER 0x0D683#define ACPI_DESC_TYPE_OPERAND 0x0E684#define ACPI_DESC_TYPE_NAMED 0x0F685#define ACPI_DESC_TYPE_MAX 0x0F686687688typedef struct acpi_common_descriptor689{690void *CommonPointer;691UINT8 DescriptorType; /* To differentiate various internal objs */692693} ACPI_COMMON_DESCRIPTOR;694695typedef union acpi_descriptor696{697ACPI_COMMON_DESCRIPTOR Common;698ACPI_OPERAND_OBJECT Object;699ACPI_NAMESPACE_NODE Node;700ACPI_PARSE_OBJECT Op;701702} ACPI_DESCRIPTOR;703704#pragma pack()705706#endif /* _ACOBJECT_H */707708709