50#define _COMPONENT ACPI_RESOURCES
67 UINT32 MinimumTotalLength);
93 for (BitsSet = 0;
BitField; BitsSet++)
158 UINT32 MinimumAmlResourceLength)
179 if (ResourceLength > MinimumAmlResourceLength)
183 StringLength = ResourceLength - MinimumAmlResourceLength - 1;
213 ACPI_SIZE ResourceListSize,
214 ACPI_SIZE *SizeNeeded)
216 ACPI_SIZE AmlSizeNeeded = 0;
257 if (
Resource->Data.Irq.DescriptorLength == 2)
268 if (
Resource->Data.Irq.DescriptorLength == 0)
282 if (
Resource->Data.Vendor.ByteLength > 7)
292 (TotalSize +
Resource->Data.Vendor.ByteLength);
301 *SizeNeeded = AmlSizeNeeded + TotalSize;
315 &
Resource->Data.Address16.ResourceSource));
326 &
Resource->Data.Address32.ResourceSource));
337 &
Resource->Data.Address64.ResourceSource));
348 ((
Resource->Data.ExtendedIrq.InterruptCount - 1) * 4) +
353 &
Resource->Data.ExtendedIrq.ResourceSource));
360 (
Resource->Data.Gpio.PinTableLength * 2) +
361 Resource->Data.Gpio.ResourceSource.StringLength +
369 (
Resource->Data.PinFunction.PinTableLength * 2) +
370 Resource->Data.PinFunction.ResourceSource.StringLength +
371 Resource->Data.PinFunction.VendorLength);
379 Resource->Data.CommonSerialBus.Type];
382 Resource->Data.I2cSerialBus.ResourceSource.StringLength +
383 Resource->Data.I2cSerialBus.VendorLength);
390 (
Resource->Data.PinConfig.PinTableLength * 2) +
391 Resource->Data.PinConfig.ResourceSource.StringLength +
392 Resource->Data.PinConfig.VendorLength);
399 (
Resource->Data.PinGroup.PinTableLength * 2) +
400 Resource->Data.PinGroup.ResourceLabel.StringLength +
401 Resource->Data.PinGroup.VendorLength);
408 Resource->Data.PinGroupFunction.ResourceSource.StringLength +
409 Resource->Data.PinGroupFunction.ResourceSourceLabel.StringLength +
410 Resource->Data.PinGroupFunction.VendorLength);
417 Resource->Data.PinGroupConfig.ResourceSource.StringLength +
418 Resource->Data.PinGroupConfig.ResourceSourceLabel.StringLength +
419 Resource->Data.PinGroupConfig.VendorLength);
430 AmlSizeNeeded += TotalSize;
463 ACPI_SIZE *SizeNeeded)
473 UINT8 MinimumAmlResourceLength;
485 while (AmlBuffer < EndAml)
499 AmlResource = (
void *) AmlBuffer;
510 ExtraStructBytes = 0;
540 ExtraStructBytes = ResourceLength;
547 if (ExtraStructBytes)
569 ResourceLength, MinimumAmlResourceLength);
585 ResourceLength - ExtraStructBytes, MinimumAmlResourceLength);
634 MinimumAmlResourceLength;
711 "Type %.2X, AmlLength %.2X InternalLength %.2X%8X\n",
751 ACPI_SIZE TempSizeNeeded = 0;
781 PackageElement = *TopObjectList;
785 if (!PackageElement ||
802 TableIndex < PackageElement->
Package.
Count && !NameFound;
805 if (*SubObjectList &&
808 (*SubObjectList)->Common.Type) ||
811 (*SubObjectList)->Common.Type) &&
813 ((*SubObjectList)->Reference.Class ==
838 TempSizeNeeded += ((ACPI_SIZE)
839 (*SubObjectList)->String.Length + 1);
844 (*SubObjectList)->Reference.Node);
853 TempSizeNeeded +=
sizeof (
UINT32);
#define AE_AML_INVALID_RESOURCE_TYPE
#define AE_AML_BAD_RESOURCE_LENGTH
#define AE_AML_NO_RESOURCE_END_TAG
#define AE_AML_OPERAND_TYPE
#define ACPI_RESOURCE_NAME_ADDRESS64
#define ACPI_RESOURCE_NAME_VENDOR_LARGE
#define ACPI_RESOURCE_NAME_DMA
#define ACPI_RESOURCE_NAME_ADDRESS32
#define ACPI_RESOURCE_NAME_VENDOR_SMALL
#define ACPI_RESOURCE_NAME_END_TAG
#define ACPI_RESOURCE_NAME_PIN_FUNCTION
#define ACPI_RESOURCE_NAME_PIN_GROUP
#define ACPI_RESOURCE_NAME_ADDRESS16
#define ACPI_RESOURCE_NAME_PIN_GROUP_CONFIG
#define ACPI_RESOURCE_NAME_IRQ
#define ACPI_RESOURCE_NAME_PIN_GROUP_FUNCTION
#define ACPI_RESOURCE_NAME_GPIO
#define ACPI_RESOURCE_NAME_EXTENDED_IRQ
#define ACPI_RESOURCE_NAME_PIN_CONFIG
#define ACPI_RESOURCE_NAME_SERIAL_BUS
#define ACPI_FORMAT_UINT64(i)
#define ACPI_MOVE_16_TO_16(d, s)
#define ACPI_ROUND_UP_TO_NATIVE_WORD(a)
#define ACPI_ROUND_UP_TO_64BIT(a)
ACPI_SIZE AcpiNsGetPathnameLength(ACPI_NAMESPACE_NODE *Node)
#define ACPI_DEBUG_PRINT(pl)
#define ACPI_MODULE_NAME(Name)
#define ACPI_FUNCTION_ENTRY()
#define return_ACPI_STATUS(s)
#define ACPI_FUNCTION_TRACE(a)
#define ACPI_DB_RESOURCES
ACPI_BUFFER *RetBuffer ACPI_BUFFER *RetBuffer char ACPI_WALK_RESOURCE_CALLBACK void *Context ACPI_BUFFER *RetBuffer UINT16 AmlBufferLength
const UINT8 AcpiGbl_AmlResourceSizes[]
const UINT8 AcpiGbl_ResourceStructSerialBusSizes[]
const UINT8 AcpiGbl_AmlResourceSerialBusSizes[]
const UINT8 AcpiGbl_ResourceStructSizes[]
#define ACPI_RESOURCE_TYPE_PIN_FUNCTION
#define ACPI_RESOURCE_TYPE_SERIAL_BUS
#define ACPI_RESOURCE_TYPE_GPIO
#define ACPI_RESOURCE_TYPE_EXTENDED_IRQ
#define ACPI_RESOURCE_TYPE_PIN_CONFIG
#define ACPI_RESOURCE_TYPE_PIN_GROUP_CONFIG
#define ACPI_RESOURCE_TYPE_IRQ
struct acpi_pci_routing_table ACPI_PCI_ROUTING_TABLE
#define ACPI_RESOURCE_TYPE_END_TAG
#define ACPI_RESOURCE_TYPE_START_DEPENDENT
#define ACPI_RESOURCE_TYPE_MAX
#define ACPI_RESOURCE_TYPE_VENDOR
#define ACPI_RESOURCE_TYPE_PIN_GROUP_FUNCTION
#define ACPI_RESOURCE_TYPE_ADDRESS64
#define ACPI_RESOURCE_TYPE_PIN_GROUP
#define ACPI_RESOURCE_TYPE_ADDRESS32
#define ACPI_RESOURCE_TYPE_ADDRESS16
#define ACPI_TYPE_LOCAL_REFERENCE
#define ACPI_ADD_PTR(t, a, b)
#define ACPI_TYPE_PACKAGE
const UINT8 AcpiGbl_ResourceAmlSizes[]
UINT16 AcpiUtGetResourceLength(void *Aml)
UINT8 AcpiUtGetResourceHeaderLength(void *Aml)
UINT32 AcpiUtGetDescriptorLength(void *Aml)
const UINT8 AcpiGbl_ResourceAmlSerialBusSizes[]
ACPI_STATUS AcpiUtValidateResource(ACPI_WALK_STATE *WalkState, void *Aml, UINT8 *ReturnIndex)
UINT8 AcpiUtGetResourceType(void *Aml)
struct aml_resource_large_header AML_RESOURCE_LARGE_HEADER
_Acquires_exclusive_lock_ Resource _Acquires_shared_lock_ Resource _Inout_ PERESOURCE Resource
_Must_inspect_result_ _Inout_opt_ PUNICODE_STRING _Out_opt_ PULONG BufferSizeNeeded
static UINT32 AcpiRsStreamOptionLength(UINT32 ResourceLength, UINT32 MinimumTotalLength)
ACPI_STATUS AcpiRsGetAmlLength(ACPI_RESOURCE *Resource, ACPI_SIZE ResourceListSize, ACPI_SIZE *SizeNeeded)
ACPI_STATUS AcpiRsGetListLength(UINT8 *AmlBuffer, UINT32 AmlBufferLength, ACPI_SIZE *SizeNeeded)
ACPI_STATUS AcpiRsGetPciRoutingTableLength(ACPI_OPERAND_OBJECT *PackageObject, ACPI_SIZE *BufferSizeNeeded)
static UINT8 AcpiRsCountSetBits(UINT16 BitField)
static ACPI_RS_LENGTH AcpiRsStructOptionLength(ACPI_RESOURCE_SOURCE *ResourceSource)
union acpi_operand_object ** Elements
ACPI_OBJECT_COMMON Common
ACPI_OBJECT_PACKAGE Package
AML_RESOURCE_PIN_CONFIG PinConfig
AML_RESOURCE_PIN_GROUP PinGroup
AML_RESOURCE_PIN_GROUP_FUNCTION PinGroupFunction
AML_RESOURCE_PIN_GROUP_CONFIG PinGroupConfig
AML_RESOURCE_LARGE_HEADER LargeHeader
AML_RESOURCE_COMMON_SERIALBUS CommonSerialBus
AML_RESOURCE_PIN_FUNCTION PinFunction
_In_ WDFCOLLECTION _In_ ULONG Index
_In_ WDFMEMORY _Out_opt_ size_t * BufferSize