xref: /freebsd/sys/contrib/dev/acpica/include/acdebug.h (revision b7b7e71176cc1bb79b4a815163a8314c034e3e4e)
1a9f12690SJung-uk Kim /******************************************************************************
2a9f12690SJung-uk Kim  *
3a9f12690SJung-uk Kim  * Name: acdebug.h - ACPI/AML debugger
4a9f12690SJung-uk Kim  *
5a9f12690SJung-uk Kim  *****************************************************************************/
6a9f12690SJung-uk Kim 
70d84335fSJung-uk Kim /******************************************************************************
80d84335fSJung-uk Kim  *
90d84335fSJung-uk Kim  * 1. Copyright Notice
100d84335fSJung-uk Kim  *
110d84335fSJung-uk Kim  * Some or all of this work - Copyright (c) 1999 - 2017, Intel Corp.
12a9f12690SJung-uk Kim  * All rights reserved.
13a9f12690SJung-uk Kim  *
140d84335fSJung-uk Kim  * 2. License
150d84335fSJung-uk Kim  *
160d84335fSJung-uk Kim  * 2.1. This is your license from Intel Corp. under its intellectual property
170d84335fSJung-uk Kim  * rights. You may have additional license terms from the party that provided
180d84335fSJung-uk Kim  * you this software, covering your right to use that party's intellectual
190d84335fSJung-uk Kim  * property rights.
200d84335fSJung-uk Kim  *
210d84335fSJung-uk Kim  * 2.2. Intel grants, free of charge, to any person ("Licensee") obtaining a
220d84335fSJung-uk Kim  * copy of the source code appearing in this file ("Covered Code") an
230d84335fSJung-uk Kim  * irrevocable, perpetual, worldwide license under Intel's copyrights in the
240d84335fSJung-uk Kim  * base code distributed originally by Intel ("Original Intel Code") to copy,
250d84335fSJung-uk Kim  * make derivatives, distribute, use and display any portion of the Covered
260d84335fSJung-uk Kim  * Code in any form, with the right to sublicense such rights; and
270d84335fSJung-uk Kim  *
280d84335fSJung-uk Kim  * 2.3. Intel grants Licensee a non-exclusive and non-transferable patent
290d84335fSJung-uk Kim  * license (with the right to sublicense), under only those claims of Intel
300d84335fSJung-uk Kim  * patents that are infringed by the Original Intel Code, to make, use, sell,
310d84335fSJung-uk Kim  * offer to sell, and import the Covered Code and derivative works thereof
320d84335fSJung-uk Kim  * solely to the minimum extent necessary to exercise the above copyright
330d84335fSJung-uk Kim  * license, and in no event shall the patent license extend to any additions
340d84335fSJung-uk Kim  * to or modifications of the Original Intel Code. No other license or right
350d84335fSJung-uk Kim  * is granted directly or by implication, estoppel or otherwise;
360d84335fSJung-uk Kim  *
370d84335fSJung-uk Kim  * The above copyright and patent license is granted only if the following
380d84335fSJung-uk Kim  * conditions are met:
390d84335fSJung-uk Kim  *
400d84335fSJung-uk Kim  * 3. Conditions
410d84335fSJung-uk Kim  *
420d84335fSJung-uk Kim  * 3.1. Redistribution of Source with Rights to Further Distribute Source.
430d84335fSJung-uk Kim  * Redistribution of source code of any substantial portion of the Covered
440d84335fSJung-uk Kim  * Code or modification with rights to further distribute source must include
450d84335fSJung-uk Kim  * the above Copyright Notice, the above License, this list of Conditions,
460d84335fSJung-uk Kim  * and the following Disclaimer and Export Compliance provision. In addition,
470d84335fSJung-uk Kim  * Licensee must cause all Covered Code to which Licensee contributes to
480d84335fSJung-uk Kim  * contain a file documenting the changes Licensee made to create that Covered
490d84335fSJung-uk Kim  * Code and the date of any change. Licensee must include in that file the
500d84335fSJung-uk Kim  * documentation of any changes made by any predecessor Licensee. Licensee
510d84335fSJung-uk Kim  * must include a prominent statement that the modification is derived,
520d84335fSJung-uk Kim  * directly or indirectly, from Original Intel Code.
530d84335fSJung-uk Kim  *
540d84335fSJung-uk Kim  * 3.2. Redistribution of Source with no Rights to Further Distribute Source.
550d84335fSJung-uk Kim  * Redistribution of source code of any substantial portion of the Covered
560d84335fSJung-uk Kim  * Code or modification without rights to further distribute source must
570d84335fSJung-uk Kim  * include the following Disclaimer and Export Compliance provision in the
580d84335fSJung-uk Kim  * documentation and/or other materials provided with distribution. In
590d84335fSJung-uk Kim  * addition, Licensee may not authorize further sublicense of source of any
600d84335fSJung-uk Kim  * portion of the Covered Code, and must include terms to the effect that the
610d84335fSJung-uk Kim  * license from Licensee to its licensee is limited to the intellectual
620d84335fSJung-uk Kim  * property embodied in the software Licensee provides to its licensee, and
630d84335fSJung-uk Kim  * not to intellectual property embodied in modifications its licensee may
640d84335fSJung-uk Kim  * make.
650d84335fSJung-uk Kim  *
660d84335fSJung-uk Kim  * 3.3. Redistribution of Executable. Redistribution in executable form of any
670d84335fSJung-uk Kim  * substantial portion of the Covered Code or modification must reproduce the
680d84335fSJung-uk Kim  * above Copyright Notice, and the following Disclaimer and Export Compliance
690d84335fSJung-uk Kim  * provision in the documentation and/or other materials provided with the
700d84335fSJung-uk Kim  * distribution.
710d84335fSJung-uk Kim  *
720d84335fSJung-uk Kim  * 3.4. Intel retains all right, title, and interest in and to the Original
730d84335fSJung-uk Kim  * Intel Code.
740d84335fSJung-uk Kim  *
750d84335fSJung-uk Kim  * 3.5. Neither the name Intel nor any other trademark owned or controlled by
760d84335fSJung-uk Kim  * Intel shall be used in advertising or otherwise to promote the sale, use or
770d84335fSJung-uk Kim  * other dealings in products derived from or relating to the Covered Code
780d84335fSJung-uk Kim  * without prior written authorization from Intel.
790d84335fSJung-uk Kim  *
800d84335fSJung-uk Kim  * 4. Disclaimer and Export Compliance
810d84335fSJung-uk Kim  *
820d84335fSJung-uk Kim  * 4.1. INTEL MAKES NO WARRANTY OF ANY KIND REGARDING ANY SOFTWARE PROVIDED
830d84335fSJung-uk Kim  * HERE. ANY SOFTWARE ORIGINATING FROM INTEL OR DERIVED FROM INTEL SOFTWARE
840d84335fSJung-uk Kim  * IS PROVIDED "AS IS," AND INTEL WILL NOT PROVIDE ANY SUPPORT, ASSISTANCE,
850d84335fSJung-uk Kim  * INSTALLATION, TRAINING OR OTHER SERVICES. INTEL WILL NOT PROVIDE ANY
860d84335fSJung-uk Kim  * UPDATES, ENHANCEMENTS OR EXTENSIONS. INTEL SPECIFICALLY DISCLAIMS ANY
870d84335fSJung-uk Kim  * IMPLIED WARRANTIES OF MERCHANTABILITY, NONINFRINGEMENT AND FITNESS FOR A
880d84335fSJung-uk Kim  * PARTICULAR PURPOSE.
890d84335fSJung-uk Kim  *
900d84335fSJung-uk Kim  * 4.2. IN NO EVENT SHALL INTEL HAVE ANY LIABILITY TO LICENSEE, ITS LICENSEES
910d84335fSJung-uk Kim  * OR ANY OTHER THIRD PARTY, FOR ANY LOST PROFITS, LOST DATA, LOSS OF USE OR
920d84335fSJung-uk Kim  * COSTS OF PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES, OR FOR ANY INDIRECT,
930d84335fSJung-uk Kim  * SPECIAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THIS AGREEMENT, UNDER ANY
940d84335fSJung-uk Kim  * CAUSE OF ACTION OR THEORY OF LIABILITY, AND IRRESPECTIVE OF WHETHER INTEL
950d84335fSJung-uk Kim  * HAS ADVANCE NOTICE OF THE POSSIBILITY OF SUCH DAMAGES. THESE LIMITATIONS
960d84335fSJung-uk Kim  * SHALL APPLY NOTWITHSTANDING THE FAILURE OF THE ESSENTIAL PURPOSE OF ANY
970d84335fSJung-uk Kim  * LIMITED REMEDY.
980d84335fSJung-uk Kim  *
990d84335fSJung-uk Kim  * 4.3. Licensee shall not export, either directly or indirectly, any of this
1000d84335fSJung-uk Kim  * software or system incorporating such software without first obtaining any
1010d84335fSJung-uk Kim  * required license or other approval from the U. S. Department of Commerce or
1020d84335fSJung-uk Kim  * any other agency or department of the United States Government. In the
1030d84335fSJung-uk Kim  * event Licensee exports any such software from the United States or
1040d84335fSJung-uk Kim  * re-exports any such software from a foreign destination, Licensee shall
1050d84335fSJung-uk Kim  * ensure that the distribution and export/re-export of the software is in
1060d84335fSJung-uk Kim  * compliance with all laws, regulations, orders, or other restrictions of the
1070d84335fSJung-uk Kim  * U.S. Export Administration Regulations. Licensee agrees that neither it nor
1080d84335fSJung-uk Kim  * any of its subsidiaries will export/re-export any technical data, process,
1090d84335fSJung-uk Kim  * software, or service, directly or indirectly, to any country for which the
1100d84335fSJung-uk Kim  * United States government or any agency thereof requires an export license,
1110d84335fSJung-uk Kim  * other governmental approval, or letter of assurance, without first obtaining
1120d84335fSJung-uk Kim  * such license, approval or letter.
1130d84335fSJung-uk Kim  *
1140d84335fSJung-uk Kim  *****************************************************************************
1150d84335fSJung-uk Kim  *
1160d84335fSJung-uk Kim  * Alternatively, you may choose to be licensed under the terms of the
1170d84335fSJung-uk Kim  * following license:
1180d84335fSJung-uk Kim  *
119d244b227SJung-uk Kim  * Redistribution and use in source and binary forms, with or without
120d244b227SJung-uk Kim  * modification, are permitted provided that the following conditions
121d244b227SJung-uk Kim  * are met:
122d244b227SJung-uk Kim  * 1. Redistributions of source code must retain the above copyright
123d244b227SJung-uk Kim  *    notice, this list of conditions, and the following disclaimer,
124d244b227SJung-uk Kim  *    without modification.
125d244b227SJung-uk Kim  * 2. Redistributions in binary form must reproduce at minimum a disclaimer
126d244b227SJung-uk Kim  *    substantially similar to the "NO WARRANTY" disclaimer below
127d244b227SJung-uk Kim  *    ("Disclaimer") and any redistribution must be conditioned upon
128d244b227SJung-uk Kim  *    including a substantially similar Disclaimer requirement for further
129d244b227SJung-uk Kim  *    binary redistribution.
130d244b227SJung-uk Kim  * 3. Neither the names of the above-listed copyright holders nor the names
131d244b227SJung-uk Kim  *    of any contributors may be used to endorse or promote products derived
132d244b227SJung-uk Kim  *    from this software without specific prior written permission.
133a9f12690SJung-uk Kim  *
1340d84335fSJung-uk Kim  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
1350d84335fSJung-uk Kim  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
1360d84335fSJung-uk Kim  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
1370d84335fSJung-uk Kim  * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
1380d84335fSJung-uk Kim  * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
1390d84335fSJung-uk Kim  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
1400d84335fSJung-uk Kim  * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
1410d84335fSJung-uk Kim  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
1420d84335fSJung-uk Kim  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
1430d84335fSJung-uk Kim  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
1440d84335fSJung-uk Kim  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
1450d84335fSJung-uk Kim  *
1460d84335fSJung-uk Kim  * Alternatively, you may choose to be licensed under the terms of the
147d244b227SJung-uk Kim  * GNU General Public License ("GPL") version 2 as published by the Free
148d244b227SJung-uk Kim  * Software Foundation.
149a9f12690SJung-uk Kim  *
1500d84335fSJung-uk Kim  *****************************************************************************/
151a9f12690SJung-uk Kim 
152a9f12690SJung-uk Kim #ifndef __ACDEBUG_H__
153a9f12690SJung-uk Kim #define __ACDEBUG_H__
154a9f12690SJung-uk Kim 
15570e6ab8fSJung-uk Kim /* The debugger is used in conjunction with the disassembler most of time */
15670e6ab8fSJung-uk Kim 
15770e6ab8fSJung-uk Kim #ifdef ACPI_DISASSEMBLER
15870e6ab8fSJung-uk Kim #include <contrib/dev/acpica/include/acdisasm.h>
15970e6ab8fSJung-uk Kim #endif
16070e6ab8fSJung-uk Kim 
161a9f12690SJung-uk Kim 
1625a77b11bSJung-uk Kim #define ACPI_DEBUG_BUFFER_SIZE  0x4000      /* 16K buffer for return objects */
163a9f12690SJung-uk Kim 
164042ff955SJung-uk Kim typedef struct acpi_db_command_info
165a9f12690SJung-uk Kim {
166f8146b88SJung-uk Kim     const char              *Name;          /* Command Name */
167a9f12690SJung-uk Kim     UINT8                   MinArgs;        /* Minimum arguments required */
168a9f12690SJung-uk Kim 
169042ff955SJung-uk Kim } ACPI_DB_COMMAND_INFO;
170a9f12690SJung-uk Kim 
171042ff955SJung-uk Kim typedef struct acpi_db_command_help
172042ff955SJung-uk Kim {
173042ff955SJung-uk Kim     UINT8                   LineCount;      /* Number of help lines */
174042ff955SJung-uk Kim     char                    *Invocation;    /* Command Invocation */
175042ff955SJung-uk Kim     char                    *Description;   /* Command Description */
176042ff955SJung-uk Kim 
177042ff955SJung-uk Kim } ACPI_DB_COMMAND_HELP;
178042ff955SJung-uk Kim 
179042ff955SJung-uk Kim typedef struct acpi_db_argument_info
180a9f12690SJung-uk Kim {
181f8146b88SJung-uk Kim     const char              *Name;          /* Argument Name */
182a9f12690SJung-uk Kim 
183042ff955SJung-uk Kim } ACPI_DB_ARGUMENT_INFO;
184a9f12690SJung-uk Kim 
185042ff955SJung-uk Kim typedef struct acpi_db_execute_walk
186f556842eSJung-uk Kim {
187f556842eSJung-uk Kim     UINT32                  Count;
188f556842eSJung-uk Kim     UINT32                  MaxCount;
189f556842eSJung-uk Kim 
190042ff955SJung-uk Kim } ACPI_DB_EXECUTE_WALK;
191f556842eSJung-uk Kim 
192a9f12690SJung-uk Kim 
193a9f12690SJung-uk Kim #define PARAM_LIST(pl)                  pl
194a9f12690SJung-uk Kim 
195a9f12690SJung-uk Kim #define EX_NO_SINGLE_STEP               1
196a9f12690SJung-uk Kim #define EX_SINGLE_STEP                  2
197a9f12690SJung-uk Kim 
198a9f12690SJung-uk Kim 
199a9f12690SJung-uk Kim /*
200a9f12690SJung-uk Kim  * dbxface - external debugger interfaces
201a9f12690SJung-uk Kim  */
202f8146b88SJung-uk Kim ACPI_DBR_DEPENDENT_RETURN_OK (
203a9f12690SJung-uk Kim ACPI_STATUS
204a9f12690SJung-uk Kim AcpiDbSingleStep (
205a9f12690SJung-uk Kim     ACPI_WALK_STATE         *WalkState,
206a9f12690SJung-uk Kim     ACPI_PARSE_OBJECT       *Op,
207f8146b88SJung-uk Kim     UINT32                  OpType))
208f8146b88SJung-uk Kim 
209f8146b88SJung-uk Kim ACPI_DBR_DEPENDENT_RETURN_VOID (
210f8146b88SJung-uk Kim void
211f8146b88SJung-uk Kim AcpiDbSignalBreakPoint (
212f8146b88SJung-uk Kim     ACPI_WALK_STATE         *WalkState))
213a9f12690SJung-uk Kim 
214a9f12690SJung-uk Kim 
215a9f12690SJung-uk Kim /*
216a9f12690SJung-uk Kim  * dbcmds - debug commands and output routines
217a9f12690SJung-uk Kim  */
2180b94ba42SJung-uk Kim ACPI_NAMESPACE_NODE *
2190b94ba42SJung-uk Kim AcpiDbConvertToNode (
2200b94ba42SJung-uk Kim     char                    *InString);
221a9f12690SJung-uk Kim 
222a9f12690SJung-uk Kim void
223a9f12690SJung-uk Kim AcpiDbDisplayTableInfo (
224a9f12690SJung-uk Kim     char                    *TableArg);
225a9f12690SJung-uk Kim 
226a9f12690SJung-uk Kim void
2273f0275a0SJung-uk Kim AcpiDbDisplayTemplate (
2283f0275a0SJung-uk Kim     char                    *BufferArg);
2293f0275a0SJung-uk Kim 
2303f0275a0SJung-uk Kim void
231a9f12690SJung-uk Kim AcpiDbUnloadAcpiTable (
232e8241eabSJung-uk Kim     char                    *Name);
233a9f12690SJung-uk Kim 
234a9f12690SJung-uk Kim void
235a9f12690SJung-uk Kim AcpiDbSendNotify (
236a9f12690SJung-uk Kim     char                    *Name,
237a9f12690SJung-uk Kim     UINT32                  Value);
238a9f12690SJung-uk Kim 
239a9f12690SJung-uk Kim void
240709fac06SJung-uk Kim AcpiDbDisplayInterfaces (
241709fac06SJung-uk Kim     char                    *ActionArg,
242709fac06SJung-uk Kim     char                    *InterfaceNameArg);
243709fac06SJung-uk Kim 
244a9f12690SJung-uk Kim ACPI_STATUS
245a9f12690SJung-uk Kim AcpiDbSleep (
246a9f12690SJung-uk Kim     char                    *ObjectArg);
247a9f12690SJung-uk Kim 
248a9f12690SJung-uk Kim void
249fe0f0bbbSJung-uk Kim AcpiDbTrace (
250fe0f0bbbSJung-uk Kim     char                    *EnableArg,
251fe0f0bbbSJung-uk Kim     char                    *MethodArg,
252fe0f0bbbSJung-uk Kim     char                    *OnceArg);
253fe0f0bbbSJung-uk Kim 
254fe0f0bbbSJung-uk Kim void
255a9f12690SJung-uk Kim AcpiDbDisplayLocks (
256a9f12690SJung-uk Kim     void);
257a9f12690SJung-uk Kim 
258a9f12690SJung-uk Kim void
259a9f12690SJung-uk Kim AcpiDbDisplayResources (
260a9f12690SJung-uk Kim     char                    *ObjectArg);
261a9f12690SJung-uk Kim 
262a159c266SJung-uk Kim ACPI_HW_DEPENDENT_RETURN_VOID (
263a9f12690SJung-uk Kim void
264a9f12690SJung-uk Kim AcpiDbDisplayGpes (
265a159c266SJung-uk Kim     void))
266a9f12690SJung-uk Kim 
267a9f12690SJung-uk Kim void
2680b94ba42SJung-uk Kim AcpiDbDisplayHandlers (
269a9f12690SJung-uk Kim     void);
270a9f12690SJung-uk Kim 
271a159c266SJung-uk Kim ACPI_HW_DEPENDENT_RETURN_VOID (
272a9f12690SJung-uk Kim void
273a9f12690SJung-uk Kim AcpiDbGenerateGpe (
274a9f12690SJung-uk Kim     char                    *GpeArg,
275a159c266SJung-uk Kim     char                    *BlockArg))
276a9f12690SJung-uk Kim 
27779c6d946SJung-uk Kim ACPI_HW_DEPENDENT_RETURN_VOID (
27879c6d946SJung-uk Kim void
27979c6d946SJung-uk Kim AcpiDbGenerateSci (
28079c6d946SJung-uk Kim     void))
2810b94ba42SJung-uk Kim 
282313a0c13SJung-uk Kim void
283313a0c13SJung-uk Kim AcpiDbExecuteTest (
284313a0c13SJung-uk Kim     char                    *TypeArg);
285313a0c13SJung-uk Kim 
286313a0c13SJung-uk Kim 
2870b94ba42SJung-uk Kim /*
288efcc2a30SJung-uk Kim  * dbconvert - miscellaneous conversion routines
289efcc2a30SJung-uk Kim  */
290efcc2a30SJung-uk Kim ACPI_STATUS
291efcc2a30SJung-uk Kim AcpiDbHexCharToValue (
292efcc2a30SJung-uk Kim     int                     HexChar,
293efcc2a30SJung-uk Kim     UINT8                   *ReturnValue);
294efcc2a30SJung-uk Kim 
295efcc2a30SJung-uk Kim ACPI_STATUS
296efcc2a30SJung-uk Kim AcpiDbConvertToPackage (
297efcc2a30SJung-uk Kim     char                    *String,
298efcc2a30SJung-uk Kim     ACPI_OBJECT             *Object);
299efcc2a30SJung-uk Kim 
300efcc2a30SJung-uk Kim ACPI_STATUS
301efcc2a30SJung-uk Kim AcpiDbConvertToObject (
302efcc2a30SJung-uk Kim     ACPI_OBJECT_TYPE        Type,
303efcc2a30SJung-uk Kim     char                    *String,
304efcc2a30SJung-uk Kim     ACPI_OBJECT             *Object);
305efcc2a30SJung-uk Kim 
306efcc2a30SJung-uk Kim UINT8 *
307efcc2a30SJung-uk Kim AcpiDbEncodePldBuffer (
308efcc2a30SJung-uk Kim     ACPI_PLD_INFO           *PldInfo);
309efcc2a30SJung-uk Kim 
310efcc2a30SJung-uk Kim void
311efcc2a30SJung-uk Kim AcpiDbDumpPldBuffer (
312efcc2a30SJung-uk Kim     ACPI_OBJECT             *ObjDesc);
313efcc2a30SJung-uk Kim 
314efcc2a30SJung-uk Kim 
315efcc2a30SJung-uk Kim /*
3160b94ba42SJung-uk Kim  * dbmethod - control method commands
3170b94ba42SJung-uk Kim  */
318a9f12690SJung-uk Kim void
3190b94ba42SJung-uk Kim AcpiDbSetMethodBreakpoint (
3200b94ba42SJung-uk Kim     char                    *Location,
3210b94ba42SJung-uk Kim     ACPI_WALK_STATE         *WalkState,
3220b94ba42SJung-uk Kim     ACPI_PARSE_OBJECT       *Op);
3230b94ba42SJung-uk Kim 
3240b94ba42SJung-uk Kim void
3250b94ba42SJung-uk Kim AcpiDbSetMethodCallBreakpoint (
3260b94ba42SJung-uk Kim     ACPI_PARSE_OBJECT       *Op);
3270b94ba42SJung-uk Kim 
3280b94ba42SJung-uk Kim void
3290b94ba42SJung-uk Kim AcpiDbSetMethodData (
3300b94ba42SJung-uk Kim     char                    *TypeArg,
3310b94ba42SJung-uk Kim     char                    *IndexArg,
3320b94ba42SJung-uk Kim     char                    *ValueArg);
3330b94ba42SJung-uk Kim 
3340b94ba42SJung-uk Kim ACPI_STATUS
3350b94ba42SJung-uk Kim AcpiDbDisassembleMethod (
3360b94ba42SJung-uk Kim     char                    *Name);
3370b94ba42SJung-uk Kim 
3380b94ba42SJung-uk Kim void
3390b94ba42SJung-uk Kim AcpiDbDisassembleAml (
3400b94ba42SJung-uk Kim     char                    *Statements,
3410b94ba42SJung-uk Kim     ACPI_PARSE_OBJECT       *Op);
342a9f12690SJung-uk Kim 
343a9f12690SJung-uk Kim void
344493deb39SJung-uk Kim AcpiDbEvaluatePredefinedNames (
345493deb39SJung-uk Kim     void);
346a9f12690SJung-uk Kim 
3470b94ba42SJung-uk Kim 
3480b94ba42SJung-uk Kim /*
3490b94ba42SJung-uk Kim  * dbnames - namespace commands
3500b94ba42SJung-uk Kim  */
3510b94ba42SJung-uk Kim void
3520b94ba42SJung-uk Kim AcpiDbSetScope (
3530b94ba42SJung-uk Kim     char                    *Name);
3540b94ba42SJung-uk Kim 
3550b94ba42SJung-uk Kim void
3560b94ba42SJung-uk Kim AcpiDbDumpNamespace (
3570b94ba42SJung-uk Kim     char                    *StartArg,
3580b94ba42SJung-uk Kim     char                    *DepthArg);
3590b94ba42SJung-uk Kim 
3600b94ba42SJung-uk Kim void
36179c6d946SJung-uk Kim AcpiDbDumpNamespacePaths (
36279c6d946SJung-uk Kim     void);
36379c6d946SJung-uk Kim 
36479c6d946SJung-uk Kim void
3650b94ba42SJung-uk Kim AcpiDbDumpNamespaceByOwner (
3660b94ba42SJung-uk Kim     char                    *OwnerArg,
3670b94ba42SJung-uk Kim     char                    *DepthArg);
3680b94ba42SJung-uk Kim 
3690b94ba42SJung-uk Kim ACPI_STATUS
3700b94ba42SJung-uk Kim AcpiDbFindNameInNamespace (
3710b94ba42SJung-uk Kim     char                    *NameArg);
3720b94ba42SJung-uk Kim 
3730b94ba42SJung-uk Kim void
3740b94ba42SJung-uk Kim AcpiDbCheckPredefinedNames (
3750b94ba42SJung-uk Kim     void);
3760b94ba42SJung-uk Kim 
3770b94ba42SJung-uk Kim ACPI_STATUS
3780b94ba42SJung-uk Kim AcpiDbDisplayObjects (
3790b94ba42SJung-uk Kim     char                    *ObjTypeArg,
3800b94ba42SJung-uk Kim     char                    *DisplayCountArg);
3810b94ba42SJung-uk Kim 
3820b94ba42SJung-uk Kim void
3830b94ba42SJung-uk Kim AcpiDbCheckIntegrity (
3840b94ba42SJung-uk Kim     void);
3850b94ba42SJung-uk Kim 
3860b94ba42SJung-uk Kim void
3870b94ba42SJung-uk Kim AcpiDbFindReferences (
3880b94ba42SJung-uk Kim     char                    *ObjectArg);
3890b94ba42SJung-uk Kim 
3900b94ba42SJung-uk Kim void
3910b94ba42SJung-uk Kim AcpiDbGetBusInfo (
3920b94ba42SJung-uk Kim     void);
3930b94ba42SJung-uk Kim 
3940b94ba42SJung-uk Kim 
395a9f12690SJung-uk Kim /*
396a9f12690SJung-uk Kim  * dbdisply - debug display commands
397a9f12690SJung-uk Kim  */
398a9f12690SJung-uk Kim void
399a9f12690SJung-uk Kim AcpiDbDisplayMethodInfo (
400a9f12690SJung-uk Kim     ACPI_PARSE_OBJECT       *Op);
401a9f12690SJung-uk Kim 
402a9f12690SJung-uk Kim void
403a9f12690SJung-uk Kim AcpiDbDecodeAndDisplayObject (
404a9f12690SJung-uk Kim     char                    *Target,
405a9f12690SJung-uk Kim     char                    *OutputType);
406a9f12690SJung-uk Kim 
407f8146b88SJung-uk Kim ACPI_DBR_DEPENDENT_RETURN_VOID (
408a9f12690SJung-uk Kim void
409a9f12690SJung-uk Kim AcpiDbDisplayResultObject (
410a9f12690SJung-uk Kim     ACPI_OPERAND_OBJECT     *ObjDesc,
411f8146b88SJung-uk Kim     ACPI_WALK_STATE         *WalkState))
412a9f12690SJung-uk Kim 
413a9f12690SJung-uk Kim ACPI_STATUS
414a9f12690SJung-uk Kim AcpiDbDisplayAllMethods (
415a9f12690SJung-uk Kim     char                    *DisplayCountArg);
416a9f12690SJung-uk Kim 
417a9f12690SJung-uk Kim void
418a9f12690SJung-uk Kim AcpiDbDisplayArguments (
419a9f12690SJung-uk Kim     void);
420a9f12690SJung-uk Kim 
421a9f12690SJung-uk Kim void
422a9f12690SJung-uk Kim AcpiDbDisplayLocals (
423a9f12690SJung-uk Kim     void);
424a9f12690SJung-uk Kim 
425a9f12690SJung-uk Kim void
426a9f12690SJung-uk Kim AcpiDbDisplayResults (
427a9f12690SJung-uk Kim     void);
428a9f12690SJung-uk Kim 
429a9f12690SJung-uk Kim void
430a9f12690SJung-uk Kim AcpiDbDisplayCallingTree (
431a9f12690SJung-uk Kim     void);
432a9f12690SJung-uk Kim 
433a9f12690SJung-uk Kim void
434a9f12690SJung-uk Kim AcpiDbDisplayObjectType (
435a9f12690SJung-uk Kim     char                    *ObjectArg);
436a9f12690SJung-uk Kim 
437f8146b88SJung-uk Kim ACPI_DBR_DEPENDENT_RETURN_VOID (
438a9f12690SJung-uk Kim void
439a9f12690SJung-uk Kim AcpiDbDisplayArgumentObject (
440a9f12690SJung-uk Kim     ACPI_OPERAND_OBJECT     *ObjDesc,
441f8146b88SJung-uk Kim     ACPI_WALK_STATE         *WalkState))
442a9f12690SJung-uk Kim 
443d6dd1baeSJung-uk Kim 
444a9f12690SJung-uk Kim /*
445a9f12690SJung-uk Kim  * dbexec - debugger control method execution
446a9f12690SJung-uk Kim  */
447a9f12690SJung-uk Kim void
448a9f12690SJung-uk Kim AcpiDbExecute (
449a9f12690SJung-uk Kim     char                    *Name,
450a9f12690SJung-uk Kim     char                    **Args,
45142e58c03SJung-uk Kim     ACPI_OBJECT_TYPE        *Types,
452a9f12690SJung-uk Kim     UINT32                  Flags);
453a9f12690SJung-uk Kim 
454a9f12690SJung-uk Kim void
455*b7b7e711SJung-uk Kim AcpiDbCreateExecutionThread (
456*b7b7e711SJung-uk Kim     char                    *MethodNameArg,
457*b7b7e711SJung-uk Kim     char                    **Arguments,
458*b7b7e711SJung-uk Kim     ACPI_OBJECT_TYPE        *Types);
459*b7b7e711SJung-uk Kim 
460*b7b7e711SJung-uk Kim void
461a9f12690SJung-uk Kim AcpiDbCreateExecutionThreads (
462a9f12690SJung-uk Kim     char                    *NumThreadsArg,
463a9f12690SJung-uk Kim     char                    *NumLoopsArg,
464a9f12690SJung-uk Kim     char                    *MethodNameArg);
465a9f12690SJung-uk Kim 
466efcc2a30SJung-uk Kim void
467efcc2a30SJung-uk Kim AcpiDbDeleteObjects (
468efcc2a30SJung-uk Kim     UINT32                  Count,
469efcc2a30SJung-uk Kim     ACPI_OBJECT             *Objects);
470efcc2a30SJung-uk Kim 
471a9f12690SJung-uk Kim #ifdef ACPI_DBG_TRACK_ALLOCATIONS
472a9f12690SJung-uk Kim UINT32
473a9f12690SJung-uk Kim AcpiDbGetCacheInfo (
474a9f12690SJung-uk Kim     ACPI_MEMORY_LIST        *Cache);
475a9f12690SJung-uk Kim #endif
476a9f12690SJung-uk Kim 
477a9f12690SJung-uk Kim 
478a9f12690SJung-uk Kim /*
479a9f12690SJung-uk Kim  * dbfileio - Debugger file I/O commands
480a9f12690SJung-uk Kim  */
481a9f12690SJung-uk Kim ACPI_OBJECT_TYPE
482a9f12690SJung-uk Kim AcpiDbMatchArgument (
483a9f12690SJung-uk Kim     char                    *UserArgument,
484042ff955SJung-uk Kim     ACPI_DB_ARGUMENT_INFO   *Arguments);
485a9f12690SJung-uk Kim 
486a9f12690SJung-uk Kim void
487a9f12690SJung-uk Kim AcpiDbCloseDebugFile (
488a9f12690SJung-uk Kim     void);
489a9f12690SJung-uk Kim 
490a9f12690SJung-uk Kim void
491a9f12690SJung-uk Kim AcpiDbOpenDebugFile (
492a9f12690SJung-uk Kim     char                    *Name);
493a9f12690SJung-uk Kim 
494a9f12690SJung-uk Kim ACPI_STATUS
495a9f12690SJung-uk Kim AcpiDbLoadAcpiTable (
496a9f12690SJung-uk Kim     char                    *Filename);
497a9f12690SJung-uk Kim 
498a9f12690SJung-uk Kim ACPI_STATUS
499f8146b88SJung-uk Kim AcpiDbLoadTables (
500f8146b88SJung-uk Kim     ACPI_NEW_TABLE_DESC     *ListHead);
501a9f12690SJung-uk Kim 
502a9f12690SJung-uk Kim 
503a9f12690SJung-uk Kim /*
504a9f12690SJung-uk Kim  * dbhistry - debugger HISTORY command
505a9f12690SJung-uk Kim  */
506a9f12690SJung-uk Kim void
507a9f12690SJung-uk Kim AcpiDbAddToHistory (
508a9f12690SJung-uk Kim     char                    *CommandLine);
509a9f12690SJung-uk Kim 
510a9f12690SJung-uk Kim void
511a9f12690SJung-uk Kim AcpiDbDisplayHistory (
512a9f12690SJung-uk Kim     void);
513a9f12690SJung-uk Kim 
514a9f12690SJung-uk Kim char *
515a9f12690SJung-uk Kim AcpiDbGetFromHistory (
516a9f12690SJung-uk Kim     char                    *CommandNumArg);
517a9f12690SJung-uk Kim 
518313a0c13SJung-uk Kim char *
519313a0c13SJung-uk Kim AcpiDbGetHistoryByIndex (
520313a0c13SJung-uk Kim     UINT32                  CommanddNum);
521313a0c13SJung-uk Kim 
522a9f12690SJung-uk Kim 
523a9f12690SJung-uk Kim /*
524a9f12690SJung-uk Kim  * dbinput - user front-end to the AML debugger
525a9f12690SJung-uk Kim  */
526a9f12690SJung-uk Kim ACPI_STATUS
527a9f12690SJung-uk Kim AcpiDbCommandDispatch (
528a9f12690SJung-uk Kim     char                    *InputBuffer,
529a9f12690SJung-uk Kim     ACPI_WALK_STATE         *WalkState,
530a9f12690SJung-uk Kim     ACPI_PARSE_OBJECT       *Op);
531a9f12690SJung-uk Kim 
532a9f12690SJung-uk Kim void ACPI_SYSTEM_XFACE
533a9f12690SJung-uk Kim AcpiDbExecuteThread (
534a9f12690SJung-uk Kim     void                    *Context);
535a9f12690SJung-uk Kim 
536a9f12690SJung-uk Kim ACPI_STATUS
537a9f12690SJung-uk Kim AcpiDbUserCommands (
53828482948SJung-uk Kim     void);
539a9f12690SJung-uk Kim 
54042e58c03SJung-uk Kim char *
54142e58c03SJung-uk Kim AcpiDbGetNextToken (
54242e58c03SJung-uk Kim     char                    *String,
54342e58c03SJung-uk Kim     char                    **Next,
54442e58c03SJung-uk Kim     ACPI_OBJECT_TYPE        *ReturnType);
54542e58c03SJung-uk Kim 
546a9f12690SJung-uk Kim 
547a9f12690SJung-uk Kim /*
548fe0f0bbbSJung-uk Kim  * dbobject
549fe0f0bbbSJung-uk Kim  */
550fe0f0bbbSJung-uk Kim void
551fe0f0bbbSJung-uk Kim AcpiDbDecodeInternalObject (
552fe0f0bbbSJung-uk Kim     ACPI_OPERAND_OBJECT     *ObjDesc);
553fe0f0bbbSJung-uk Kim 
554fe0f0bbbSJung-uk Kim void
555fe0f0bbbSJung-uk Kim AcpiDbDisplayInternalObject (
556fe0f0bbbSJung-uk Kim     ACPI_OPERAND_OBJECT     *ObjDesc,
557fe0f0bbbSJung-uk Kim     ACPI_WALK_STATE         *WalkState);
558fe0f0bbbSJung-uk Kim 
559fe0f0bbbSJung-uk Kim void
560fe0f0bbbSJung-uk Kim AcpiDbDecodeArguments (
561fe0f0bbbSJung-uk Kim     ACPI_WALK_STATE         *WalkState);
562fe0f0bbbSJung-uk Kim 
563fe0f0bbbSJung-uk Kim void
564fe0f0bbbSJung-uk Kim AcpiDbDecodeLocals (
565fe0f0bbbSJung-uk Kim     ACPI_WALK_STATE         *WalkState);
566fe0f0bbbSJung-uk Kim 
567fe0f0bbbSJung-uk Kim void
568fe0f0bbbSJung-uk Kim AcpiDbDumpMethodInfo (
569fe0f0bbbSJung-uk Kim     ACPI_STATUS             Status,
570fe0f0bbbSJung-uk Kim     ACPI_WALK_STATE         *WalkState);
571fe0f0bbbSJung-uk Kim 
572fe0f0bbbSJung-uk Kim 
573fe0f0bbbSJung-uk Kim /*
574a9f12690SJung-uk Kim  * dbstats - Generation and display of ACPI table statistics
575a9f12690SJung-uk Kim  */
576a9f12690SJung-uk Kim void
577a9f12690SJung-uk Kim AcpiDbGenerateStatistics (
578a9f12690SJung-uk Kim     ACPI_PARSE_OBJECT       *Root,
579a9f12690SJung-uk Kim     BOOLEAN                 IsMethod);
580a9f12690SJung-uk Kim 
581a9f12690SJung-uk Kim ACPI_STATUS
582a9f12690SJung-uk Kim AcpiDbDisplayStatistics (
583a9f12690SJung-uk Kim     char                    *TypeArg);
584a9f12690SJung-uk Kim 
585a9f12690SJung-uk Kim 
586a9f12690SJung-uk Kim /*
587a9f12690SJung-uk Kim  * dbutils - AML debugger utilities
588a9f12690SJung-uk Kim  */
589a9f12690SJung-uk Kim void
590a9f12690SJung-uk Kim AcpiDbSetOutputDestination (
591a9f12690SJung-uk Kim     UINT32                  Where);
592a9f12690SJung-uk Kim 
593a9f12690SJung-uk Kim void
594a9f12690SJung-uk Kim AcpiDbDumpExternalObject (
595a9f12690SJung-uk Kim     ACPI_OBJECT             *ObjDesc,
596a9f12690SJung-uk Kim     UINT32                  Level);
597a9f12690SJung-uk Kim 
598a9f12690SJung-uk Kim void
599a9f12690SJung-uk Kim AcpiDbPrepNamestring (
600a9f12690SJung-uk Kim     char                    *Name);
601a9f12690SJung-uk Kim 
602a9f12690SJung-uk Kim ACPI_NAMESPACE_NODE *
603a9f12690SJung-uk Kim AcpiDbLocalNsLookup (
604a9f12690SJung-uk Kim     char                    *Name);
605a9f12690SJung-uk Kim 
606a9f12690SJung-uk Kim void
607f38b0f21SJung-uk Kim AcpiDbUint32ToHexString (
608a9f12690SJung-uk Kim     UINT32                  Value,
609a9f12690SJung-uk Kim     char                    *Buffer);
610a9f12690SJung-uk Kim 
611a9f12690SJung-uk Kim #endif  /* __ACDEBUG_H__ */
612