1 /******************************************************************************
3 * Module Name: aehandlers - Various handlers for acpiexec
5 *****************************************************************************/
7 /******************************************************************************
11 * Some or all of this work - Copyright (c) 1999 - 2009, Intel Corp.
12 * All rights reserved.
16 * 2.1. This is your license from Intel Corp. under its intellectual property
17 * rights. You may have additional license terms from the party that provided
18 * you this software, covering your right to use that party's intellectual
21 * 2.2. Intel grants, free of charge, to any person ("Licensee") obtaining a
22 * copy of the source code appearing in this file ("Covered Code") an
23 * irrevocable, perpetual, worldwide license under Intel's copyrights in the
24 * base code distributed originally by Intel ("Original Intel Code") to copy,
25 * make derivatives, distribute, use and display any portion of the Covered
26 * Code in any form, with the right to sublicense such rights; and
28 * 2.3. Intel grants Licensee a non-exclusive and non-transferable patent
29 * license (with the right to sublicense), under only those claims of Intel
30 * patents that are infringed by the Original Intel Code, to make, use, sell,
31 * offer to sell, and import the Covered Code and derivative works thereof
32 * solely to the minimum extent necessary to exercise the above copyright
33 * license, and in no event shall the patent license extend to any additions
34 * to or modifications of the Original Intel Code. No other license or right
35 * is granted directly or by implication, estoppel or otherwise;
37 * The above copyright and patent license is granted only if the following
42 * 3.1. Redistribution of Source with Rights to Further Distribute Source.
43 * Redistribution of source code of any substantial portion of the Covered
44 * Code or modification with rights to further distribute source must include
45 * the above Copyright Notice, the above License, this list of Conditions,
46 * and the following Disclaimer and Export Compliance provision. In addition,
47 * Licensee must cause all Covered Code to which Licensee contributes to
48 * contain a file documenting the changes Licensee made to create that Covered
49 * Code and the date of any change. Licensee must include in that file the
50 * documentation of any changes made by any predecessor Licensee. Licensee
51 * must include a prominent statement that the modification is derived,
52 * directly or indirectly, from Original Intel Code.
54 * 3.2. Redistribution of Source with no Rights to Further Distribute Source.
55 * Redistribution of source code of any substantial portion of the Covered
56 * Code or modification without rights to further distribute source must
57 * include the following Disclaimer and Export Compliance provision in the
58 * documentation and/or other materials provided with distribution. In
59 * addition, Licensee may not authorize further sublicense of source of any
60 * portion of the Covered Code, and must include terms to the effect that the
61 * license from Licensee to its licensee is limited to the intellectual
62 * property embodied in the software Licensee provides to its licensee, and
63 * not to intellectual property embodied in modifications its licensee may
66 * 3.3. Redistribution of Executable. Redistribution in executable form of any
67 * substantial portion of the Covered Code or modification must reproduce the
68 * above Copyright Notice, and the following Disclaimer and Export Compliance
69 * provision in the documentation and/or other materials provided with the
72 * 3.4. Intel retains all right, title, and interest in and to the Original
75 * 3.5. Neither the name Intel nor any other trademark owned or controlled by
76 * Intel shall be used in advertising or otherwise to promote the sale, use or
77 * other dealings in products derived from or relating to the Covered Code
78 * without prior written authorization from Intel.
80 * 4. Disclaimer and Export Compliance
82 * 4.1. INTEL MAKES NO WARRANTY OF ANY KIND REGARDING ANY SOFTWARE PROVIDED
83 * HERE. ANY SOFTWARE ORIGINATING FROM INTEL OR DERIVED FROM INTEL SOFTWARE
84 * IS PROVIDED "AS IS," AND INTEL WILL NOT PROVIDE ANY SUPPORT, ASSISTANCE,
85 * INSTALLATION, TRAINING OR OTHER SERVICES. INTEL WILL NOT PROVIDE ANY
86 * UPDATES, ENHANCEMENTS OR EXTENSIONS. INTEL SPECIFICALLY DISCLAIMS ANY
87 * IMPLIED WARRANTIES OF MERCHANTABILITY, NONINFRINGEMENT AND FITNESS FOR A
90 * 4.2. IN NO EVENT SHALL INTEL HAVE ANY LIABILITY TO LICENSEE, ITS LICENSEES
91 * OR ANY OTHER THIRD PARTY, FOR ANY LOST PROFITS, LOST DATA, LOSS OF USE OR
92 * COSTS OF PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES, OR FOR ANY INDIRECT,
93 * SPECIAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THIS AGREEMENT, UNDER ANY
94 * CAUSE OF ACTION OR THEORY OF LIABILITY, AND IRRESPECTIVE OF WHETHER INTEL
95 * HAS ADVANCE NOTICE OF THE POSSIBILITY OF SUCH DAMAGES. THESE LIMITATIONS
96 * SHALL APPLY NOTWITHSTANDING THE FAILURE OF THE ESSENTIAL PURPOSE OF ANY
99 * 4.3. Licensee shall not export, either directly or indirectly, any of this
100 * software or system incorporating such software without first obtaining any
101 * required license or other approval from the U. S. Department of Commerce or
102 * any other agency or department of the United States Government. In the
103 * event Licensee exports any such software from the United States or
104 * re-exports any such software from a foreign destination, Licensee shall
105 * ensure that the distribution and export/re-export of the software is in
106 * compliance with all laws, regulations, orders, or other restrictions of the
107 * U.S. Export Administration Regulations. Licensee agrees that neither it nor
108 * any of its subsidiaries will export/re-export any technical data, process,
109 * software, or service, directly or indirectly, to any country for which the
110 * United States government or any agency thereof requires an export license,
111 * other governmental approval, or letter of assurance, without first obtaining
112 * such license, approval or letter.
114 *****************************************************************************/
116 #include "aecommon.h"
118 #define _COMPONENT ACPI_TOOLS
119 ACPI_MODULE_NAME ("aehandlers")
121 /* Local prototypes */
130 AeDeviceNotifyHandler (
137 ACPI_STATUS AmlStatus
,
151 ACPI_HANDLE RegionHandle
,
153 void *HandlerContext
,
154 void **RegionContext
);
157 AeAttachedDataHandler (
161 UINT32 SigintCount
= 0;
162 AE_DEBUG_REGIONS AeRegions
;
165 /******************************************************************************
167 * FUNCTION: AeCtrlCHandler
173 * DESCRIPTION: Control-C handler. Abort running control method if any.
175 *****************************************************************************/
182 signal (SIGINT
, SIG_IGN
);
185 AcpiOsPrintf ("Caught a ctrl-c (#%d)\n\n", SigintCount
);
187 if (AcpiGbl_MethodExecuting
)
189 AcpiGbl_AbortMethod
= TRUE
;
190 signal (SIGINT
, AeCtrlCHandler
);
192 if (SigintCount
< 10)
202 /******************************************************************************
204 * FUNCTION: AeNotifyHandler
206 * PARAMETERS: Standard notify handler parameters
210 * DESCRIPTION: System notify handler for AcpiExec utility. Used by the ASL
211 * test suite(s) to communicate errors and other information to
212 * this utility via the Notify() operator.
214 *****************************************************************************/
227 printf ("[AcpiExec] Method Error 0x%X: Results not equal\n", Value
);
228 if (AcpiGbl_DebugFile
)
230 AcpiOsPrintf ("[AcpiExec] Method Error: Results not equal\n");
236 printf ("[AcpiExec] Method Error: Incorrect numeric result\n");
237 if (AcpiGbl_DebugFile
)
239 AcpiOsPrintf ("[AcpiExec] Method Error: Incorrect numeric result\n");
245 printf ("[AcpiExec] Method Error: An operand was overwritten\n");
246 if (AcpiGbl_DebugFile
)
248 AcpiOsPrintf ("[AcpiExec] Method Error: An operand was overwritten\n");
255 printf ("[AcpiExec] Received a System Notify on [%4.4s] %p Value 0x%2.2X (%s)\n",
256 AcpiUtGetNodeName (Device
), Device
, Value
,
257 AcpiUtGetNotifyName (Value
));
258 if (AcpiGbl_DebugFile
)
260 AcpiOsPrintf ("[AcpiExec] Received a system notify, Value 0x%2.2X\n", Value
);
263 (void) AcpiEvaluateObject (Device
, "_NOT", NULL
, NULL
);
270 /******************************************************************************
272 * FUNCTION: AeDeviceNotifyHandler
274 * PARAMETERS: Standard notify handler parameters
278 * DESCRIPTION: Device notify handler for AcpiExec utility. Used by the ASL
279 * test suite(s) to communicate errors and other information to
280 * this utility via the Notify() operator.
282 *****************************************************************************/
285 AeDeviceNotifyHandler (
291 printf ("[AcpiExec] Received a Device Notify on [%4.4s] %p Value 0x%2.2X (%s)\n",
292 AcpiUtGetNodeName (Device
), Device
, Value
,
293 AcpiUtGetNotifyName (Value
));
294 if (AcpiGbl_DebugFile
)
296 AcpiOsPrintf ("[AcpiExec] Received a device notify, Value 0x%2.2X\n", Value
);
299 (void) AcpiEvaluateObject (Device
, "_NOT", NULL
, NULL
);
303 /******************************************************************************
305 * FUNCTION: AeExceptionHandler
307 * PARAMETERS: Standard exception handler parameters
311 * DESCRIPTION: System exception handler for AcpiExec utility.
313 *****************************************************************************/
317 ACPI_STATUS AmlStatus
,
323 ACPI_STATUS NewAmlStatus
= AmlStatus
;
325 ACPI_BUFFER ReturnObj
;
326 ACPI_OBJECT_LIST ArgList
;
328 const char *Exception
;
331 Exception
= AcpiFormatException (AmlStatus
);
332 AcpiOsPrintf ("[AcpiExec] Exception %s during execution ", Exception
);
335 AcpiOsPrintf ("of method [%4.4s]", (char *) &Name
);
339 AcpiOsPrintf ("at module level (table load)");
341 AcpiOsPrintf (" Opcode [%s] @%X\n", AcpiPsGetOpcodeName (Opcode
), AmlOffset
);
344 * Invoke the _ERR method if present
346 * Setup parameter object
349 ArgList
.Pointer
= Arg
;
351 Arg
[0].Type
= ACPI_TYPE_INTEGER
;
352 Arg
[0].Integer
.Value
= AmlStatus
;
354 Arg
[1].Type
= ACPI_TYPE_STRING
;
355 Arg
[1].String
.Pointer
= ACPI_CAST_PTR (char, Exception
);
356 Arg
[1].String
.Length
= ACPI_STRLEN (Exception
);
358 Arg
[2].Type
= ACPI_TYPE_INTEGER
;
359 Arg
[2].Integer
.Value
= ACPI_TO_INTEGER (AcpiOsGetThreadId());
361 /* Setup return buffer */
363 ReturnObj
.Pointer
= NULL
;
364 ReturnObj
.Length
= ACPI_ALLOCATE_BUFFER
;
366 Status
= AcpiEvaluateObject (NULL
, "\\_ERR", &ArgList
, &ReturnObj
);
367 if (ACPI_SUCCESS (Status
))
369 if (ReturnObj
.Pointer
)
371 /* Override original status */
373 NewAmlStatus
= (ACPI_STATUS
)
374 ((ACPI_OBJECT
*) ReturnObj
.Pointer
)->Integer
.Value
;
376 AcpiOsFree (ReturnObj
.Pointer
);
379 else if (Status
!= AE_NOT_FOUND
)
381 AcpiOsPrintf ("[AcpiExec] Could not execute _ERR method, %s\n",
382 AcpiFormatException (Status
));
385 /* Global override */
387 if (AcpiGbl_IgnoreErrors
)
389 NewAmlStatus
= AE_OK
;
392 if (NewAmlStatus
!= AmlStatus
)
394 AcpiOsPrintf ("[AcpiExec] Exception override, new status %s\n",
395 AcpiFormatException (NewAmlStatus
));
398 return (NewAmlStatus
);
402 /******************************************************************************
404 * FUNCTION: AeTableHandler
406 * PARAMETERS: Table handler
410 * DESCRIPTION: System table handler for AcpiExec utility.
412 *****************************************************************************/
414 char *TableEvents
[] =
428 if (Event
> ACPI_NUM_TABLE_EVENTS
)
430 Event
= ACPI_NUM_TABLE_EVENTS
;
433 /* TBD: could dump entire table header, need a header dump routine */
435 printf ("[AcpiExec] Table Event %s, [%4.4s] %p\n",
436 TableEvents
[Event
], ((ACPI_TABLE_HEADER
*) Table
)->Signature
, Table
);
441 /******************************************************************************
443 * FUNCTION: AeGpeHandler
445 * DESCRIPTION: GPE handler for acpiexec
447 *****************************************************************************/
453 AcpiOsPrintf ("Received a GPE at handler\n");
458 /******************************************************************************
460 * FUNCTION: AeAttachedDataHandler
462 * DESCRIPTION: Handler for deletion of nodes with attached data (attached via
465 *****************************************************************************/
468 AeAttachedDataHandler (
472 ACPI_NAMESPACE_NODE
*Node
= ACPI_CAST_PTR (ACPI_NAMESPACE_NODE
, Data
);
475 AcpiOsPrintf ("Received an attached data deletion on %4.4s\n",
480 /******************************************************************************
482 * FUNCTION: AeRegionInit
488 * DESCRIPTION: Opregion init function.
490 *****************************************************************************/
494 ACPI_HANDLE RegionHandle
,
496 void *HandlerContext
,
497 void **RegionContext
)
500 * Real simple, set the RegionContext to the RegionHandle
502 *RegionContext
= RegionHandle
;
508 /******************************************************************************
510 * FUNCTION: AeInstallHandlers
516 * DESCRIPTION: Install handlers for the AcpiExec utility.
518 *****************************************************************************/
520 ACPI_ADR_SPACE_TYPE SpaceId
[] = {0, 1, 2, 3, 4, 5, 6, 7, 0x80};
521 #define AEXEC_NUM_REGIONS 9
524 AeInstallHandlers (void)
531 ACPI_FUNCTION_ENTRY ();
534 Status
= AcpiInstallTableHandler (AeTableHandler
, NULL
);
535 if (ACPI_FAILURE (Status
))
537 printf ("Could not install table handler, %s\n",
538 AcpiFormatException (Status
));
541 Status
= AcpiInstallExceptionHandler (AeExceptionHandler
);
542 if (ACPI_FAILURE (Status
))
544 printf ("Could not install exception handler, %s\n",
545 AcpiFormatException (Status
));
548 /* Install global notify handler */
550 Status
= AcpiInstallNotifyHandler (ACPI_ROOT_OBJECT
, ACPI_SYSTEM_NOTIFY
,
551 AeNotifyHandler
, NULL
);
552 if (ACPI_FAILURE (Status
))
554 printf ("Could not install a global notify handler, %s\n",
555 AcpiFormatException (Status
));
558 Status
= AcpiInstallNotifyHandler (ACPI_ROOT_OBJECT
, ACPI_DEVICE_NOTIFY
,
559 AeDeviceNotifyHandler
, NULL
);
560 if (ACPI_FAILURE (Status
))
562 printf ("Could not install a global notify handler, %s\n",
563 AcpiFormatException (Status
));
566 Status
= AcpiGetHandle (NULL
, "\\_SB", &Handle
);
567 if (ACPI_SUCCESS (Status
))
569 Status
= AcpiInstallNotifyHandler (Handle
, ACPI_SYSTEM_NOTIFY
,
570 AeNotifyHandler
, NULL
);
571 if (ACPI_FAILURE (Status
))
573 printf ("Could not install a notify handler, %s\n",
574 AcpiFormatException (Status
));
577 Status
= AcpiRemoveNotifyHandler (Handle
, ACPI_SYSTEM_NOTIFY
,
579 if (ACPI_FAILURE (Status
))
581 printf ("Could not remove a notify handler, %s\n",
582 AcpiFormatException (Status
));
585 Status
= AcpiInstallNotifyHandler (Handle
, ACPI_ALL_NOTIFY
,
586 AeNotifyHandler
, NULL
);
587 Status
= AcpiRemoveNotifyHandler (Handle
, ACPI_ALL_NOTIFY
,
589 Status
= AcpiInstallNotifyHandler (Handle
, ACPI_ALL_NOTIFY
,
590 AeNotifyHandler
, NULL
);
591 if (ACPI_FAILURE (Status
))
593 printf ("Could not install a notify handler, %s\n",
594 AcpiFormatException (Status
));
597 Status
= AcpiAttachData (Handle
, AeAttachedDataHandler
, Handle
);
598 Status
= AcpiDetachData (Handle
, AeAttachedDataHandler
);
599 Status
= AcpiAttachData (Handle
, AeAttachedDataHandler
, Handle
);
603 printf ("No _SB_ found, %s\n", AcpiFormatException (Status
));
606 /* Set a handler for all supported operation regions */
608 for (i
= 0; i
< AEXEC_NUM_REGIONS
; i
++)
610 Status
= AcpiRemoveAddressSpaceHandler (AcpiGbl_RootNode
,
611 SpaceId
[i
], AeRegionHandler
);
613 /* Install handler at the root object.
614 * TBD: all default handlers should be installed here!
616 Status
= AcpiInstallAddressSpaceHandler (AcpiGbl_RootNode
,
617 SpaceId
[i
], AeRegionHandler
, AeRegionInit
, NULL
);
618 if (ACPI_FAILURE (Status
))
620 ACPI_EXCEPTION ((AE_INFO
, Status
,
621 "Could not install an OpRegion handler for %s space(%d)",
622 AcpiUtGetRegionName((UINT8
) SpaceId
[i
]), SpaceId
[i
]));
628 * Initialize the global Region Handler space
631 AeRegions
.NumberOfRegions
= 0;
632 AeRegions
.RegionList
= NULL
;
638 /******************************************************************************
640 * FUNCTION: AeRegionHandler
642 * PARAMETERS: Standard region handler parameters
646 * DESCRIPTION: Test handler - Handles some dummy regions via memory that can
647 * be manipulated in Ring 3. Simulates actual reads and writes.
649 *****************************************************************************/
654 ACPI_PHYSICAL_ADDRESS Address
,
657 void *HandlerContext
,
661 ACPI_OPERAND_OBJECT
*RegionObject
= ACPI_CAST_PTR (ACPI_OPERAND_OBJECT
, RegionContext
);
662 UINT8
*Buffer
= ACPI_CAST_PTR (UINT8
, Value
);
663 ACPI_PHYSICAL_ADDRESS BaseAddress
;
665 BOOLEAN BufferExists
;
666 AE_REGION
*RegionElement
;
674 ACPI_FUNCTION_NAME (AeRegionHandler
);
677 * If the object is not a region, simply return
679 if (RegionObject
->Region
.Type
!= ACPI_TYPE_REGION
)
685 * Region support can be disabled with the -r option.
686 * We use this to support dynamically loaded tables where we pass a valid
687 * address to the AML.
689 if (AcpiGbl_DbOpt_NoRegionSupport
)
691 BufferValue
= ACPI_TO_POINTER (Address
);
692 ByteWidth
= (BitWidth
/ 8);
702 * Find the region's address space and length before searching
705 BaseAddress
= RegionObject
->Region
.Address
;
706 Length
= (ACPI_SIZE
) RegionObject
->Region
.Length
;
707 SpaceId
= RegionObject
->Region
.SpaceId
;
709 ACPI_DEBUG_PRINT ((ACPI_DB_OPREGION
, "Operation Region request on %s at 0x%X\n",
710 AcpiUtGetRegionName (RegionObject
->Region
.SpaceId
),
715 case ACPI_ADR_SPACE_SYSTEM_IO
:
717 * For I/O space, exercise the port validation
719 switch (Function
& ACPI_IO_MASK
)
722 Status
= AcpiHwReadPort (Address
, (UINT32
*) Value
, BitWidth
);
726 Status
= AcpiHwWritePort (Address
, (UINT32
) *Value
, BitWidth
);
730 Status
= AE_BAD_PARAMETER
;
734 if (ACPI_FAILURE (Status
))
739 /* Now go ahead and simulate the hardware */
743 case ACPI_ADR_SPACE_SMBUS
:
747 switch (Function
& ACPI_IO_MASK
)
750 switch (Function
>> 16)
752 case AML_FIELD_ATTRIB_SMB_QUICK
:
753 case AML_FIELD_ATTRIB_SMB_SEND_RCV
:
754 case AML_FIELD_ATTRIB_SMB_BYTE
:
758 case AML_FIELD_ATTRIB_SMB_WORD
:
759 case AML_FIELD_ATTRIB_SMB_WORD_CALL
:
763 case AML_FIELD_ATTRIB_SMB_BLOCK
:
764 case AML_FIELD_ATTRIB_SMB_BLOCK_CALL
:
774 switch (Function
>> 16)
776 case AML_FIELD_ATTRIB_SMB_QUICK
:
777 case AML_FIELD_ATTRIB_SMB_SEND_RCV
:
778 case AML_FIELD_ATTRIB_SMB_BYTE
:
779 case AML_FIELD_ATTRIB_SMB_WORD
:
780 case AML_FIELD_ATTRIB_SMB_BLOCK
:
784 case AML_FIELD_ATTRIB_SMB_WORD_CALL
:
788 case AML_FIELD_ATTRIB_SMB_BLOCK_CALL
:
801 for (i
= 0; i
< Length
; i
++)
803 Buffer
[i
+2] = (UINT8
) (0xA0 + i
);
807 Buffer
[1] = (UINT8
) Length
;
811 case ACPI_ADR_SPACE_IPMI
: /* ACPI 4.0 */
813 AcpiOsPrintf ("AcpiExec: Received IPMI request: "
814 "Address %X BaseAddress %X Length %X Width %X BufferLength %u\n",
815 (UINT32
) Address
, (UINT32
) BaseAddress
,
816 Length
, BitWidth
, Buffer
[1]);
819 * Regardless of a READ or WRITE, this handler is passed a 66-byte
820 * buffer in which to return the IPMI status/length/data.
822 * Return some example data to show use of the bidirectional buffer
824 Buffer
[0] = 0; /* Status byte */
825 Buffer
[1] = 64; /* Return buffer data length */
826 Buffer
[2] = 0; /* Completion code */
827 Buffer
[3] = 0x34; /* Power measurement */
828 Buffer
[4] = 0x12; /* Power measurement */
829 Buffer
[65] = 0xEE; /* last buffer byte */
837 * Search through the linked list for this region's buffer
839 BufferExists
= FALSE
;
840 RegionElement
= AeRegions
.RegionList
;
842 if (AeRegions
.NumberOfRegions
)
844 while (!BufferExists
&& RegionElement
)
846 if (RegionElement
->Address
== BaseAddress
&&
847 RegionElement
->Length
== Length
&&
848 RegionElement
->SpaceId
== SpaceId
)
854 RegionElement
= RegionElement
->NextRegion
;
860 * If the Region buffer does not exist, create it now
865 * Do the memory allocations first
867 RegionElement
= AcpiOsAllocate (sizeof (AE_REGION
));
873 RegionElement
->Buffer
= AcpiOsAllocate (Length
);
874 if (!RegionElement
->Buffer
)
876 AcpiOsFree (RegionElement
);
880 ACPI_MEMSET (RegionElement
->Buffer
, 0, Length
);
881 RegionElement
->Address
= BaseAddress
;
882 RegionElement
->Length
= Length
;
883 RegionElement
->SpaceId
= SpaceId
;
884 RegionElement
->NextRegion
= NULL
;
887 * Increment the number of regions and put this one
888 * at the head of the list as it will probably get accessed
891 AeRegions
.NumberOfRegions
+= 1;
893 if (AeRegions
.RegionList
)
895 RegionElement
->NextRegion
= AeRegions
.RegionList
;
898 AeRegions
.RegionList
= RegionElement
;
902 * Calculate the size of the memory copy
904 ByteWidth
= (BitWidth
/ 8);
912 * The buffer exists and is pointed to by RegionElement.
913 * We now need to verify the request is valid and perform the operation.
915 * NOTE: RegionElement->Length is in bytes, therefore it we compare against
916 * ByteWidth (see above)
918 if (((ACPI_INTEGER
) Address
+ ByteWidth
) >
919 ((ACPI_INTEGER
)(RegionElement
->Address
) + RegionElement
->Length
))
921 ACPI_WARNING ((AE_INFO
,
922 "Request on [%4.4s] is beyond region limit Req-%X+%X, Base=%X, Len-%X",
923 (RegionObject
->Region
.Node
)->Name
.Ascii
, (UINT32
) Address
,
924 ByteWidth
, (UINT32
)(RegionElement
->Address
),
925 RegionElement
->Length
));
927 return AE_AML_REGION_LIMIT
;
931 * Get BufferValue to point to the "address" in the buffer
933 BufferValue
= ((UINT8
*) RegionElement
->Buffer
+
934 ((ACPI_INTEGER
) Address
- (ACPI_INTEGER
) RegionElement
->Address
));
939 * Perform a read or write to the buffer space
945 * Set the pointer Value to whatever is in the buffer
947 ACPI_MEMCPY (Value
, BufferValue
, ByteWidth
);
952 * Write the contents of Value to the buffer
954 ACPI_MEMCPY (BufferValue
, Value
, ByteWidth
);
958 return AE_BAD_PARAMETER
;