Sync ACPICA with Intel's version 20190405.
[dragonfly.git] / sys / contrib / dev / acpica / source / include / acpixf.h
1 /******************************************************************************
2  *
3  * Name: acpixf.h - External interfaces to the ACPI subsystem
4  *
5  *****************************************************************************/
6
7 /******************************************************************************
8  *
9  * 1. Copyright Notice
10  *
11  * Some or all of this work - Copyright (c) 1999 - 2019, Intel Corp.
12  * All rights reserved.
13  *
14  * 2. License
15  *
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
19  * property rights.
20  *
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
27  *
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;
36  *
37  * The above copyright and patent license is granted only if the following
38  * conditions are met:
39  *
40  * 3. Conditions
41  *
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.
53  *
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
64  * make.
65  *
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
70  * distribution.
71  *
72  * 3.4. Intel retains all right, title, and interest in and to the Original
73  * Intel Code.
74  *
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.
79  *
80  * 4. Disclaimer and Export Compliance
81  *
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
88  * PARTICULAR PURPOSE.
89  *
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
97  * LIMITED REMEDY.
98  *
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.
113  *
114  *****************************************************************************
115  *
116  * Alternatively, you may choose to be licensed under the terms of the
117  * following license:
118  *
119  * Redistribution and use in source and binary forms, with or without
120  * modification, are permitted provided that the following conditions
121  * are met:
122  * 1. Redistributions of source code must retain the above copyright
123  *    notice, this list of conditions, and the following disclaimer,
124  *    without modification.
125  * 2. Redistributions in binary form must reproduce at minimum a disclaimer
126  *    substantially similar to the "NO WARRANTY" disclaimer below
127  *    ("Disclaimer") and any redistribution must be conditioned upon
128  *    including a substantially similar Disclaimer requirement for further
129  *    binary redistribution.
130  * 3. Neither the names of the above-listed copyright holders nor the names
131  *    of any contributors may be used to endorse or promote products derived
132  *    from this software without specific prior written permission.
133  *
134  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
135  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
136  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
137  * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
138  * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
139  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
140  * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
141  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
142  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
143  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
144  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
145  *
146  * Alternatively, you may choose to be licensed under the terms of the
147  * GNU General Public License ("GPL") version 2 as published by the Free
148  * Software Foundation.
149  *
150  *****************************************************************************/
151
152 #ifndef __ACXFACE_H__
153 #define __ACXFACE_H__
154
155 /* Current ACPICA subsystem version in YYYYMMDD format */
156
157 #define ACPI_CA_VERSION                 0x20190405
158
159 #include "acconfig.h"
160 #include "actypes.h"
161 #include "actbl.h"
162 #include "acbuffer.h"
163
164
165 /*****************************************************************************
166  *
167  * Macros used for ACPICA globals and configuration
168  *
169  ****************************************************************************/
170
171 /*
172  * Ensure that global variables are defined and initialized only once.
173  *
174  * The use of these macros allows for a single list of globals (here)
175  * in order to simplify maintenance of the code.
176  */
177 #ifdef DEFINE_ACPI_GLOBALS
178 #define ACPI_GLOBAL(type,name) \
179     extern type name; \
180     type name
181
182 #define ACPI_INIT_GLOBAL(type,name,value) \
183     type name=value
184
185 #else
186 #ifndef ACPI_GLOBAL
187 #define ACPI_GLOBAL(type,name) \
188     extern type name
189 #endif
190
191 #ifndef ACPI_INIT_GLOBAL
192 #define ACPI_INIT_GLOBAL(type,name,value) \
193     extern type name
194 #endif
195 #endif
196
197 /*
198  * These macros configure the various ACPICA interfaces. They are
199  * useful for generating stub inline functions for features that are
200  * configured out of the current kernel or ACPICA application.
201  */
202 #ifndef ACPI_EXTERNAL_RETURN_STATUS
203 #define ACPI_EXTERNAL_RETURN_STATUS(Prototype) \
204     Prototype;
205 #endif
206
207 #ifndef ACPI_EXTERNAL_RETURN_OK
208 #define ACPI_EXTERNAL_RETURN_OK(Prototype) \
209     Prototype;
210 #endif
211
212 #ifndef ACPI_EXTERNAL_RETURN_VOID
213 #define ACPI_EXTERNAL_RETURN_VOID(Prototype) \
214     Prototype;
215 #endif
216
217 #ifndef ACPI_EXTERNAL_RETURN_UINT32
218 #define ACPI_EXTERNAL_RETURN_UINT32(Prototype) \
219     Prototype;
220 #endif
221
222 #ifndef ACPI_EXTERNAL_RETURN_PTR
223 #define ACPI_EXTERNAL_RETURN_PTR(Prototype) \
224     Prototype;
225 #endif
226
227
228 /*****************************************************************************
229  *
230  * Public globals and runtime configuration options
231  *
232  ****************************************************************************/
233
234 /*
235  * Enable "slack mode" of the AML interpreter?  Default is FALSE, and the
236  * interpreter strictly follows the ACPI specification. Setting to TRUE
237  * allows the interpreter to ignore certain errors and/or bad AML constructs.
238  *
239  * Currently, these features are enabled by this flag:
240  *
241  * 1) Allow "implicit return" of last value in a control method
242  * 2) Allow access beyond the end of an operation region
243  * 3) Allow access to uninitialized locals/args (auto-init to integer 0)
244  * 4) Allow ANY object type to be a source operand for the Store() operator
245  * 5) Allow unresolved references (invalid target name) in package objects
246  * 6) Enable warning messages for behavior that is not ACPI spec compliant
247  */
248 ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_EnableInterpreterSlack, FALSE);
249
250 /*
251  * Automatically serialize all methods that create named objects? Default
252  * is TRUE, meaning that all NonSerialized methods are scanned once at
253  * table load time to determine those that create named objects. Methods
254  * that create named objects are marked Serialized in order to prevent
255  * possible run-time problems if they are entered by more than one thread.
256  */
257 ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_AutoSerializeMethods, TRUE);
258
259 /*
260  * Create the predefined _OSI method in the namespace? Default is TRUE
261  * because ACPICA is fully compatible with other ACPI implementations.
262  * Changing this will revert ACPICA (and machine ASL) to pre-OSI behavior.
263  */
264 ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_CreateOsiMethod, TRUE);
265
266 /*
267  * Optionally use default values for the ACPI register widths. Set this to
268  * TRUE to use the defaults, if an FADT contains incorrect widths/lengths.
269  */
270 ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_UseDefaultRegisterWidths, TRUE);
271
272 /*
273  * Whether or not to validate (map) an entire table to verify
274  * checksum/duplication in early stage before install. Set this to TRUE to
275  * allow early table validation before install it to the table manager.
276  * Note that enabling this option causes errors to happen in some OSPMs
277  * during early initialization stages. Default behavior is to allow such
278  * validation.
279  */
280 ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_EnableTableValidation, TRUE);
281
282 /*
283  * Optionally enable output from the AML Debug Object.
284  */
285 ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_EnableAmlDebugObject, FALSE);
286
287 /*
288  * Optionally copy the entire DSDT to local memory (instead of simply
289  * mapping it.) There are some BIOSs that corrupt or replace the original
290  * DSDT, creating the need for this option. Default is FALSE, do not copy
291  * the DSDT.
292  */
293 ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_CopyDsdtLocally, FALSE);
294
295 /*
296  * Optionally ignore an XSDT if present and use the RSDT instead.
297  * Although the ACPI specification requires that an XSDT be used instead
298  * of the RSDT, the XSDT has been found to be corrupt or ill-formed on
299  * some machines. Default behavior is to use the XSDT if present.
300  */
301 ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_DoNotUseXsdt, FALSE);
302
303 /*
304  * Optionally use 32-bit FADT addresses if and when there is a conflict
305  * (address mismatch) between the 32-bit and 64-bit versions of the
306  * address. Although ACPICA adheres to the ACPI specification which
307  * requires the use of the corresponding 64-bit address if it is non-zero,
308  * some machines have been found to have a corrupted non-zero 64-bit
309  * address. Default is FALSE, do not favor the 32-bit addresses.
310  */
311 ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_Use32BitFadtAddresses, FALSE);
312
313 /*
314  * Optionally use 32-bit FACS table addresses.
315  * It is reported that some platforms fail to resume from system suspending
316  * if 64-bit FACS table address is selected:
317  * https://bugzilla.kernel.org/show_bug.cgi?id=74021
318  * Default is TRUE, favor the 32-bit addresses.
319  */
320 ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_Use32BitFacsAddresses, TRUE);
321
322 /*
323  * Optionally truncate I/O addresses to 16 bits. Provides compatibility
324  * with other ACPI implementations. NOTE: During ACPICA initialization,
325  * this value is set to TRUE if any Windows OSI strings have been
326  * requested by the BIOS.
327  */
328 ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_TruncateIoAddresses, FALSE);
329
330 /*
331  * Disable runtime checking and repair of values returned by control methods.
332  * Use only if the repair is causing a problem on a particular machine.
333  */
334 ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_DisableAutoRepair, FALSE);
335
336 /*
337  * Optionally do not install any SSDTs from the RSDT/XSDT during initialization.
338  * This can be useful for debugging ACPI problems on some machines.
339  */
340 ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_DisableSsdtTableInstall, FALSE);
341
342 /*
343  * Optionally enable runtime namespace override.
344  */
345 ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_RuntimeNamespaceOverride, TRUE);
346
347 /*
348  * We keep track of the latest version of Windows that has been requested by
349  * the BIOS. ACPI 5.0.
350  */
351 ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_OsiData, 0);
352
353 /*
354  * ACPI 5.0 introduces the concept of a "reduced hardware platform", meaning
355  * that the ACPI hardware is no longer required. A flag in the FADT indicates
356  * a reduced HW machine, and that flag is duplicated here for convenience.
357  */
358 ACPI_INIT_GLOBAL (BOOLEAN,          AcpiGbl_ReducedHardware, FALSE);
359
360 /*
361  * Maximum timeout for While() loop iterations before forced method abort.
362  * This mechanism is intended to prevent infinite loops during interpreter
363  * execution within a host kernel.
364  */
365 ACPI_INIT_GLOBAL (UINT32,           AcpiGbl_MaxLoopIterations, ACPI_MAX_LOOP_TIMEOUT);
366
367 /*
368  * Optionally ignore AE_NOT_FOUND errors from named reference package elements
369  * during DSDT/SSDT table loading. This reduces error "noise" in platforms
370  * whose firmware is carrying around a bunch of unused package objects that
371  * refer to non-existent named objects. However, If the AML actually tries to
372  * use such a package, the unresolved element(s) will be replaced with NULL
373  * elements.
374  */
375 ACPI_INIT_GLOBAL (BOOLEAN,          AcpiGbl_IgnorePackageResolutionErrors, FALSE);
376
377 /*
378  * This mechanism is used to trace a specified AML method. The method is
379  * traced each time it is executed.
380  */
381 ACPI_INIT_GLOBAL (UINT32,           AcpiGbl_TraceFlags, 0);
382 ACPI_INIT_GLOBAL (const char *,     AcpiGbl_TraceMethodName, NULL);
383 ACPI_INIT_GLOBAL (UINT32,           AcpiGbl_TraceDbgLevel, ACPI_TRACE_LEVEL_DEFAULT);
384 ACPI_INIT_GLOBAL (UINT32,           AcpiGbl_TraceDbgLayer, ACPI_TRACE_LAYER_DEFAULT);
385
386 /*
387  * Runtime configuration of debug output control masks. We want the debug
388  * switches statically initialized so they are already set when the debugger
389  * is entered.
390  */
391 #ifdef ACPI_DEBUG_OUTPUT
392 ACPI_INIT_GLOBAL (UINT32,           AcpiDbgLevel, ACPI_DEBUG_DEFAULT);
393 #else
394 ACPI_INIT_GLOBAL (UINT32,           AcpiDbgLevel, ACPI_NORMAL_DEFAULT);
395 #endif
396 ACPI_INIT_GLOBAL (UINT32,           AcpiDbgLayer, ACPI_COMPONENT_DEFAULT);
397
398 /* Optionally enable timer output with Debug Object output */
399
400 ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_DisplayDebugTimer, FALSE);
401
402 /*
403  * Debugger command handshake globals. Host OSes need to access these
404  * variables to implement their own command handshake mechanism.
405  */
406 #ifdef ACPI_DEBUGGER
407 ACPI_INIT_GLOBAL (BOOLEAN,          AcpiGbl_MethodExecuting, FALSE);
408 ACPI_GLOBAL (char,                  AcpiGbl_DbLineBuf[ACPI_DB_LINE_BUFFER_SIZE]);
409 #endif
410
411 /*
412  * Other miscellaneous globals
413  */
414 ACPI_GLOBAL (ACPI_TABLE_FADT,       AcpiGbl_FADT);
415 ACPI_GLOBAL (UINT32,                AcpiCurrentGpeCount);
416 ACPI_GLOBAL (BOOLEAN,               AcpiGbl_SystemAwakeAndRunning);
417
418
419 /*****************************************************************************
420  *
421  * ACPICA public interface configuration.
422  *
423  * Interfaces that are configured out of the ACPICA build are replaced
424  * by inlined stubs by default.
425  *
426  ****************************************************************************/
427
428 /*
429  * Hardware-reduced prototypes (default: Not hardware reduced).
430  *
431  * All ACPICA hardware-related interfaces that use these macros will be
432  * configured out of the ACPICA build if the ACPI_REDUCED_HARDWARE flag
433  * is set to TRUE.
434  *
435  * Note: This static build option for reduced hardware is intended to
436  * reduce ACPICA code size if desired or necessary. However, even if this
437  * option is not specified, the runtime behavior of ACPICA is dependent
438  * on the actual FADT reduced hardware flag (HW_REDUCED_ACPI). If set,
439  * the flag will enable similar behavior -- ACPICA will not attempt
440  * to access any ACPI-relate hardware (SCI, GPEs, Fixed Events, etc.)
441  */
442 #if (!ACPI_REDUCED_HARDWARE)
443 #define ACPI_HW_DEPENDENT_RETURN_STATUS(Prototype) \
444     ACPI_EXTERNAL_RETURN_STATUS(Prototype)
445
446 #define ACPI_HW_DEPENDENT_RETURN_OK(Prototype) \
447     ACPI_EXTERNAL_RETURN_OK(Prototype)
448
449 #define ACPI_HW_DEPENDENT_RETURN_VOID(Prototype) \
450     ACPI_EXTERNAL_RETURN_VOID(Prototype)
451
452 #else
453 #define ACPI_HW_DEPENDENT_RETURN_STATUS(Prototype) \
454     static ACPI_INLINE Prototype {return(AE_NOT_CONFIGURED);}
455
456 #define ACPI_HW_DEPENDENT_RETURN_OK(Prototype) \
457     static ACPI_INLINE Prototype {return(AE_OK);}
458
459 #define ACPI_HW_DEPENDENT_RETURN_VOID(Prototype) \
460     static ACPI_INLINE Prototype {return;}
461
462 #endif /* !ACPI_REDUCED_HARDWARE */
463
464
465 /*
466  * Error message prototypes (default: error messages enabled).
467  *
468  * All interfaces related to error and warning messages
469  * will be configured out of the ACPICA build if the
470  * ACPI_NO_ERROR_MESSAGE flag is defined.
471  */
472 #ifndef ACPI_NO_ERROR_MESSAGES
473 #define ACPI_MSG_DEPENDENT_RETURN_VOID(Prototype) \
474     Prototype;
475
476 #else
477 #define ACPI_MSG_DEPENDENT_RETURN_VOID(Prototype) \
478     static ACPI_INLINE Prototype {return;}
479
480 #endif /* ACPI_NO_ERROR_MESSAGES */
481
482
483 /*
484  * Debugging output prototypes (default: no debug output).
485  *
486  * All interfaces related to debug output messages
487  * will be configured out of the ACPICA build unless the
488  * ACPI_DEBUG_OUTPUT flag is defined.
489  */
490 #ifdef ACPI_DEBUG_OUTPUT
491 #define ACPI_DBG_DEPENDENT_RETURN_VOID(Prototype) \
492     Prototype;
493
494 #else
495 #define ACPI_DBG_DEPENDENT_RETURN_VOID(Prototype) \
496     static ACPI_INLINE Prototype {return;}
497
498 #endif /* ACPI_DEBUG_OUTPUT */
499
500
501 /*
502  * Application prototypes
503  *
504  * All interfaces used by application will be configured
505  * out of the ACPICA build unless the ACPI_APPLICATION
506  * flag is defined.
507  */
508 #ifdef ACPI_APPLICATION
509 #define ACPI_APP_DEPENDENT_RETURN_VOID(Prototype) \
510     Prototype;
511
512 #else
513 #define ACPI_APP_DEPENDENT_RETURN_VOID(Prototype) \
514     static ACPI_INLINE Prototype {return;}
515
516 #endif /* ACPI_APPLICATION */
517
518
519 /*
520  * Debugger prototypes
521  *
522  * All interfaces used by debugger will be configured
523  * out of the ACPICA build unless the ACPI_DEBUGGER
524  * flag is defined.
525  */
526 #ifdef ACPI_DEBUGGER
527 #define ACPI_DBR_DEPENDENT_RETURN_OK(Prototype) \
528     ACPI_EXTERNAL_RETURN_OK(Prototype)
529
530 #define ACPI_DBR_DEPENDENT_RETURN_VOID(Prototype) \
531     ACPI_EXTERNAL_RETURN_VOID(Prototype)
532
533 #else
534 #define ACPI_DBR_DEPENDENT_RETURN_OK(Prototype) \
535     static ACPI_INLINE Prototype {return(AE_OK);}
536
537 #define ACPI_DBR_DEPENDENT_RETURN_VOID(Prototype) \
538     static ACPI_INLINE Prototype {return;}
539
540 #endif /* ACPI_DEBUGGER */
541
542
543 /*****************************************************************************
544  *
545  * ACPICA public interface prototypes
546  *
547  ****************************************************************************/
548
549 /*
550  * Initialization
551  */
552 ACPI_EXTERNAL_RETURN_STATUS (
553 ACPI_STATUS ACPI_INIT_FUNCTION
554 AcpiInitializeTables (
555     ACPI_TABLE_DESC         *InitialStorage,
556     UINT32                  InitialTableCount,
557     BOOLEAN                 AllowResize))
558
559 ACPI_EXTERNAL_RETURN_STATUS (
560 ACPI_STATUS ACPI_INIT_FUNCTION
561 AcpiInitializeSubsystem (
562     void))
563
564 ACPI_EXTERNAL_RETURN_STATUS (
565 ACPI_STATUS ACPI_INIT_FUNCTION
566 AcpiEnableSubsystem (
567     UINT32                  Flags))
568
569 ACPI_EXTERNAL_RETURN_STATUS (
570 ACPI_STATUS ACPI_INIT_FUNCTION
571 AcpiInitializeObjects (
572     UINT32                  Flags))
573
574 ACPI_EXTERNAL_RETURN_STATUS (
575 ACPI_STATUS ACPI_INIT_FUNCTION
576 AcpiTerminate (
577     void))
578
579
580 /*
581  * Miscellaneous global interfaces
582  */
583 ACPI_HW_DEPENDENT_RETURN_STATUS (
584 ACPI_STATUS
585 AcpiEnable (
586     void))
587
588 ACPI_HW_DEPENDENT_RETURN_STATUS (
589 ACPI_STATUS
590 AcpiDisable (
591     void))
592
593 ACPI_EXTERNAL_RETURN_STATUS (
594 ACPI_STATUS
595 AcpiSubsystemStatus (
596     void))
597
598 ACPI_EXTERNAL_RETURN_STATUS (
599 ACPI_STATUS
600 AcpiGetSystemInfo (
601     ACPI_BUFFER             *RetBuffer))
602
603 ACPI_EXTERNAL_RETURN_STATUS (
604 ACPI_STATUS
605 AcpiGetStatistics (
606     ACPI_STATISTICS         *Stats))
607
608 ACPI_EXTERNAL_RETURN_PTR (
609 const char *
610 AcpiFormatException (
611     ACPI_STATUS             Exception))
612
613 ACPI_EXTERNAL_RETURN_STATUS (
614 ACPI_STATUS
615 AcpiPurgeCachedObjects (
616     void))
617
618 ACPI_EXTERNAL_RETURN_STATUS (
619 ACPI_STATUS
620 AcpiInstallInterface (
621     ACPI_STRING             InterfaceName))
622
623 ACPI_EXTERNAL_RETURN_STATUS (
624 ACPI_STATUS
625 AcpiRemoveInterface (
626     ACPI_STRING             InterfaceName))
627
628 ACPI_EXTERNAL_RETURN_STATUS (
629 ACPI_STATUS
630 AcpiUpdateInterfaces (
631     UINT8                   Action))
632
633 ACPI_EXTERNAL_RETURN_UINT32 (
634 UINT32
635 AcpiCheckAddressRange (
636     ACPI_ADR_SPACE_TYPE     SpaceId,
637     ACPI_PHYSICAL_ADDRESS   Address,
638     ACPI_SIZE               Length,
639     BOOLEAN                 Warn))
640
641 ACPI_EXTERNAL_RETURN_STATUS (
642 ACPI_STATUS
643 AcpiDecodePldBuffer (
644     UINT8                   *InBuffer,
645     ACPI_SIZE               Length,
646     ACPI_PLD_INFO           **ReturnBuffer))
647
648
649 /*
650  * ACPI table load/unload interfaces
651  */
652 ACPI_EXTERNAL_RETURN_STATUS (
653 ACPI_STATUS ACPI_INIT_FUNCTION
654 AcpiInstallTable (
655     ACPI_PHYSICAL_ADDRESS   Address,
656     BOOLEAN                 Physical))
657
658 ACPI_EXTERNAL_RETURN_STATUS (
659 ACPI_STATUS
660 AcpiLoadTable (
661     ACPI_TABLE_HEADER       *Table))
662
663 ACPI_EXTERNAL_RETURN_STATUS (
664 ACPI_STATUS
665 AcpiUnloadParentTable (
666     ACPI_HANDLE             Object))
667
668 ACPI_EXTERNAL_RETURN_STATUS (
669 ACPI_STATUS ACPI_INIT_FUNCTION
670 AcpiLoadTables (
671     void))
672
673
674 /*
675  * ACPI table manipulation interfaces
676  */
677 ACPI_EXTERNAL_RETURN_STATUS (
678 ACPI_STATUS ACPI_INIT_FUNCTION
679 AcpiReallocateRootTable (
680     void))
681
682 ACPI_EXTERNAL_RETURN_STATUS (
683 ACPI_STATUS ACPI_INIT_FUNCTION
684 AcpiFindRootPointer (
685     ACPI_PHYSICAL_ADDRESS   *RsdpAddress))
686
687 ACPI_EXTERNAL_RETURN_STATUS (
688 ACPI_STATUS
689 AcpiGetTableHeader (
690     ACPI_STRING             Signature,
691     UINT32                  Instance,
692     ACPI_TABLE_HEADER       *OutTableHeader))
693
694 ACPI_EXTERNAL_RETURN_STATUS (
695 ACPI_STATUS
696 AcpiGetTable (
697     ACPI_STRING             Signature,
698     UINT32                  Instance,
699     ACPI_TABLE_HEADER       **OutTable))
700
701 ACPI_EXTERNAL_RETURN_VOID (
702 void
703 AcpiPutTable (
704     ACPI_TABLE_HEADER       *Table))
705
706 ACPI_EXTERNAL_RETURN_STATUS (
707 ACPI_STATUS
708 AcpiGetTableByIndex (
709     UINT32                  TableIndex,
710     ACPI_TABLE_HEADER       **OutTable))
711
712 ACPI_EXTERNAL_RETURN_STATUS (
713 ACPI_STATUS
714 AcpiInstallTableHandler (
715     ACPI_TABLE_HANDLER      Handler,
716     void                    *Context))
717
718 ACPI_EXTERNAL_RETURN_STATUS (
719 ACPI_STATUS
720 AcpiRemoveTableHandler (
721     ACPI_TABLE_HANDLER      Handler))
722
723
724 /*
725  * Namespace and name interfaces
726  */
727 ACPI_EXTERNAL_RETURN_STATUS (
728 ACPI_STATUS
729 AcpiWalkNamespace (
730     ACPI_OBJECT_TYPE        Type,
731     ACPI_HANDLE             StartObject,
732     UINT32                  MaxDepth,
733     ACPI_WALK_CALLBACK      DescendingCallback,
734     ACPI_WALK_CALLBACK      AscendingCallback,
735     void                    *Context,
736     void                    **ReturnValue))
737
738 ACPI_EXTERNAL_RETURN_STATUS (
739 ACPI_STATUS
740 AcpiGetDevices (
741     char                    *HID,
742     ACPI_WALK_CALLBACK      UserFunction,
743     void                    *Context,
744     void                    **ReturnValue))
745
746 ACPI_EXTERNAL_RETURN_STATUS (
747 ACPI_STATUS
748 AcpiGetName (
749     ACPI_HANDLE             Object,
750     UINT32                  NameType,
751     ACPI_BUFFER             *RetPathPtr))
752
753 ACPI_EXTERNAL_RETURN_STATUS (
754 ACPI_STATUS
755 AcpiGetHandle (
756     ACPI_HANDLE             Parent,
757     ACPI_STRING             Pathname,
758     ACPI_HANDLE             *RetHandle))
759
760 ACPI_EXTERNAL_RETURN_STATUS (
761 ACPI_STATUS
762 AcpiAttachData (
763     ACPI_HANDLE             Object,
764     ACPI_OBJECT_HANDLER     Handler,
765     void                    *Data))
766
767 ACPI_EXTERNAL_RETURN_STATUS (
768 ACPI_STATUS
769 AcpiDetachData (
770     ACPI_HANDLE             Object,
771     ACPI_OBJECT_HANDLER     Handler))
772
773 ACPI_EXTERNAL_RETURN_STATUS (
774 ACPI_STATUS
775 AcpiGetData (
776     ACPI_HANDLE             Object,
777     ACPI_OBJECT_HANDLER     Handler,
778     void                    **Data))
779
780 ACPI_EXTERNAL_RETURN_STATUS (
781 ACPI_STATUS
782 AcpiDebugTrace (
783     const char              *Name,
784     UINT32                  DebugLevel,
785     UINT32                  DebugLayer,
786     UINT32                  Flags))
787
788
789 /*
790  * Object manipulation and enumeration
791  */
792 ACPI_EXTERNAL_RETURN_STATUS (
793 ACPI_STATUS
794 AcpiEvaluateObject (
795     ACPI_HANDLE             Object,
796     ACPI_STRING             Pathname,
797     ACPI_OBJECT_LIST        *ParameterObjects,
798     ACPI_BUFFER             *ReturnObjectBuffer))
799
800 ACPI_EXTERNAL_RETURN_STATUS (
801 ACPI_STATUS
802 AcpiEvaluateObjectTyped (
803     ACPI_HANDLE             Object,
804     ACPI_STRING             Pathname,
805     ACPI_OBJECT_LIST        *ExternalParams,
806     ACPI_BUFFER             *ReturnBuffer,
807     ACPI_OBJECT_TYPE        ReturnType))
808
809 ACPI_EXTERNAL_RETURN_STATUS (
810 ACPI_STATUS
811 AcpiGetObjectInfo (
812     ACPI_HANDLE             Object,
813     ACPI_DEVICE_INFO        **ReturnBuffer))
814
815 ACPI_EXTERNAL_RETURN_STATUS (
816 ACPI_STATUS
817 AcpiInstallMethod (
818     UINT8                   *Buffer))
819
820 ACPI_EXTERNAL_RETURN_STATUS (
821 ACPI_STATUS
822 AcpiGetNextObject (
823     ACPI_OBJECT_TYPE        Type,
824     ACPI_HANDLE             Parent,
825     ACPI_HANDLE             Child,
826     ACPI_HANDLE             *OutHandle))
827
828 ACPI_EXTERNAL_RETURN_STATUS (
829 ACPI_STATUS
830 AcpiGetType (
831     ACPI_HANDLE             Object,
832     ACPI_OBJECT_TYPE        *OutType))
833
834 ACPI_EXTERNAL_RETURN_STATUS (
835 ACPI_STATUS
836 AcpiGetParent (
837     ACPI_HANDLE             Object,
838     ACPI_HANDLE             *OutHandle))
839
840
841 /*
842  * Handler interfaces
843  */
844 ACPI_EXTERNAL_RETURN_STATUS (
845 ACPI_STATUS
846 AcpiInstallInitializationHandler (
847     ACPI_INIT_HANDLER       Handler,
848     UINT32                  Function))
849
850 ACPI_HW_DEPENDENT_RETURN_STATUS (
851 ACPI_STATUS
852 AcpiInstallSciHandler (
853     ACPI_SCI_HANDLER        Address,
854     void                    *Context))
855
856 ACPI_HW_DEPENDENT_RETURN_STATUS (
857 ACPI_STATUS
858 AcpiRemoveSciHandler (
859     ACPI_SCI_HANDLER        Address))
860
861 ACPI_HW_DEPENDENT_RETURN_STATUS (
862 ACPI_STATUS
863 AcpiInstallGlobalEventHandler (
864     ACPI_GBL_EVENT_HANDLER  Handler,
865     void                    *Context))
866
867 ACPI_HW_DEPENDENT_RETURN_STATUS (
868 ACPI_STATUS
869 AcpiInstallFixedEventHandler (
870     UINT32                  AcpiEvent,
871     ACPI_EVENT_HANDLER      Handler,
872     void                    *Context))
873
874 ACPI_HW_DEPENDENT_RETURN_STATUS (
875 ACPI_STATUS
876 AcpiRemoveFixedEventHandler (
877     UINT32                  AcpiEvent,
878     ACPI_EVENT_HANDLER      Handler))
879
880 ACPI_HW_DEPENDENT_RETURN_STATUS (
881 ACPI_STATUS
882 AcpiInstallGpeHandler (
883     ACPI_HANDLE             GpeDevice,
884     UINT32                  GpeNumber,
885     UINT32                  Type,
886     ACPI_GPE_HANDLER        Address,
887     void                    *Context))
888
889 ACPI_HW_DEPENDENT_RETURN_STATUS (
890 ACPI_STATUS
891 AcpiInstallGpeRawHandler (
892     ACPI_HANDLE             GpeDevice,
893     UINT32                  GpeNumber,
894     UINT32                  Type,
895     ACPI_GPE_HANDLER        Address,
896     void                    *Context))
897
898 ACPI_HW_DEPENDENT_RETURN_STATUS (
899 ACPI_STATUS
900 AcpiRemoveGpeHandler (
901     ACPI_HANDLE             GpeDevice,
902     UINT32                  GpeNumber,
903     ACPI_GPE_HANDLER        Address))
904
905 ACPI_EXTERNAL_RETURN_STATUS (
906 ACPI_STATUS
907 AcpiInstallNotifyHandler (
908     ACPI_HANDLE             Device,
909     UINT32                  HandlerType,
910     ACPI_NOTIFY_HANDLER     Handler,
911     void                    *Context))
912
913 ACPI_EXTERNAL_RETURN_STATUS (
914 ACPI_STATUS
915 AcpiRemoveNotifyHandler (
916     ACPI_HANDLE             Device,
917     UINT32                  HandlerType,
918     ACPI_NOTIFY_HANDLER     Handler))
919
920 ACPI_EXTERNAL_RETURN_STATUS (
921 ACPI_STATUS
922 AcpiInstallAddressSpaceHandler (
923     ACPI_HANDLE             Device,
924     ACPI_ADR_SPACE_TYPE     SpaceId,
925     ACPI_ADR_SPACE_HANDLER  Handler,
926     ACPI_ADR_SPACE_SETUP    Setup,
927     void                    *Context))
928
929 ACPI_EXTERNAL_RETURN_STATUS (
930 ACPI_STATUS
931 AcpiRemoveAddressSpaceHandler (
932     ACPI_HANDLE             Device,
933     ACPI_ADR_SPACE_TYPE     SpaceId,
934     ACPI_ADR_SPACE_HANDLER  Handler))
935
936 ACPI_EXTERNAL_RETURN_STATUS (
937 ACPI_STATUS
938 AcpiInstallExceptionHandler (
939     ACPI_EXCEPTION_HANDLER  Handler))
940
941 ACPI_EXTERNAL_RETURN_STATUS (
942 ACPI_STATUS
943 AcpiInstallInterfaceHandler (
944     ACPI_INTERFACE_HANDLER  Handler))
945
946
947 /*
948  * Global Lock interfaces
949  */
950 ACPI_HW_DEPENDENT_RETURN_STATUS (
951 ACPI_STATUS
952 AcpiAcquireGlobalLock (
953     UINT16                  Timeout,
954     UINT32                  *Handle))
955
956 ACPI_HW_DEPENDENT_RETURN_STATUS (
957 ACPI_STATUS
958 AcpiReleaseGlobalLock (
959     UINT32                  Handle))
960
961
962 /*
963  * Interfaces to AML mutex objects
964  */
965 ACPI_EXTERNAL_RETURN_STATUS (
966 ACPI_STATUS
967 AcpiAcquireMutex (
968     ACPI_HANDLE             Handle,
969     ACPI_STRING             Pathname,
970     UINT16                  Timeout))
971
972 ACPI_EXTERNAL_RETURN_STATUS (
973 ACPI_STATUS
974 AcpiReleaseMutex (
975     ACPI_HANDLE             Handle,
976     ACPI_STRING             Pathname))
977
978
979 /*
980  * Fixed Event interfaces
981  */
982 ACPI_HW_DEPENDENT_RETURN_STATUS (
983 ACPI_STATUS
984 AcpiEnableEvent (
985     UINT32                  Event,
986     UINT32                  Flags))
987
988 ACPI_HW_DEPENDENT_RETURN_STATUS (
989 ACPI_STATUS
990 AcpiDisableEvent (
991     UINT32                  Event,
992     UINT32                  Flags))
993
994 ACPI_HW_DEPENDENT_RETURN_STATUS (
995 ACPI_STATUS
996 AcpiClearEvent (
997     UINT32                  Event))
998
999 ACPI_HW_DEPENDENT_RETURN_STATUS (
1000 ACPI_STATUS
1001 AcpiGetEventStatus (
1002     UINT32                  Event,
1003     ACPI_EVENT_STATUS       *EventStatus))
1004
1005
1006 /*
1007  * General Purpose Event (GPE) Interfaces
1008  */
1009 ACPI_HW_DEPENDENT_RETURN_STATUS (
1010 ACPI_STATUS
1011 AcpiUpdateAllGpes (
1012     void))
1013
1014 ACPI_HW_DEPENDENT_RETURN_STATUS (
1015 ACPI_STATUS
1016 AcpiEnableGpe (
1017     ACPI_HANDLE             GpeDevice,
1018     UINT32                  GpeNumber))
1019
1020 ACPI_HW_DEPENDENT_RETURN_STATUS (
1021 ACPI_STATUS
1022 AcpiDisableGpe (
1023     ACPI_HANDLE             GpeDevice,
1024     UINT32                  GpeNumber))
1025
1026 ACPI_HW_DEPENDENT_RETURN_STATUS (
1027 ACPI_STATUS
1028 AcpiClearGpe (
1029     ACPI_HANDLE             GpeDevice,
1030     UINT32                  GpeNumber))
1031
1032 ACPI_HW_DEPENDENT_RETURN_STATUS (
1033 ACPI_STATUS
1034 AcpiSetGpe (
1035     ACPI_HANDLE             GpeDevice,
1036     UINT32                  GpeNumber,
1037     UINT8                   Action))
1038
1039 ACPI_HW_DEPENDENT_RETURN_STATUS (
1040 ACPI_STATUS
1041 AcpiFinishGpe (
1042     ACPI_HANDLE             GpeDevice,
1043     UINT32                  GpeNumber))
1044
1045 ACPI_HW_DEPENDENT_RETURN_STATUS (
1046 ACPI_STATUS
1047 AcpiMaskGpe (
1048     ACPI_HANDLE             GpeDevice,
1049     UINT32                  GpeNumber,
1050     BOOLEAN                 IsMasked))
1051
1052 ACPI_HW_DEPENDENT_RETURN_STATUS (
1053 ACPI_STATUS
1054 AcpiMarkGpeForWake (
1055     ACPI_HANDLE             GpeDevice,
1056     UINT32                  GpeNumber))
1057
1058 ACPI_HW_DEPENDENT_RETURN_STATUS (
1059 ACPI_STATUS
1060 AcpiSetupGpeForWake (
1061     ACPI_HANDLE             ParentDevice,
1062     ACPI_HANDLE             GpeDevice,
1063     UINT32                  GpeNumber))
1064
1065 ACPI_HW_DEPENDENT_RETURN_STATUS (
1066 ACPI_STATUS
1067 AcpiSetGpeWakeMask (
1068     ACPI_HANDLE             GpeDevice,
1069     UINT32                  GpeNumber,
1070     UINT8                   Action))
1071
1072 ACPI_HW_DEPENDENT_RETURN_STATUS (
1073 ACPI_STATUS
1074 AcpiGetGpeStatus (
1075     ACPI_HANDLE             GpeDevice,
1076     UINT32                  GpeNumber,
1077     ACPI_EVENT_STATUS       *EventStatus))
1078
1079 ACPI_HW_DEPENDENT_RETURN_STATUS (
1080 ACPI_STATUS
1081 AcpiDisableAllGpes (
1082     void))
1083
1084 ACPI_HW_DEPENDENT_RETURN_STATUS (
1085 ACPI_STATUS
1086 AcpiEnableAllRuntimeGpes (
1087     void))
1088
1089 ACPI_HW_DEPENDENT_RETURN_STATUS (
1090 ACPI_STATUS
1091 AcpiEnableAllWakeupGpes (
1092     void))
1093
1094 ACPI_HW_DEPENDENT_RETURN_STATUS (
1095 ACPI_STATUS
1096 AcpiGetGpeDevice (
1097     UINT32                  GpeIndex,
1098     ACPI_HANDLE             *GpeDevice))
1099
1100 ACPI_HW_DEPENDENT_RETURN_STATUS (
1101 ACPI_STATUS
1102 AcpiInstallGpeBlock (
1103     ACPI_HANDLE             GpeDevice,
1104     ACPI_GENERIC_ADDRESS    *GpeBlockAddress,
1105     UINT32                  RegisterCount,
1106     UINT32                  InterruptNumber))
1107
1108 ACPI_HW_DEPENDENT_RETURN_STATUS (
1109 ACPI_STATUS
1110 AcpiRemoveGpeBlock (
1111     ACPI_HANDLE             GpeDevice))
1112
1113
1114 /*
1115  * Resource interfaces
1116  */
1117 typedef
1118 ACPI_STATUS (*ACPI_WALK_RESOURCE_CALLBACK) (
1119     ACPI_RESOURCE           *Resource,
1120     void                    *Context);
1121
1122 ACPI_EXTERNAL_RETURN_STATUS (
1123 ACPI_STATUS
1124 AcpiGetVendorResource (
1125     ACPI_HANDLE             Device,
1126     char                    *Name,
1127     ACPI_VENDOR_UUID        *Uuid,
1128     ACPI_BUFFER             *RetBuffer))
1129
1130 ACPI_EXTERNAL_RETURN_STATUS (
1131 ACPI_STATUS
1132 AcpiGetCurrentResources (
1133     ACPI_HANDLE             Device,
1134     ACPI_BUFFER             *RetBuffer))
1135
1136 ACPI_EXTERNAL_RETURN_STATUS (
1137 ACPI_STATUS
1138 AcpiGetPossibleResources (
1139     ACPI_HANDLE             Device,
1140     ACPI_BUFFER             *RetBuffer))
1141
1142 ACPI_EXTERNAL_RETURN_STATUS (
1143 ACPI_STATUS
1144 AcpiGetEventResources (
1145     ACPI_HANDLE             DeviceHandle,
1146     ACPI_BUFFER             *RetBuffer))
1147
1148 ACPI_EXTERNAL_RETURN_STATUS (
1149 ACPI_STATUS
1150 AcpiWalkResourceBuffer (
1151     ACPI_BUFFER                 *Buffer,
1152     ACPI_WALK_RESOURCE_CALLBACK UserFunction,
1153     void                        *Context))
1154
1155 ACPI_EXTERNAL_RETURN_STATUS (
1156 ACPI_STATUS
1157 AcpiWalkResources (
1158     ACPI_HANDLE                 Device,
1159     char                        *Name,
1160     ACPI_WALK_RESOURCE_CALLBACK UserFunction,
1161     void                        *Context))
1162
1163 ACPI_EXTERNAL_RETURN_STATUS (
1164 ACPI_STATUS
1165 AcpiSetCurrentResources (
1166     ACPI_HANDLE             Device,
1167     ACPI_BUFFER             *InBuffer))
1168
1169 ACPI_EXTERNAL_RETURN_STATUS (
1170 ACPI_STATUS
1171 AcpiGetIrqRoutingTable (
1172     ACPI_HANDLE             Device,
1173     ACPI_BUFFER             *RetBuffer))
1174
1175 ACPI_EXTERNAL_RETURN_STATUS (
1176 ACPI_STATUS
1177 AcpiResourceToAddress64 (
1178     ACPI_RESOURCE           *Resource,
1179     ACPI_RESOURCE_ADDRESS64 *Out))
1180
1181 ACPI_EXTERNAL_RETURN_STATUS (
1182 ACPI_STATUS
1183 AcpiBufferToResource (
1184     UINT8                   *AmlBuffer,
1185     UINT16                  AmlBufferLength,
1186     ACPI_RESOURCE           **ResourcePtr))
1187
1188
1189 /*
1190  * Hardware (ACPI device) interfaces
1191  */
1192 ACPI_EXTERNAL_RETURN_STATUS (
1193 ACPI_STATUS
1194 AcpiReset (
1195     void))
1196
1197 ACPI_EXTERNAL_RETURN_STATUS (
1198 ACPI_STATUS
1199 AcpiRead (
1200     UINT64                  *Value,
1201     ACPI_GENERIC_ADDRESS    *Reg))
1202
1203 ACPI_EXTERNAL_RETURN_STATUS (
1204 ACPI_STATUS
1205 AcpiWrite (
1206     UINT64                  Value,
1207     ACPI_GENERIC_ADDRESS    *Reg))
1208
1209 ACPI_HW_DEPENDENT_RETURN_STATUS (
1210 ACPI_STATUS
1211 AcpiReadBitRegister (
1212     UINT32                  RegisterId,
1213     UINT32                  *ReturnValue))
1214
1215 ACPI_HW_DEPENDENT_RETURN_STATUS (
1216 ACPI_STATUS
1217 AcpiWriteBitRegister (
1218     UINT32                  RegisterId,
1219     UINT32                  Value))
1220
1221
1222 /*
1223  * Sleep/Wake interfaces
1224  */
1225 ACPI_EXTERNAL_RETURN_STATUS (
1226 ACPI_STATUS
1227 AcpiGetSleepTypeData (
1228     UINT8                   SleepState,
1229     UINT8                   *Slp_TypA,
1230     UINT8                   *Slp_TypB))
1231
1232 ACPI_EXTERNAL_RETURN_STATUS (
1233 ACPI_STATUS
1234 AcpiEnterSleepStatePrep (
1235     UINT8                   SleepState))
1236
1237 ACPI_EXTERNAL_RETURN_STATUS (
1238 ACPI_STATUS
1239 AcpiEnterSleepState (
1240     UINT8                   SleepState))
1241
1242 ACPI_HW_DEPENDENT_RETURN_STATUS (
1243 ACPI_STATUS
1244 AcpiEnterSleepStateS4bios (
1245     void))
1246
1247 ACPI_EXTERNAL_RETURN_STATUS (
1248 ACPI_STATUS
1249 AcpiLeaveSleepStatePrep (
1250     UINT8                   SleepState))
1251
1252 ACPI_EXTERNAL_RETURN_STATUS (
1253 ACPI_STATUS
1254 AcpiLeaveSleepState (
1255     UINT8                   SleepState))
1256
1257 ACPI_HW_DEPENDENT_RETURN_STATUS (
1258 ACPI_STATUS
1259 AcpiSetFirmwareWakingVector (
1260     ACPI_PHYSICAL_ADDRESS   PhysicalAddress,
1261     ACPI_PHYSICAL_ADDRESS   PhysicalAddress64))
1262
1263
1264 /*
1265  * ACPI Timer interfaces
1266  */
1267 ACPI_HW_DEPENDENT_RETURN_STATUS (
1268 ACPI_STATUS
1269 AcpiGetTimerResolution (
1270     UINT32                  *Resolution))
1271
1272 ACPI_HW_DEPENDENT_RETURN_STATUS (
1273 ACPI_STATUS
1274 AcpiGetTimer (
1275     UINT32                  *Ticks))
1276
1277 ACPI_HW_DEPENDENT_RETURN_STATUS (
1278 ACPI_STATUS
1279 AcpiGetTimerDuration (
1280     UINT32                  StartTicks,
1281     UINT32                  EndTicks,
1282     UINT32                  *TimeElapsed))
1283
1284
1285 /*
1286  * Error/Warning output
1287  */
1288 ACPI_MSG_DEPENDENT_RETURN_VOID (
1289 ACPI_PRINTF_LIKE(3)
1290 void ACPI_INTERNAL_VAR_XFACE
1291 AcpiError (
1292     const char              *ModuleName,
1293     UINT32                  LineNumber,
1294     const char              *Format,
1295     ...))
1296
1297 ACPI_MSG_DEPENDENT_RETURN_VOID (
1298 ACPI_PRINTF_LIKE(4)
1299 void  ACPI_INTERNAL_VAR_XFACE
1300 AcpiException (
1301     const char              *ModuleName,
1302     UINT32                  LineNumber,
1303     ACPI_STATUS             Status,
1304     const char              *Format,
1305     ...))
1306
1307 ACPI_MSG_DEPENDENT_RETURN_VOID (
1308 ACPI_PRINTF_LIKE(3)
1309 void ACPI_INTERNAL_VAR_XFACE
1310 AcpiWarning (
1311     const char              *ModuleName,
1312     UINT32                  LineNumber,
1313     const char              *Format,
1314     ...))
1315
1316 ACPI_MSG_DEPENDENT_RETURN_VOID (
1317 ACPI_PRINTF_LIKE(1)
1318 void ACPI_INTERNAL_VAR_XFACE
1319 AcpiInfo (
1320     const char              *Format,
1321     ...))
1322
1323 ACPI_MSG_DEPENDENT_RETURN_VOID (
1324 ACPI_PRINTF_LIKE(3)
1325 void ACPI_INTERNAL_VAR_XFACE
1326 AcpiBiosError (
1327     const char              *ModuleName,
1328     UINT32                  LineNumber,
1329     const char              *Format,
1330     ...))
1331
1332 ACPI_MSG_DEPENDENT_RETURN_VOID (
1333 ACPI_PRINTF_LIKE(4)
1334 void  ACPI_INTERNAL_VAR_XFACE
1335 AcpiBiosException (
1336     const char              *ModuleName,
1337     UINT32                  LineNumber,
1338     ACPI_STATUS             Status,
1339     const char              *Format,
1340     ...))
1341
1342 ACPI_MSG_DEPENDENT_RETURN_VOID (
1343 ACPI_PRINTF_LIKE(3)
1344 void ACPI_INTERNAL_VAR_XFACE
1345 AcpiBiosWarning (
1346     const char              *ModuleName,
1347     UINT32                  LineNumber,
1348     const char              *Format,
1349     ...))
1350
1351
1352 /*
1353  * Debug output
1354  */
1355 ACPI_DBG_DEPENDENT_RETURN_VOID (
1356 ACPI_PRINTF_LIKE(6)
1357 void ACPI_INTERNAL_VAR_XFACE
1358 AcpiDebugPrint (
1359     UINT32                  RequestedDebugLevel,
1360     UINT32                  LineNumber,
1361     const char              *FunctionName,
1362     const char              *ModuleName,
1363     UINT32                  ComponentId,
1364     const char              *Format,
1365     ...))
1366
1367 ACPI_DBG_DEPENDENT_RETURN_VOID (
1368 ACPI_PRINTF_LIKE(6)
1369 void ACPI_INTERNAL_VAR_XFACE
1370 AcpiDebugPrintRaw (
1371     UINT32                  RequestedDebugLevel,
1372     UINT32                  LineNumber,
1373     const char              *FunctionName,
1374     const char              *ModuleName,
1375     UINT32                  ComponentId,
1376     const char              *Format,
1377     ...))
1378
1379 ACPI_DBG_DEPENDENT_RETURN_VOID (
1380 void
1381 AcpiTracePoint (
1382     ACPI_TRACE_EVENT_TYPE   Type,
1383     BOOLEAN                 Begin,
1384     UINT8                   *Aml,
1385     char                    *Pathname))
1386
1387 ACPI_STATUS
1388 AcpiInitializeDebugger (
1389     void);
1390
1391 void
1392 AcpiTerminateDebugger (
1393     void);
1394
1395 void
1396 AcpiRunDebugger (
1397     char                    *BatchBuffer);
1398
1399 void
1400 AcpiSetDebuggerThreadId (
1401     ACPI_THREAD_ID          ThreadId);
1402
1403 #endif /* __ACXFACE_H__ */