diff options
author | Robert Moore <Robert.Moore@intel.com> | 2011-09-13 15:00:42 -0700 |
---|---|---|
committer | Lin Ming <ming.m.lin@intel.com> | 2011-11-10 10:10:25 +0800 |
commit | 03c8c470cc8e8b61c42f6b2b63553267141a4a55 (patch) | |
tree | 8954ba0394dba96e365d82efce2cd663477f585a /source/compiler/aslrestype2s.c | |
parent | ac147fca7d07f9be9fbdfef161ce29ba54be1ca7 (diff) | |
download | acpica-03c8c470cc8e8b61c42f6b2b63553267141a4a55.tar.gz |
ACPI 5.0/iASL: Update comments/headers for new descriptor file.
Finish the headers for this new file. Make local functions static.
Diffstat (limited to 'source/compiler/aslrestype2s.c')
-rw-r--r-- | source/compiler/aslrestype2s.c | 37 |
1 files changed, 33 insertions, 4 deletions
diff --git a/source/compiler/aslrestype2s.c b/source/compiler/aslrestype2s.c index 63b462689..6ee627737 100644 --- a/source/compiler/aslrestype2s.c +++ b/source/compiler/aslrestype2s.c @@ -122,11 +122,11 @@ ACPI_MODULE_NAME ("aslrestype2s") -UINT16 +static UINT16 RsGetBufferDataLength ( ACPI_PARSE_OBJECT *InitializerOp); -UINT16 +static UINT16 RsGetInterruptDataLength ( ACPI_PARSE_OBJECT *InitializerOp); @@ -151,9 +151,16 @@ RsGetVendorData ( * * FUNCTION: RsGetBufferDataLength * + * PARAMETERS: InitializerOp - Current parse op, start of the resource + * descriptor + * + * RETURN: Length of the data buffer + * + * DESCRIPTION: Get the length of a RawDataBuffer, used for vendor data. + * ******************************************************************************/ -UINT16 +static UINT16 RsGetBufferDataLength ( ACPI_PARSE_OBJECT *InitializerOp) { @@ -161,6 +168,8 @@ RsGetBufferDataLength ( ACPI_PARSE_OBJECT *DataList; + /* Find the byte-initializer list */ + while (InitializerOp) { if (InitializerOp->Asl.ParseOpcode == PARSEOP_DATABUFFER) @@ -180,6 +189,7 @@ RsGetBufferDataLength ( return (ExtraDataSize); } + InitializerOp = ASL_GET_PEER_NODE (InitializerOp); } @@ -191,9 +201,17 @@ RsGetBufferDataLength ( * * FUNCTION: RsGetInterruptDataLength * + * PARAMETERS: InitializerOp - Current parse op, start of the resource + * descriptor + * + * RETURN: Length of the interrupt data list + * + * DESCRIPTION: Get the length of a list of interrupt DWORDs for the GPIO + * descriptors. + * ******************************************************************************/ -UINT16 +static UINT16 RsGetInterruptDataLength ( ACPI_PARSE_OBJECT *InitializerOp) { @@ -208,6 +226,8 @@ RsGetInterruptDataLength ( { InitializerOp = ASL_GET_PEER_NODE (InitializerOp); + /* Interrupt list starts at offset 10 (Gpio descriptors) */ + if (i >= 10) { InterruptLength += 2; @@ -222,6 +242,15 @@ RsGetInterruptDataLength ( * * FUNCTION: RsGetVendorData * + * PARAMETERS: InitializerOp - Current parse op, start of the resource + * descriptor. + * VendorData - Where the vendor data is returned + * DescriptorOffset - Where vendor data begins in descriptor + * + * RETURN: TRUE if valid vendor data was returned, FALSE otherwise. + * + * DESCRIPTION: Extract the vendor data and construct a vendor data buffer. + * ******************************************************************************/ static BOOLEAN |