xref: /freebsd/sys/contrib/dev/acpica/include/acdisasm.h (revision 9a14aa017b21c292740c00ee098195cd46642730)
1 /******************************************************************************
2  *
3  * Name: acdisasm.h - AML disassembler
4  *
5  *****************************************************************************/
6 
7 /*
8  * Copyright (C) 2000 - 2012, Intel Corp.
9  * All rights reserved.
10  *
11  * Redistribution and use in source and binary forms, with or without
12  * modification, are permitted provided that the following conditions
13  * are met:
14  * 1. Redistributions of source code must retain the above copyright
15  *    notice, this list of conditions, and the following disclaimer,
16  *    without modification.
17  * 2. Redistributions in binary form must reproduce at minimum a disclaimer
18  *    substantially similar to the "NO WARRANTY" disclaimer below
19  *    ("Disclaimer") and any redistribution must be conditioned upon
20  *    including a substantially similar Disclaimer requirement for further
21  *    binary redistribution.
22  * 3. Neither the names of the above-listed copyright holders nor the names
23  *    of any contributors may be used to endorse or promote products derived
24  *    from this software without specific prior written permission.
25  *
26  * Alternatively, this software may be distributed under the terms of the
27  * GNU General Public License ("GPL") version 2 as published by the Free
28  * Software Foundation.
29  *
30  * NO WARRANTY
31  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
32  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
33  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR
34  * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
35  * HOLDERS OR CONTRIBUTORS BE LIABLE FOR SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
36  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
37  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
38  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
39  * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
40  * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
41  * POSSIBILITY OF SUCH DAMAGES.
42  */
43 
44 #ifndef __ACDISASM_H__
45 #define __ACDISASM_H__
46 
47 #include <contrib/dev/acpica/include/amlresrc.h>
48 
49 
50 #define BLOCK_NONE              0
51 #define BLOCK_PAREN             1
52 #define BLOCK_BRACE             2
53 #define BLOCK_COMMA_LIST        4
54 #define ACPI_DEFAULT_RESNAME    *(UINT32 *) "__RD"
55 
56 /*
57  * Raw table data header. Used by disassembler and data table compiler.
58  * Do not change.
59  */
60 #define ACPI_RAW_TABLE_DATA_HEADER      "Raw Table Data"
61 
62 
63 typedef const struct acpi_dmtable_info
64 {
65     UINT8                       Opcode;
66     UINT16                      Offset;
67     char                        *Name;
68     UINT8                       Flags;
69 
70 } ACPI_DMTABLE_INFO;
71 
72 #define DT_LENGTH                       0x01    /* Field is a subtable length */
73 #define DT_FLAG                         0x02    /* Field is a flag value */
74 #define DT_NON_ZERO                     0x04    /* Field must be non-zero */
75 
76 /* TBD: Not used at this time */
77 
78 #define DT_OPTIONAL                     0x08
79 #define DT_COUNT                        0x10
80 
81 /*
82  * Values for Opcode above.
83  * Note: 0-7 must not change, they are used as a flag shift value. Other
84  * than those, new values can be added wherever appropriate.
85  */
86 typedef enum
87 {
88     /* Simple Data Types */
89 
90     ACPI_DMT_FLAG0          = 0,
91     ACPI_DMT_FLAG1          = 1,
92     ACPI_DMT_FLAG2          = 2,
93     ACPI_DMT_FLAG3          = 3,
94     ACPI_DMT_FLAG4          = 4,
95     ACPI_DMT_FLAG5          = 5,
96     ACPI_DMT_FLAG6          = 6,
97     ACPI_DMT_FLAG7          = 7,
98     ACPI_DMT_FLAGS0,
99     ACPI_DMT_FLAGS1,
100     ACPI_DMT_FLAGS2,
101     ACPI_DMT_FLAGS4,
102     ACPI_DMT_UINT8,
103     ACPI_DMT_UINT16,
104     ACPI_DMT_UINT24,
105     ACPI_DMT_UINT32,
106     ACPI_DMT_UINT40,
107     ACPI_DMT_UINT48,
108     ACPI_DMT_UINT56,
109     ACPI_DMT_UINT64,
110     ACPI_DMT_BUF7,
111     ACPI_DMT_BUF16,
112     ACPI_DMT_BUF128,
113     ACPI_DMT_SIG,
114     ACPI_DMT_STRING,
115     ACPI_DMT_NAME4,
116     ACPI_DMT_NAME6,
117     ACPI_DMT_NAME8,
118 
119     /* Types that are decoded to strings and miscellaneous */
120 
121     ACPI_DMT_ACCWIDTH,
122     ACPI_DMT_CHKSUM,
123     ACPI_DMT_GAS,
124     ACPI_DMT_SPACEID,
125     ACPI_DMT_UNICODE,
126     ACPI_DMT_UUID,
127 
128     /* Types used only for the Data Table Compiler */
129 
130     ACPI_DMT_BUFFER,
131     ACPI_DMT_DEVICE_PATH,
132     ACPI_DMT_LABEL,
133     ACPI_DMT_PCI_PATH,
134 
135     /* Types that are specific to particular ACPI tables */
136 
137     ACPI_DMT_ASF,
138     ACPI_DMT_DMAR,
139     ACPI_DMT_EINJACT,
140     ACPI_DMT_EINJINST,
141     ACPI_DMT_ERSTACT,
142     ACPI_DMT_ERSTINST,
143     ACPI_DMT_FADTPM,
144     ACPI_DMT_HEST,
145     ACPI_DMT_HESTNTFY,
146     ACPI_DMT_HESTNTYP,
147     ACPI_DMT_IVRS,
148     ACPI_DMT_MADT,
149     ACPI_DMT_PMTT,
150     ACPI_DMT_SLIC,
151     ACPI_DMT_SRAT,
152 
153     /* Special opcodes */
154 
155     ACPI_DMT_EXTRA_TEXT,
156     ACPI_DMT_EXIT
157 
158 } ACPI_ENTRY_TYPES;
159 
160 typedef
161 void (*ACPI_DMTABLE_HANDLER) (
162     ACPI_TABLE_HEADER       *Table);
163 
164 typedef
165 ACPI_STATUS (*ACPI_CMTABLE_HANDLER) (
166     void                    **PFieldList);
167 
168 typedef struct acpi_dmtable_data
169 {
170     char                    *Signature;
171     ACPI_DMTABLE_INFO       *TableInfo;
172     ACPI_DMTABLE_HANDLER    TableHandler;
173     ACPI_CMTABLE_HANDLER    CmTableHandler;
174     const unsigned char     *Template;
175     char                    *Name;
176 
177 } ACPI_DMTABLE_DATA;
178 
179 
180 typedef struct acpi_op_walk_info
181 {
182     UINT32                  Level;
183     UINT32                  LastLevel;
184     UINT32                  Count;
185     UINT32                  BitOffset;
186     UINT32                  Flags;
187     ACPI_WALK_STATE         *WalkState;
188 
189 } ACPI_OP_WALK_INFO;
190 
191 /*
192  * TBD - another copy of this is in asltypes.h, fix
193  */
194 #ifndef ASL_WALK_CALLBACK_DEFINED
195 typedef
196 ACPI_STATUS (*ASL_WALK_CALLBACK) (
197     ACPI_PARSE_OBJECT           *Op,
198     UINT32                      Level,
199     void                        *Context);
200 #define ASL_WALK_CALLBACK_DEFINED
201 #endif
202 
203 typedef
204 void (*ACPI_RESOURCE_HANDLER) (
205     AML_RESOURCE            *Resource,
206     UINT32                  Length,
207     UINT32                  Level);
208 
209 typedef struct acpi_resource_tag
210 {
211     UINT32                  BitIndex;
212     char                    *Tag;
213 
214 } ACPI_RESOURCE_TAG;
215 
216 /* Strings used for decoding flags to ASL keywords */
217 
218 extern const char               *AcpiGbl_WordDecode[];
219 extern const char               *AcpiGbl_IrqDecode[];
220 extern const char               *AcpiGbl_LockRule[];
221 extern const char               *AcpiGbl_AccessTypes[];
222 extern const char               *AcpiGbl_UpdateRules[];
223 extern const char               *AcpiGbl_MatchOps[];
224 
225 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoAsf0[];
226 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoAsf1[];
227 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoAsf1a[];
228 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoAsf2[];
229 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoAsf2a[];
230 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoAsf3[];
231 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoAsf4[];
232 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoAsfHdr[];
233 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoBoot[];
234 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoBert[];
235 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoBgrt[];
236 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoCpep[];
237 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoCpep0[];
238 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoDbgp[];
239 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoDmar[];
240 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoDmarHdr[];
241 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoDmarScope[];
242 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoDmar0[];
243 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoDmar1[];
244 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoDmar2[];
245 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoDmar3[];
246 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoDrtm[];
247 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoEcdt[];
248 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoEinj[];
249 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoEinj0[];
250 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoErst[];
251 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoErst0[];
252 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoFacs[];
253 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoFadt1[];
254 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoFadt2[];
255 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoFadt3[];
256 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoFadt5[];
257 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoFpdt[];
258 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoFpdtHdr[];
259 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoFpdt0[];
260 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoFpdt1[];
261 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoGas[];
262 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoGtdt[];
263 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHeader[];
264 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHest[];
265 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHest0[];
266 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHest1[];
267 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHest2[];
268 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHest6[];
269 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHest7[];
270 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHest8[];
271 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHest9[];
272 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHestNotify[];
273 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHestBank[];
274 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHpet[];
275 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoIvrs[];
276 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoIvrs0[];
277 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoIvrs1[];
278 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoIvrs4[];
279 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoIvrs8a[];
280 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoIvrs8b[];
281 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoIvrs8c[];
282 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoIvrsHdr[];
283 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt[];
284 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt0[];
285 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt1[];
286 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt2[];
287 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt3[];
288 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt4[];
289 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt5[];
290 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt6[];
291 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt7[];
292 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt8[];
293 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt9[];
294 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt10[];
295 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt11[];
296 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadt12[];
297 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMadtHdr[];
298 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMcfg[];
299 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMcfg0[];
300 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMchi[];
301 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMpst[];
302 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMpst0[];
303 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMpst0A[];
304 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMpst0B[];
305 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMpst1[];
306 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMpst2[];
307 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMsct[];
308 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoMsct0[];
309 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoPmtt[];
310 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoPmtt0[];
311 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoPmtt1[];
312 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoPmtt1a[];
313 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoPmtt2[];
314 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoPmttHdr[];
315 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoPcct[];
316 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoPcct0[];
317 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoRsdp1[];
318 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoRsdp2[];
319 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoS3pt[];
320 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoS3ptHdr[];
321 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoS3pt0[];
322 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoS3pt1[];
323 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoSbst[];
324 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoSlicHdr[];
325 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoSlic0[];
326 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoSlic1[];
327 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoSlit[];
328 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoSpcr[];
329 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoSpmi[];
330 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoSrat[];
331 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoSratHdr[];
332 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoSrat0[];
333 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoSrat1[];
334 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoSrat2[];
335 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoTcpa[];
336 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoUefi[];
337 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoWaet[];
338 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoWdat[];
339 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoWdat0[];
340 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoWddt[];
341 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoWdrt[];
342 
343 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoGeneric[][2];
344 
345 
346 /*
347  * dmtable
348  */
349 extern ACPI_DMTABLE_DATA        AcpiDmTableData[];
350 
351 UINT8
352 AcpiDmGenerateChecksum (
353     void                    *Table,
354     UINT32                  Length,
355     UINT8                   OriginalChecksum);
356 
357 ACPI_DMTABLE_DATA *
358 AcpiDmGetTableData (
359     char                    *Signature);
360 
361 void
362 AcpiDmDumpDataTable (
363     ACPI_TABLE_HEADER       *Table);
364 
365 ACPI_STATUS
366 AcpiDmDumpTable (
367     UINT32                  TableLength,
368     UINT32                  TableOffset,
369     void                    *Table,
370     UINT32                  SubTableLength,
371     ACPI_DMTABLE_INFO        *Info);
372 
373 void
374 AcpiDmLineHeader (
375     UINT32                  Offset,
376     UINT32                  ByteLength,
377     char                    *Name);
378 
379 void
380 AcpiDmLineHeader2 (
381     UINT32                  Offset,
382     UINT32                  ByteLength,
383     char                    *Name,
384     UINT32                  Value);
385 
386 
387 /*
388  * dmtbdump
389  */
390 void
391 AcpiDmDumpAsf (
392     ACPI_TABLE_HEADER       *Table);
393 
394 void
395 AcpiDmDumpCpep (
396     ACPI_TABLE_HEADER       *Table);
397 
398 void
399 AcpiDmDumpDmar (
400     ACPI_TABLE_HEADER       *Table);
401 
402 void
403 AcpiDmDumpEinj (
404     ACPI_TABLE_HEADER       *Table);
405 
406 void
407 AcpiDmDumpErst (
408     ACPI_TABLE_HEADER       *Table);
409 
410 void
411 AcpiDmDumpFadt (
412     ACPI_TABLE_HEADER       *Table);
413 
414 void
415 AcpiDmDumpFpdt (
416     ACPI_TABLE_HEADER       *Table);
417 
418 void
419 AcpiDmDumpHest (
420     ACPI_TABLE_HEADER       *Table);
421 
422 void
423 AcpiDmDumpIvrs (
424     ACPI_TABLE_HEADER       *Table);
425 
426 void
427 AcpiDmDumpMadt (
428     ACPI_TABLE_HEADER       *Table);
429 
430 void
431 AcpiDmDumpMcfg (
432     ACPI_TABLE_HEADER       *Table);
433 
434 void
435 AcpiDmDumpMpst (
436     ACPI_TABLE_HEADER       *Table);
437 
438 void
439 AcpiDmDumpMsct (
440     ACPI_TABLE_HEADER       *Table);
441 
442 void
443 AcpiDmDumpPcct (
444     ACPI_TABLE_HEADER       *Table);
445 
446 void
447 AcpiDmDumpPmtt (
448     ACPI_TABLE_HEADER       *Table);
449 
450 UINT32
451 AcpiDmDumpRsdp (
452     ACPI_TABLE_HEADER       *Table);
453 
454 void
455 AcpiDmDumpRsdt (
456     ACPI_TABLE_HEADER       *Table);
457 
458 UINT32
459 AcpiDmDumpS3pt (
460     ACPI_TABLE_HEADER       *Table);
461 
462 void
463 AcpiDmDumpSlic (
464     ACPI_TABLE_HEADER       *Table);
465 
466 void
467 AcpiDmDumpSlit (
468     ACPI_TABLE_HEADER       *Table);
469 
470 void
471 AcpiDmDumpSrat (
472     ACPI_TABLE_HEADER       *Table);
473 
474 void
475 AcpiDmDumpWdat (
476     ACPI_TABLE_HEADER       *Table);
477 
478 void
479 AcpiDmDumpXsdt (
480     ACPI_TABLE_HEADER       *Table);
481 
482 
483 /*
484  * dmwalk
485  */
486 void
487 AcpiDmDisassemble (
488     ACPI_WALK_STATE         *WalkState,
489     ACPI_PARSE_OBJECT       *Origin,
490     UINT32                  NumOpcodes);
491 
492 void
493 AcpiDmWalkParseTree (
494     ACPI_PARSE_OBJECT       *Op,
495     ASL_WALK_CALLBACK       DescendingCallback,
496     ASL_WALK_CALLBACK       AscendingCallback,
497     void                    *Context);
498 
499 
500 /*
501  * dmopcode
502  */
503 void
504 AcpiDmDisassembleOneOp (
505     ACPI_WALK_STATE         *WalkState,
506     ACPI_OP_WALK_INFO       *Info,
507     ACPI_PARSE_OBJECT       *Op);
508 
509 void
510 AcpiDmDecodeInternalObject (
511     ACPI_OPERAND_OBJECT     *ObjDesc);
512 
513 UINT32
514 AcpiDmListType (
515     ACPI_PARSE_OBJECT       *Op);
516 
517 void
518 AcpiDmMethodFlags (
519     ACPI_PARSE_OBJECT       *Op);
520 
521 void
522 AcpiDmFieldFlags (
523     ACPI_PARSE_OBJECT       *Op);
524 
525 void
526 AcpiDmAddressSpace (
527     UINT8                   SpaceId);
528 
529 void
530 AcpiDmRegionFlags (
531     ACPI_PARSE_OBJECT       *Op);
532 
533 void
534 AcpiDmMatchOp (
535     ACPI_PARSE_OBJECT       *Op);
536 
537 
538 /*
539  * dmnames
540  */
541 UINT32
542 AcpiDmDumpName (
543     UINT32                  Name);
544 
545 ACPI_STATUS
546 AcpiPsDisplayObjectPathname (
547     ACPI_WALK_STATE         *WalkState,
548     ACPI_PARSE_OBJECT       *Op);
549 
550 void
551 AcpiDmNamestring (
552     char                    *Name);
553 
554 
555 /*
556  * dmobject
557  */
558 void
559 AcpiDmDisplayInternalObject (
560     ACPI_OPERAND_OBJECT     *ObjDesc,
561     ACPI_WALK_STATE         *WalkState);
562 
563 void
564 AcpiDmDisplayArguments (
565     ACPI_WALK_STATE         *WalkState);
566 
567 void
568 AcpiDmDisplayLocals (
569     ACPI_WALK_STATE         *WalkState);
570 
571 void
572 AcpiDmDumpMethodInfo (
573     ACPI_STATUS             Status,
574     ACPI_WALK_STATE         *WalkState,
575     ACPI_PARSE_OBJECT       *Op);
576 
577 
578 /*
579  * dmbuffer
580  */
581 void
582 AcpiDmDisasmByteList (
583     UINT32                  Level,
584     UINT8                   *ByteData,
585     UINT32                  ByteCount);
586 
587 void
588 AcpiDmByteList (
589     ACPI_OP_WALK_INFO       *Info,
590     ACPI_PARSE_OBJECT       *Op);
591 
592 void
593 AcpiDmIsEisaId (
594     ACPI_PARSE_OBJECT       *Op);
595 
596 void
597 AcpiDmEisaId (
598     UINT32                  EncodedId);
599 
600 BOOLEAN
601 AcpiDmIsUnicodeBuffer (
602     ACPI_PARSE_OBJECT       *Op);
603 
604 BOOLEAN
605 AcpiDmIsStringBuffer (
606     ACPI_PARSE_OBJECT       *Op);
607 
608 
609 /*
610  * dmextern
611  */
612 
613 ACPI_STATUS
614 AcpiDmAddToExternalFileList (
615     char                    *PathList);
616 
617 void
618 AcpiDmClearExternalFileList (
619     void);
620 
621 void
622 AcpiDmAddToExternalList (
623     ACPI_PARSE_OBJECT       *Op,
624     char                    *Path,
625     UINT8                   Type,
626     UINT32                  Value);
627 
628 void
629 AcpiDmAddExternalsToNamespace (
630     void);
631 
632 UINT32
633 AcpiDmGetExternalMethodCount (
634     void);
635 
636 void
637 AcpiDmClearExternalList (
638     void);
639 
640 void
641 AcpiDmEmitExternals (
642     void);
643 
644 
645 /*
646  * dmresrc
647  */
648 void
649 AcpiDmDumpInteger8 (
650     UINT8                   Value,
651     char                    *Name);
652 
653 void
654 AcpiDmDumpInteger16 (
655     UINT16                  Value,
656     char                    *Name);
657 
658 void
659 AcpiDmDumpInteger32 (
660     UINT32                  Value,
661     char                    *Name);
662 
663 void
664 AcpiDmDumpInteger64 (
665     UINT64                  Value,
666     char                    *Name);
667 
668 void
669 AcpiDmResourceTemplate (
670     ACPI_OP_WALK_INFO       *Info,
671     ACPI_PARSE_OBJECT       *Op,
672     UINT8                   *ByteData,
673     UINT32                  ByteCount);
674 
675 ACPI_STATUS
676 AcpiDmIsResourceTemplate (
677     ACPI_PARSE_OBJECT       *Op);
678 
679 void
680 AcpiDmBitList (
681     UINT16                  Mask);
682 
683 void
684 AcpiDmDescriptorName (
685     void);
686 
687 
688 /*
689  * dmresrcl
690  */
691 void
692 AcpiDmWordDescriptor (
693     AML_RESOURCE            *Resource,
694     UINT32                  Length,
695     UINT32                  Level);
696 
697 void
698 AcpiDmDwordDescriptor (
699     AML_RESOURCE            *Resource,
700     UINT32                  Length,
701     UINT32                  Level);
702 
703 void
704 AcpiDmExtendedDescriptor (
705     AML_RESOURCE            *Resource,
706     UINT32                  Length,
707     UINT32                  Level);
708 
709 void
710 AcpiDmQwordDescriptor (
711     AML_RESOURCE            *Resource,
712     UINT32                  Length,
713     UINT32                  Level);
714 
715 void
716 AcpiDmMemory24Descriptor (
717     AML_RESOURCE            *Resource,
718     UINT32                  Length,
719     UINT32                  Level);
720 
721 void
722 AcpiDmMemory32Descriptor (
723     AML_RESOURCE            *Resource,
724     UINT32                  Length,
725     UINT32                  Level);
726 
727 void
728 AcpiDmFixedMemory32Descriptor (
729     AML_RESOURCE            *Resource,
730     UINT32                  Length,
731     UINT32                  Level);
732 
733 void
734 AcpiDmGenericRegisterDescriptor (
735     AML_RESOURCE            *Resource,
736     UINT32                  Length,
737     UINT32                  Level);
738 
739 void
740 AcpiDmInterruptDescriptor (
741     AML_RESOURCE            *Resource,
742     UINT32                  Length,
743     UINT32                  Level);
744 
745 void
746 AcpiDmVendorLargeDescriptor (
747     AML_RESOURCE            *Resource,
748     UINT32                  Length,
749     UINT32                  Level);
750 
751 void
752 AcpiDmGpioDescriptor (
753     AML_RESOURCE            *Resource,
754     UINT32                  Length,
755     UINT32                  Level);
756 
757 void
758 AcpiDmSerialBusDescriptor (
759     AML_RESOURCE            *Resource,
760     UINT32                  Length,
761     UINT32                  Level);
762 
763 void
764 AcpiDmVendorCommon (
765     char                    *Name,
766     UINT8                   *ByteData,
767     UINT32                  Length,
768     UINT32                  Level);
769 
770 
771 /*
772  * dmresrcs
773  */
774 void
775 AcpiDmIrqDescriptor (
776     AML_RESOURCE            *Resource,
777     UINT32                  Length,
778     UINT32                  Level);
779 
780 void
781 AcpiDmDmaDescriptor (
782     AML_RESOURCE            *Resource,
783     UINT32                  Length,
784     UINT32                  Level);
785 
786 void
787 AcpiDmFixedDmaDescriptor (
788     AML_RESOURCE            *Resource,
789     UINT32                  Length,
790     UINT32                  Level);
791 
792 void
793 AcpiDmIoDescriptor (
794     AML_RESOURCE            *Resource,
795     UINT32                  Length,
796     UINT32                  Level);
797 
798 void
799 AcpiDmFixedIoDescriptor (
800     AML_RESOURCE            *Resource,
801     UINT32                  Length,
802     UINT32                  Level);
803 
804 void
805 AcpiDmStartDependentDescriptor (
806     AML_RESOURCE            *Resource,
807     UINT32                  Length,
808     UINT32                  Level);
809 
810 void
811 AcpiDmEndDependentDescriptor (
812     AML_RESOURCE            *Resource,
813     UINT32                  Length,
814     UINT32                  Level);
815 
816 void
817 AcpiDmVendorSmallDescriptor (
818     AML_RESOURCE            *Resource,
819     UINT32                  Length,
820     UINT32                  Level);
821 
822 
823 /*
824  * dmutils
825  */
826 void
827 AcpiDmDecodeAttribute (
828     UINT8                   Attribute);
829 
830 void
831 AcpiDmIndent (
832     UINT32                  Level);
833 
834 BOOLEAN
835 AcpiDmCommaIfListMember (
836     ACPI_PARSE_OBJECT       *Op);
837 
838 void
839 AcpiDmCommaIfFieldMember (
840     ACPI_PARSE_OBJECT       *Op);
841 
842 
843 /*
844  * dmrestag
845  */
846 void
847 AcpiDmFindResources (
848     ACPI_PARSE_OBJECT       *Root);
849 
850 void
851 AcpiDmCheckResourceReference (
852     ACPI_PARSE_OBJECT       *Op,
853     ACPI_WALK_STATE         *WalkState);
854 
855 
856 /*
857  * acdisasm
858  */
859 void
860 AdDisassemblerHeader (
861     char                    *Filename);
862 
863 
864 #endif  /* __ACDISASM_H__ */
865