xref: /haiku/src/add-ons/kernel/bus_managers/acpi/acpica/include/acdisasm.h (revision e53f0019b57484c9fe0b24371d9c8520b52af57d)
1 /******************************************************************************
2  *
3  * Name: acdisasm.h - AML disassembler
4  *
5  *****************************************************************************/
6 
7 /******************************************************************************
8  *
9  * 1. Copyright Notice
10  *
11  * Some or all of this work - Copyright (c) 1999 - 2012, 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 #ifndef __ACDISASM_H__
117 #define __ACDISASM_H__
118 
119 #include "amlresrc.h"
120 
121 
122 #define BLOCK_NONE              0
123 #define BLOCK_PAREN             1
124 #define BLOCK_BRACE             2
125 #define BLOCK_COMMA_LIST        4
126 #define ACPI_DEFAULT_RESNAME    *(UINT32 *) "__RD"
127 
128 /*
129  * Raw table data header. Used by disassembler and data table compiler.
130  * Do not change.
131  */
132 #define ACPI_RAW_TABLE_DATA_HEADER      "Raw Table Data"
133 
134 
135 typedef const struct acpi_dmtable_info
136 {
137     UINT8                       Opcode;
138     UINT16                      Offset;
139     char                        *Name;
140     UINT8                       Flags;
141 
142 } ACPI_DMTABLE_INFO;
143 
144 #define DT_LENGTH                       0x01    /* Field is a subtable length */
145 #define DT_FLAG                         0x02    /* Field is a flag value */
146 #define DT_NON_ZERO                     0x04    /* Field must be non-zero */
147 
148 /* TBD: Not used at this time */
149 
150 #define DT_OPTIONAL                     0x08
151 #define DT_COUNT                        0x10
152 
153 /*
154  * Values for Opcode above.
155  * Note: 0-7 must not change, they are used as a flag shift value. Other
156  * than those, new values can be added wherever appropriate.
157  */
158 typedef enum
159 {
160     /* Simple Data Types */
161 
162     ACPI_DMT_FLAG0          = 0,
163     ACPI_DMT_FLAG1          = 1,
164     ACPI_DMT_FLAG2          = 2,
165     ACPI_DMT_FLAG3          = 3,
166     ACPI_DMT_FLAG4          = 4,
167     ACPI_DMT_FLAG5          = 5,
168     ACPI_DMT_FLAG6          = 6,
169     ACPI_DMT_FLAG7          = 7,
170     ACPI_DMT_FLAGS0,
171     ACPI_DMT_FLAGS1,
172     ACPI_DMT_FLAGS2,
173     ACPI_DMT_FLAGS4,
174     ACPI_DMT_UINT8,
175     ACPI_DMT_UINT16,
176     ACPI_DMT_UINT24,
177     ACPI_DMT_UINT32,
178     ACPI_DMT_UINT40,
179     ACPI_DMT_UINT48,
180     ACPI_DMT_UINT56,
181     ACPI_DMT_UINT64,
182     ACPI_DMT_BUF7,
183     ACPI_DMT_BUF16,
184     ACPI_DMT_BUF128,
185     ACPI_DMT_SIG,
186     ACPI_DMT_STRING,
187     ACPI_DMT_NAME4,
188     ACPI_DMT_NAME6,
189     ACPI_DMT_NAME8,
190 
191     /* Types that are decoded to strings and miscellaneous */
192 
193     ACPI_DMT_ACCWIDTH,
194     ACPI_DMT_CHKSUM,
195     ACPI_DMT_GAS,
196     ACPI_DMT_SPACEID,
197     ACPI_DMT_UNICODE,
198     ACPI_DMT_UUID,
199 
200     /* Types used only for the Data Table Compiler */
201 
202     ACPI_DMT_BUFFER,
203     ACPI_DMT_DEVICE_PATH,
204     ACPI_DMT_LABEL,
205     ACPI_DMT_PCI_PATH,
206 
207     /* Types that are specific to particular ACPI tables */
208 
209     ACPI_DMT_ASF,
210     ACPI_DMT_DMAR,
211     ACPI_DMT_EINJACT,
212     ACPI_DMT_EINJINST,
213     ACPI_DMT_ERSTACT,
214     ACPI_DMT_ERSTINST,
215     ACPI_DMT_FADTPM,
216     ACPI_DMT_HEST,
217     ACPI_DMT_HESTNTFY,
218     ACPI_DMT_HESTNTYP,
219     ACPI_DMT_IVRS,
220     ACPI_DMT_MADT,
221     ACPI_DMT_PMTT,
222     ACPI_DMT_SLIC,
223     ACPI_DMT_SRAT,
224 
225     /* Special opcodes */
226 
227     ACPI_DMT_EXTRA_TEXT,
228     ACPI_DMT_EXIT
229 
230 } ACPI_ENTRY_TYPES;
231 
232 typedef
233 void (*ACPI_DMTABLE_HANDLER) (
234     ACPI_TABLE_HEADER       *Table);
235 
236 typedef
237 ACPI_STATUS (*ACPI_CMTABLE_HANDLER) (
238     void                    **PFieldList);
239 
240 typedef struct acpi_dmtable_data
241 {
242     char                    *Signature;
243     ACPI_DMTABLE_INFO       *TableInfo;
244     ACPI_DMTABLE_HANDLER    TableHandler;
245     ACPI_CMTABLE_HANDLER    CmTableHandler;
246     const unsigned char     *Template;
247     char                    *Name;
248 
249 } ACPI_DMTABLE_DATA;
250 
251 
252 typedef struct acpi_op_walk_info
253 {
254     UINT32                  Level;
255     UINT32                  LastLevel;
256     UINT32                  Count;
257     UINT32                  BitOffset;
258     UINT32                  Flags;
259     ACPI_WALK_STATE         *WalkState;
260 
261 } ACPI_OP_WALK_INFO;
262 
263 /*
264  * TBD - another copy of this is in asltypes.h, fix
265  */
266 #ifndef ASL_WALK_CALLBACK_DEFINED
267 typedef
268 ACPI_STATUS (*ASL_WALK_CALLBACK) (
269     ACPI_PARSE_OBJECT           *Op,
270     UINT32                      Level,
271     void                        *Context);
272 #define ASL_WALK_CALLBACK_DEFINED
273 #endif
274 
275 typedef
276 void (*ACPI_RESOURCE_HANDLER) (
277     AML_RESOURCE            *Resource,
278     UINT32                  Length,
279     UINT32                  Level);
280 
281 typedef struct acpi_resource_tag
282 {
283     UINT32                  BitIndex;
284     char                    *Tag;
285 
286 } ACPI_RESOURCE_TAG;
287 
288 /* Strings used for decoding flags to ASL keywords */
289 
290 extern const char               *AcpiGbl_WordDecode[];
291 extern const char               *AcpiGbl_IrqDecode[];
292 extern const char               *AcpiGbl_LockRule[];
293 extern const char               *AcpiGbl_AccessTypes[];
294 extern const char               *AcpiGbl_UpdateRules[];
295 extern const char               *AcpiGbl_MatchOps[];
296 
297 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoAsf0[];
298 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoAsf1[];
299 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoAsf1a[];
300 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoAsf2[];
301 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoAsf2a[];
302 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoAsf3[];
303 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoAsf4[];
304 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoAsfHdr[];
305 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoBoot[];
306 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoBert[];
307 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoBgrt[];
308 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoCpep[];
309 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoCpep0[];
310 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoDbgp[];
311 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoDmar[];
312 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoDmarHdr[];
313 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoDmarScope[];
314 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoDmar0[];
315 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoDmar1[];
316 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoDmar2[];
317 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoDmar3[];
318 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoDrtm[];
319 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoEcdt[];
320 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoEinj[];
321 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoEinj0[];
322 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoErst[];
323 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoErst0[];
324 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoFacs[];
325 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoFadt1[];
326 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoFadt2[];
327 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoFadt3[];
328 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoFadt5[];
329 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoFpdt[];
330 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoFpdtHdr[];
331 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoFpdt0[];
332 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoFpdt1[];
333 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoGas[];
334 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoGtdt[];
335 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHeader[];
336 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHest[];
337 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHest0[];
338 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHest1[];
339 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHest2[];
340 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHest6[];
341 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHest7[];
342 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHest8[];
343 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHest9[];
344 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHestNotify[];
345 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHestBank[];
346 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHpet[];
347 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoIvrs[];
348 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoIvrs0[];
349 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoIvrs1[];
350 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoIvrs4[];
351 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoIvrs8a[];
352 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoIvrs8b[];
353 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoIvrs8c[];
354 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoIvrsHdr[];
355 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt[];
356 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt0[];
357 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt1[];
358 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt2[];
359 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt3[];
360 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt4[];
361 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt5[];
362 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt6[];
363 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt7[];
364 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt8[];
365 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt9[];
366 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt10[];
367 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt11[];
368 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt12[];
369 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadtHdr[];
370 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMcfg[];
371 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMcfg0[];
372 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMchi[];
373 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMpst[];
374 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMpst0[];
375 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMpst0A[];
376 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMpst0B[];
377 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMpst1[];
378 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMpst2[];
379 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMsct[];
380 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMsct0[];
381 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoPmtt[];
382 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoPmtt0[];
383 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoPmtt1[];
384 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoPmtt1a[];
385 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoPmtt2[];
386 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoPmttHdr[];
387 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoPcct[];
388 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoPcct0[];
389 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoRsdp1[];
390 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoRsdp2[];
391 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoS3pt[];
392 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoS3ptHdr[];
393 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoS3pt0[];
394 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoS3pt1[];
395 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoSbst[];
396 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoSlicHdr[];
397 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoSlic0[];
398 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoSlic1[];
399 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoSlit[];
400 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoSpcr[];
401 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoSpmi[];
402 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoSrat[];
403 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoSratHdr[];
404 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoSrat0[];
405 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoSrat1[];
406 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoSrat2[];
407 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoTcpa[];
408 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoUefi[];
409 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoWaet[];
410 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoWdat[];
411 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoWdat0[];
412 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoWddt[];
413 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoWdrt[];
414 
415 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoGeneric[][2];
416 
417 
418 /*
419  * dmtable
420  */
421 extern ACPI_DMTABLE_DATA        AcpiDmTableData[];
422 
423 UINT8
424 AcpiDmGenerateChecksum (
425     void                    *Table,
426     UINT32                  Length,
427     UINT8                   OriginalChecksum);
428 
429 ACPI_DMTABLE_DATA *
430 AcpiDmGetTableData (
431     char                    *Signature);
432 
433 void
434 AcpiDmDumpDataTable (
435     ACPI_TABLE_HEADER       *Table);
436 
437 ACPI_STATUS
438 AcpiDmDumpTable (
439     UINT32                  TableLength,
440     UINT32                  TableOffset,
441     void                    *Table,
442     UINT32                  SubTableLength,
443     ACPI_DMTABLE_INFO        *Info);
444 
445 void
446 AcpiDmLineHeader (
447     UINT32                  Offset,
448     UINT32                  ByteLength,
449     char                    *Name);
450 
451 void
452 AcpiDmLineHeader2 (
453     UINT32                  Offset,
454     UINT32                  ByteLength,
455     char                    *Name,
456     UINT32                  Value);
457 
458 
459 /*
460  * dmtbdump
461  */
462 void
463 AcpiDmDumpAsf (
464     ACPI_TABLE_HEADER       *Table);
465 
466 void
467 AcpiDmDumpCpep (
468     ACPI_TABLE_HEADER       *Table);
469 
470 void
471 AcpiDmDumpDmar (
472     ACPI_TABLE_HEADER       *Table);
473 
474 void
475 AcpiDmDumpEinj (
476     ACPI_TABLE_HEADER       *Table);
477 
478 void
479 AcpiDmDumpErst (
480     ACPI_TABLE_HEADER       *Table);
481 
482 void
483 AcpiDmDumpFadt (
484     ACPI_TABLE_HEADER       *Table);
485 
486 void
487 AcpiDmDumpFpdt (
488     ACPI_TABLE_HEADER       *Table);
489 
490 void
491 AcpiDmDumpHest (
492     ACPI_TABLE_HEADER       *Table);
493 
494 void
495 AcpiDmDumpIvrs (
496     ACPI_TABLE_HEADER       *Table);
497 
498 void
499 AcpiDmDumpMadt (
500     ACPI_TABLE_HEADER       *Table);
501 
502 void
503 AcpiDmDumpMcfg (
504     ACPI_TABLE_HEADER       *Table);
505 
506 void
507 AcpiDmDumpMpst (
508     ACPI_TABLE_HEADER       *Table);
509 
510 void
511 AcpiDmDumpMsct (
512     ACPI_TABLE_HEADER       *Table);
513 
514 void
515 AcpiDmDumpPcct (
516     ACPI_TABLE_HEADER       *Table);
517 
518 void
519 AcpiDmDumpPmtt (
520     ACPI_TABLE_HEADER       *Table);
521 
522 UINT32
523 AcpiDmDumpRsdp (
524     ACPI_TABLE_HEADER       *Table);
525 
526 void
527 AcpiDmDumpRsdt (
528     ACPI_TABLE_HEADER       *Table);
529 
530 UINT32
531 AcpiDmDumpS3pt (
532     ACPI_TABLE_HEADER       *Table);
533 
534 void
535 AcpiDmDumpSlic (
536     ACPI_TABLE_HEADER       *Table);
537 
538 void
539 AcpiDmDumpSlit (
540     ACPI_TABLE_HEADER       *Table);
541 
542 void
543 AcpiDmDumpSrat (
544     ACPI_TABLE_HEADER       *Table);
545 
546 void
547 AcpiDmDumpWdat (
548     ACPI_TABLE_HEADER       *Table);
549 
550 void
551 AcpiDmDumpXsdt (
552     ACPI_TABLE_HEADER       *Table);
553 
554 
555 /*
556  * dmwalk
557  */
558 void
559 AcpiDmDisassemble (
560     ACPI_WALK_STATE         *WalkState,
561     ACPI_PARSE_OBJECT       *Origin,
562     UINT32                  NumOpcodes);
563 
564 void
565 AcpiDmWalkParseTree (
566     ACPI_PARSE_OBJECT       *Op,
567     ASL_WALK_CALLBACK       DescendingCallback,
568     ASL_WALK_CALLBACK       AscendingCallback,
569     void                    *Context);
570 
571 
572 /*
573  * dmopcode
574  */
575 void
576 AcpiDmDisassembleOneOp (
577     ACPI_WALK_STATE         *WalkState,
578     ACPI_OP_WALK_INFO       *Info,
579     ACPI_PARSE_OBJECT       *Op);
580 
581 void
582 AcpiDmDecodeInternalObject (
583     ACPI_OPERAND_OBJECT     *ObjDesc);
584 
585 UINT32
586 AcpiDmListType (
587     ACPI_PARSE_OBJECT       *Op);
588 
589 void
590 AcpiDmMethodFlags (
591     ACPI_PARSE_OBJECT       *Op);
592 
593 void
594 AcpiDmPredefinedDescription (
595     ACPI_PARSE_OBJECT       *Op);
596 
597 void
598 AcpiDmFieldPredefinedDescription (
599     ACPI_PARSE_OBJECT       *Op);
600 
601 void
602 AcpiDmFieldFlags (
603     ACPI_PARSE_OBJECT       *Op);
604 
605 void
606 AcpiDmAddressSpace (
607     UINT8                   SpaceId);
608 
609 void
610 AcpiDmRegionFlags (
611     ACPI_PARSE_OBJECT       *Op);
612 
613 void
614 AcpiDmMatchOp (
615     ACPI_PARSE_OBJECT       *Op);
616 
617 
618 /*
619  * dmnames
620  */
621 UINT32
622 AcpiDmDumpName (
623     UINT32                  Name);
624 
625 ACPI_STATUS
626 AcpiPsDisplayObjectPathname (
627     ACPI_WALK_STATE         *WalkState,
628     ACPI_PARSE_OBJECT       *Op);
629 
630 void
631 AcpiDmNamestring (
632     char                    *Name);
633 
634 
635 /*
636  * dmobject
637  */
638 void
639 AcpiDmDisplayInternalObject (
640     ACPI_OPERAND_OBJECT     *ObjDesc,
641     ACPI_WALK_STATE         *WalkState);
642 
643 void
644 AcpiDmDisplayArguments (
645     ACPI_WALK_STATE         *WalkState);
646 
647 void
648 AcpiDmDisplayLocals (
649     ACPI_WALK_STATE         *WalkState);
650 
651 void
652 AcpiDmDumpMethodInfo (
653     ACPI_STATUS             Status,
654     ACPI_WALK_STATE         *WalkState,
655     ACPI_PARSE_OBJECT       *Op);
656 
657 
658 /*
659  * dmbuffer
660  */
661 void
662 AcpiDmDisasmByteList (
663     UINT32                  Level,
664     UINT8                   *ByteData,
665     UINT32                  ByteCount);
666 
667 void
668 AcpiDmByteList (
669     ACPI_OP_WALK_INFO       *Info,
670     ACPI_PARSE_OBJECT       *Op);
671 
672 void
673 AcpiDmIsEisaId (
674     ACPI_PARSE_OBJECT       *Op);
675 
676 void
677 AcpiDmEisaId (
678     UINT32                  EncodedId);
679 
680 BOOLEAN
681 AcpiDmIsUnicodeBuffer (
682     ACPI_PARSE_OBJECT       *Op);
683 
684 BOOLEAN
685 AcpiDmIsStringBuffer (
686     ACPI_PARSE_OBJECT       *Op);
687 
688 
689 /*
690  * dmextern
691  */
692 
693 ACPI_STATUS
694 AcpiDmAddToExternalFileList (
695     char                    *PathList);
696 
697 void
698 AcpiDmClearExternalFileList (
699     void);
700 
701 void
702 AcpiDmAddToExternalList (
703     ACPI_PARSE_OBJECT       *Op,
704     char                    *Path,
705     UINT8                   Type,
706     UINT32                  Value);
707 
708 void
709 AcpiDmAddExternalsToNamespace (
710     void);
711 
712 UINT32
713 AcpiDmGetExternalMethodCount (
714     void);
715 
716 void
717 AcpiDmClearExternalList (
718     void);
719 
720 void
721 AcpiDmEmitExternals (
722     void);
723 
724 
725 /*
726  * dmresrc
727  */
728 void
729 AcpiDmDumpInteger8 (
730     UINT8                   Value,
731     char                    *Name);
732 
733 void
734 AcpiDmDumpInteger16 (
735     UINT16                  Value,
736     char                    *Name);
737 
738 void
739 AcpiDmDumpInteger32 (
740     UINT32                  Value,
741     char                    *Name);
742 
743 void
744 AcpiDmDumpInteger64 (
745     UINT64                  Value,
746     char                    *Name);
747 
748 void
749 AcpiDmResourceTemplate (
750     ACPI_OP_WALK_INFO       *Info,
751     ACPI_PARSE_OBJECT       *Op,
752     UINT8                   *ByteData,
753     UINT32                  ByteCount);
754 
755 ACPI_STATUS
756 AcpiDmIsResourceTemplate (
757     ACPI_PARSE_OBJECT       *Op);
758 
759 void
760 AcpiDmBitList (
761     UINT16                  Mask);
762 
763 void
764 AcpiDmDescriptorName (
765     void);
766 
767 
768 /*
769  * dmresrcl
770  */
771 void
772 AcpiDmWordDescriptor (
773     AML_RESOURCE            *Resource,
774     UINT32                  Length,
775     UINT32                  Level);
776 
777 void
778 AcpiDmDwordDescriptor (
779     AML_RESOURCE            *Resource,
780     UINT32                  Length,
781     UINT32                  Level);
782 
783 void
784 AcpiDmExtendedDescriptor (
785     AML_RESOURCE            *Resource,
786     UINT32                  Length,
787     UINT32                  Level);
788 
789 void
790 AcpiDmQwordDescriptor (
791     AML_RESOURCE            *Resource,
792     UINT32                  Length,
793     UINT32                  Level);
794 
795 void
796 AcpiDmMemory24Descriptor (
797     AML_RESOURCE            *Resource,
798     UINT32                  Length,
799     UINT32                  Level);
800 
801 void
802 AcpiDmMemory32Descriptor (
803     AML_RESOURCE            *Resource,
804     UINT32                  Length,
805     UINT32                  Level);
806 
807 void
808 AcpiDmFixedMemory32Descriptor (
809     AML_RESOURCE            *Resource,
810     UINT32                  Length,
811     UINT32                  Level);
812 
813 void
814 AcpiDmGenericRegisterDescriptor (
815     AML_RESOURCE            *Resource,
816     UINT32                  Length,
817     UINT32                  Level);
818 
819 void
820 AcpiDmInterruptDescriptor (
821     AML_RESOURCE            *Resource,
822     UINT32                  Length,
823     UINT32                  Level);
824 
825 void
826 AcpiDmVendorLargeDescriptor (
827     AML_RESOURCE            *Resource,
828     UINT32                  Length,
829     UINT32                  Level);
830 
831 void
832 AcpiDmGpioDescriptor (
833     AML_RESOURCE            *Resource,
834     UINT32                  Length,
835     UINT32                  Level);
836 
837 void
838 AcpiDmSerialBusDescriptor (
839     AML_RESOURCE            *Resource,
840     UINT32                  Length,
841     UINT32                  Level);
842 
843 void
844 AcpiDmVendorCommon (
845     char                    *Name,
846     UINT8                   *ByteData,
847     UINT32                  Length,
848     UINT32                  Level);
849 
850 
851 /*
852  * dmresrcs
853  */
854 void
855 AcpiDmIrqDescriptor (
856     AML_RESOURCE            *Resource,
857     UINT32                  Length,
858     UINT32                  Level);
859 
860 void
861 AcpiDmDmaDescriptor (
862     AML_RESOURCE            *Resource,
863     UINT32                  Length,
864     UINT32                  Level);
865 
866 void
867 AcpiDmFixedDmaDescriptor (
868     AML_RESOURCE            *Resource,
869     UINT32                  Length,
870     UINT32                  Level);
871 
872 void
873 AcpiDmIoDescriptor (
874     AML_RESOURCE            *Resource,
875     UINT32                  Length,
876     UINT32                  Level);
877 
878 void
879 AcpiDmFixedIoDescriptor (
880     AML_RESOURCE            *Resource,
881     UINT32                  Length,
882     UINT32                  Level);
883 
884 void
885 AcpiDmStartDependentDescriptor (
886     AML_RESOURCE            *Resource,
887     UINT32                  Length,
888     UINT32                  Level);
889 
890 void
891 AcpiDmEndDependentDescriptor (
892     AML_RESOURCE            *Resource,
893     UINT32                  Length,
894     UINT32                  Level);
895 
896 void
897 AcpiDmVendorSmallDescriptor (
898     AML_RESOURCE            *Resource,
899     UINT32                  Length,
900     UINT32                  Level);
901 
902 
903 /*
904  * dmutils
905  */
906 void
907 AcpiDmDecodeAttribute (
908     UINT8                   Attribute);
909 
910 void
911 AcpiDmIndent (
912     UINT32                  Level);
913 
914 BOOLEAN
915 AcpiDmCommaIfListMember (
916     ACPI_PARSE_OBJECT       *Op);
917 
918 void
919 AcpiDmCommaIfFieldMember (
920     ACPI_PARSE_OBJECT       *Op);
921 
922 
923 /*
924  * dmrestag
925  */
926 void
927 AcpiDmFindResources (
928     ACPI_PARSE_OBJECT       *Root);
929 
930 void
931 AcpiDmCheckResourceReference (
932     ACPI_PARSE_OBJECT       *Op,
933     ACPI_WALK_STATE         *WalkState);
934 
935 
936 /*
937  * acdisasm
938  */
939 void
940 AdDisassemblerHeader (
941     char                    *Filename);
942 
943 
944 #endif  /* __ACDISASM_H__ */
945