Sync ACPICA with Intel's version 20180508 (from previously 20170831).
authorSascha Wildner <saw@online.de>
Wed, 16 May 2018 16:50:43 +0000 (18:50 +0200)
committerSascha Wildner <saw@online.de>
Wed, 16 May 2018 16:51:52 +0000 (18:51 +0200)
Tons of fixes and improvements.

For detailed list, please see sys/contrib/dev/acpica/changes.txt.

445 files changed:
sys/contrib/dev/acpica/changes.txt
sys/contrib/dev/acpica/generate/unix/Makefile.config
sys/contrib/dev/acpica/generate/unix/acpiexec/Makefile
sys/contrib/dev/acpica/generate/unix/acpinames/Makefile
sys/contrib/dev/acpica/generate/unix/iasl/Makefile
sys/contrib/dev/acpica/source/common/acfileio.c
sys/contrib/dev/acpica/source/common/acgetline.c
sys/contrib/dev/acpica/source/common/adfile.c
sys/contrib/dev/acpica/source/common/adisasm.c
sys/contrib/dev/acpica/source/common/adwalk.c
sys/contrib/dev/acpica/source/common/ahids.c
sys/contrib/dev/acpica/source/common/ahpredef.c
sys/contrib/dev/acpica/source/common/ahtable.c
sys/contrib/dev/acpica/source/common/ahuuids.c
sys/contrib/dev/acpica/source/common/cmfsize.c
sys/contrib/dev/acpica/source/common/dmextern.c
sys/contrib/dev/acpica/source/common/dmrestag.c
sys/contrib/dev/acpica/source/common/dmswitch.c
sys/contrib/dev/acpica/source/common/dmtable.c
sys/contrib/dev/acpica/source/common/dmtables.c
sys/contrib/dev/acpica/source/common/dmtbdump.c
sys/contrib/dev/acpica/source/common/dmtbdump1.c [new file with mode: 0644]
sys/contrib/dev/acpica/source/common/dmtbdump2.c [new file with mode: 0644]
sys/contrib/dev/acpica/source/common/dmtbdump3.c [new file with mode: 0644]
sys/contrib/dev/acpica/source/common/dmtbinfo.c
sys/contrib/dev/acpica/source/common/dmtbinfo1.c [new file with mode: 0644]
sys/contrib/dev/acpica/source/common/dmtbinfo2.c [new file with mode: 0644]
sys/contrib/dev/acpica/source/common/dmtbinfo3.c [new file with mode: 0644]
sys/contrib/dev/acpica/source/common/getopt.c
sys/contrib/dev/acpica/source/compiler/aslallocate.c [copied from sys/contrib/dev/acpica/source/compiler/prparser.l with 72% similarity]
sys/contrib/dev/acpica/source/compiler/aslanalyze.c
sys/contrib/dev/acpica/source/compiler/aslascii.c
sys/contrib/dev/acpica/source/compiler/aslbtypes.c
sys/contrib/dev/acpica/source/compiler/aslcache.c [copied from sys/contrib/dev/acpica/source/components/events/evevent.c with 55% similarity]
sys/contrib/dev/acpica/source/compiler/aslcodegen.c
sys/contrib/dev/acpica/source/compiler/aslcompile.c
sys/contrib/dev/acpica/source/compiler/aslcompiler.h
sys/contrib/dev/acpica/source/compiler/aslcompiler.l
sys/contrib/dev/acpica/source/compiler/aslcstyle.y
sys/contrib/dev/acpica/source/compiler/asldebug.c
sys/contrib/dev/acpica/source/compiler/asldefine.h
sys/contrib/dev/acpica/source/compiler/aslerror.c
sys/contrib/dev/acpica/source/compiler/aslexternal.c
sys/contrib/dev/acpica/source/compiler/aslfileio.c
sys/contrib/dev/acpica/source/compiler/aslfiles.c
sys/contrib/dev/acpica/source/compiler/aslfold.c
sys/contrib/dev/acpica/source/compiler/aslglobal.h
sys/contrib/dev/acpica/source/compiler/aslhelp.c
sys/contrib/dev/acpica/source/compiler/aslhelpers.y
sys/contrib/dev/acpica/source/compiler/aslhex.c
sys/contrib/dev/acpica/source/compiler/aslkeywords.y
sys/contrib/dev/acpica/source/compiler/asllength.c
sys/contrib/dev/acpica/source/compiler/asllisting.c
sys/contrib/dev/acpica/source/compiler/asllistsup.c
sys/contrib/dev/acpica/source/compiler/aslload.c
sys/contrib/dev/acpica/source/compiler/asllookup.c
sys/contrib/dev/acpica/source/compiler/aslmain.c
sys/contrib/dev/acpica/source/compiler/aslmap.c
sys/contrib/dev/acpica/source/compiler/aslmapenter.c
sys/contrib/dev/acpica/source/compiler/aslmapoutput.c
sys/contrib/dev/acpica/source/compiler/aslmaputils.c
sys/contrib/dev/acpica/source/compiler/aslmessages.c
sys/contrib/dev/acpica/source/compiler/aslmessages.h
sys/contrib/dev/acpica/source/compiler/aslmethod.c
sys/contrib/dev/acpica/source/compiler/aslnamesp.c
sys/contrib/dev/acpica/source/compiler/asloffset.c
sys/contrib/dev/acpica/source/compiler/aslopcodes.c
sys/contrib/dev/acpica/source/compiler/asloperands.c
sys/contrib/dev/acpica/source/compiler/aslopt.c
sys/contrib/dev/acpica/source/compiler/asloptions.c
sys/contrib/dev/acpica/source/compiler/aslparseop.c
sys/contrib/dev/acpica/source/compiler/aslparser.y
sys/contrib/dev/acpica/source/compiler/aslpld.c
sys/contrib/dev/acpica/source/compiler/aslpredef.c
sys/contrib/dev/acpica/source/compiler/aslprepkg.c
sys/contrib/dev/acpica/source/compiler/aslprimaries.y
sys/contrib/dev/acpica/source/compiler/aslprintf.c
sys/contrib/dev/acpica/source/compiler/aslprune.c
sys/contrib/dev/acpica/source/compiler/aslresource.c
sys/contrib/dev/acpica/source/compiler/aslresources.y
sys/contrib/dev/acpica/source/compiler/aslrestype1.c
sys/contrib/dev/acpica/source/compiler/aslrestype1i.c
sys/contrib/dev/acpica/source/compiler/aslrestype2.c
sys/contrib/dev/acpica/source/compiler/aslrestype2d.c
sys/contrib/dev/acpica/source/compiler/aslrestype2e.c
sys/contrib/dev/acpica/source/compiler/aslrestype2q.c
sys/contrib/dev/acpica/source/compiler/aslrestype2s.c
sys/contrib/dev/acpica/source/compiler/aslrestype2w.c
sys/contrib/dev/acpica/source/compiler/aslrules.y
sys/contrib/dev/acpica/source/compiler/aslstartup.c
sys/contrib/dev/acpica/source/compiler/aslstubs.c
sys/contrib/dev/acpica/source/compiler/aslsupport.l
sys/contrib/dev/acpica/source/compiler/aslsupport.y
sys/contrib/dev/acpica/source/compiler/asltokens.y
sys/contrib/dev/acpica/source/compiler/asltransform.c
sys/contrib/dev/acpica/source/compiler/asltree.c
sys/contrib/dev/acpica/source/compiler/asltypes.h
sys/contrib/dev/acpica/source/compiler/asltypes.y
sys/contrib/dev/acpica/source/compiler/aslutils.c
sys/contrib/dev/acpica/source/compiler/asluuid.c
sys/contrib/dev/acpica/source/compiler/aslwalks.c
sys/contrib/dev/acpica/source/compiler/aslxref.c
sys/contrib/dev/acpica/source/compiler/aslxrefout.c
sys/contrib/dev/acpica/source/compiler/cvcompiler.c
sys/contrib/dev/acpica/source/compiler/cvdisasm.c
sys/contrib/dev/acpica/source/compiler/cvparser.c
sys/contrib/dev/acpica/source/compiler/dtcompile.c
sys/contrib/dev/acpica/source/compiler/dtcompiler.h
sys/contrib/dev/acpica/source/compiler/dtexpress.c
sys/contrib/dev/acpica/source/compiler/dtfield.c
sys/contrib/dev/acpica/source/compiler/dtio.c
sys/contrib/dev/acpica/source/compiler/dtparser.l
sys/contrib/dev/acpica/source/compiler/dtparser.y
sys/contrib/dev/acpica/source/compiler/dtsubtable.c
sys/contrib/dev/acpica/source/compiler/dttable.c
sys/contrib/dev/acpica/source/compiler/dttable1.c
sys/contrib/dev/acpica/source/compiler/dttable2.c
sys/contrib/dev/acpica/source/compiler/dttemplate.c
sys/contrib/dev/acpica/source/compiler/dttemplate.h
sys/contrib/dev/acpica/source/compiler/dtutils.c
sys/contrib/dev/acpica/source/compiler/preprocess.h
sys/contrib/dev/acpica/source/compiler/prexpress.c
sys/contrib/dev/acpica/source/compiler/prmacros.c
sys/contrib/dev/acpica/source/compiler/prparser.l
sys/contrib/dev/acpica/source/compiler/prparser.y
sys/contrib/dev/acpica/source/compiler/prscan.c
sys/contrib/dev/acpica/source/compiler/prutils.c
sys/contrib/dev/acpica/source/components/debugger/dbcmds.c
sys/contrib/dev/acpica/source/components/debugger/dbconvert.c
sys/contrib/dev/acpica/source/components/debugger/dbdisply.c
sys/contrib/dev/acpica/source/components/debugger/dbexec.c
sys/contrib/dev/acpica/source/components/debugger/dbfileio.c
sys/contrib/dev/acpica/source/components/debugger/dbhistry.c
sys/contrib/dev/acpica/source/components/debugger/dbinput.c
sys/contrib/dev/acpica/source/components/debugger/dbmethod.c
sys/contrib/dev/acpica/source/components/debugger/dbnames.c
sys/contrib/dev/acpica/source/components/debugger/dbobject.c
sys/contrib/dev/acpica/source/components/debugger/dbstats.c
sys/contrib/dev/acpica/source/components/debugger/dbtest.c
sys/contrib/dev/acpica/source/components/debugger/dbutils.c
sys/contrib/dev/acpica/source/components/debugger/dbxface.c
sys/contrib/dev/acpica/source/components/disassembler/dmbuffer.c
sys/contrib/dev/acpica/source/components/disassembler/dmcstyle.c
sys/contrib/dev/acpica/source/components/disassembler/dmdeferred.c
sys/contrib/dev/acpica/source/components/disassembler/dmnames.c
sys/contrib/dev/acpica/source/components/disassembler/dmopcode.c
sys/contrib/dev/acpica/source/components/disassembler/dmresrc.c
sys/contrib/dev/acpica/source/components/disassembler/dmresrcl.c
sys/contrib/dev/acpica/source/components/disassembler/dmresrcl2.c
sys/contrib/dev/acpica/source/components/disassembler/dmresrcs.c
sys/contrib/dev/acpica/source/components/disassembler/dmutils.c
sys/contrib/dev/acpica/source/components/disassembler/dmwalk.c
sys/contrib/dev/acpica/source/components/dispatcher/dsargs.c
sys/contrib/dev/acpica/source/components/dispatcher/dscontrol.c
sys/contrib/dev/acpica/source/components/dispatcher/dsdebug.c
sys/contrib/dev/acpica/source/components/dispatcher/dsfield.c
sys/contrib/dev/acpica/source/components/dispatcher/dsinit.c
sys/contrib/dev/acpica/source/components/dispatcher/dsmethod.c
sys/contrib/dev/acpica/source/components/dispatcher/dsmthdat.c
sys/contrib/dev/acpica/source/components/dispatcher/dsobject.c
sys/contrib/dev/acpica/source/components/dispatcher/dsopcode.c
sys/contrib/dev/acpica/source/components/dispatcher/dspkginit.c
sys/contrib/dev/acpica/source/components/dispatcher/dsutils.c
sys/contrib/dev/acpica/source/components/dispatcher/dswexec.c
sys/contrib/dev/acpica/source/components/dispatcher/dswload.c
sys/contrib/dev/acpica/source/components/dispatcher/dswload2.c
sys/contrib/dev/acpica/source/components/dispatcher/dswscope.c
sys/contrib/dev/acpica/source/components/dispatcher/dswstate.c
sys/contrib/dev/acpica/source/components/events/evevent.c
sys/contrib/dev/acpica/source/components/events/evglock.c
sys/contrib/dev/acpica/source/components/events/evgpe.c
sys/contrib/dev/acpica/source/components/events/evgpeblk.c
sys/contrib/dev/acpica/source/components/events/evgpeinit.c
sys/contrib/dev/acpica/source/components/events/evgpeutil.c
sys/contrib/dev/acpica/source/components/events/evhandler.c
sys/contrib/dev/acpica/source/components/events/evmisc.c
sys/contrib/dev/acpica/source/components/events/evregion.c
sys/contrib/dev/acpica/source/components/events/evrgnini.c
sys/contrib/dev/acpica/source/components/events/evsci.c
sys/contrib/dev/acpica/source/components/events/evxface.c
sys/contrib/dev/acpica/source/components/events/evxfevnt.c
sys/contrib/dev/acpica/source/components/events/evxfgpe.c
sys/contrib/dev/acpica/source/components/events/evxfregn.c
sys/contrib/dev/acpica/source/components/executer/exconcat.c
sys/contrib/dev/acpica/source/components/executer/exconfig.c
sys/contrib/dev/acpica/source/components/executer/exconvrt.c
sys/contrib/dev/acpica/source/components/executer/excreate.c
sys/contrib/dev/acpica/source/components/executer/exdebug.c
sys/contrib/dev/acpica/source/components/executer/exdump.c
sys/contrib/dev/acpica/source/components/executer/exfield.c
sys/contrib/dev/acpica/source/components/executer/exfldio.c
sys/contrib/dev/acpica/source/components/executer/exmisc.c
sys/contrib/dev/acpica/source/components/executer/exmutex.c
sys/contrib/dev/acpica/source/components/executer/exnames.c
sys/contrib/dev/acpica/source/components/executer/exoparg1.c
sys/contrib/dev/acpica/source/components/executer/exoparg2.c
sys/contrib/dev/acpica/source/components/executer/exoparg3.c
sys/contrib/dev/acpica/source/components/executer/exoparg6.c
sys/contrib/dev/acpica/source/components/executer/exprep.c
sys/contrib/dev/acpica/source/components/executer/exregion.c
sys/contrib/dev/acpica/source/components/executer/exresnte.c
sys/contrib/dev/acpica/source/components/executer/exresolv.c
sys/contrib/dev/acpica/source/components/executer/exresop.c
sys/contrib/dev/acpica/source/components/executer/exstore.c
sys/contrib/dev/acpica/source/components/executer/exstoren.c
sys/contrib/dev/acpica/source/components/executer/exstorob.c
sys/contrib/dev/acpica/source/components/executer/exsystem.c
sys/contrib/dev/acpica/source/components/executer/extrace.c
sys/contrib/dev/acpica/source/components/executer/exutils.c
sys/contrib/dev/acpica/source/components/hardware/hwacpi.c
sys/contrib/dev/acpica/source/components/hardware/hwesleep.c
sys/contrib/dev/acpica/source/components/hardware/hwgpe.c
sys/contrib/dev/acpica/source/components/hardware/hwpci.c
sys/contrib/dev/acpica/source/components/hardware/hwregs.c
sys/contrib/dev/acpica/source/components/hardware/hwsleep.c
sys/contrib/dev/acpica/source/components/hardware/hwtimer.c
sys/contrib/dev/acpica/source/components/hardware/hwvalid.c
sys/contrib/dev/acpica/source/components/hardware/hwxface.c
sys/contrib/dev/acpica/source/components/hardware/hwxfsleep.c
sys/contrib/dev/acpica/source/components/namespace/nsaccess.c
sys/contrib/dev/acpica/source/components/namespace/nsalloc.c
sys/contrib/dev/acpica/source/components/namespace/nsarguments.c
sys/contrib/dev/acpica/source/components/namespace/nsconvert.c
sys/contrib/dev/acpica/source/components/namespace/nsdump.c
sys/contrib/dev/acpica/source/components/namespace/nsdumpdv.c
sys/contrib/dev/acpica/source/components/namespace/nseval.c
sys/contrib/dev/acpica/source/components/namespace/nsinit.c
sys/contrib/dev/acpica/source/components/namespace/nsload.c
sys/contrib/dev/acpica/source/components/namespace/nsnames.c
sys/contrib/dev/acpica/source/components/namespace/nsobject.c
sys/contrib/dev/acpica/source/components/namespace/nsparse.c
sys/contrib/dev/acpica/source/components/namespace/nspredef.c
sys/contrib/dev/acpica/source/components/namespace/nsprepkg.c
sys/contrib/dev/acpica/source/components/namespace/nsrepair.c
sys/contrib/dev/acpica/source/components/namespace/nsrepair2.c
sys/contrib/dev/acpica/source/components/namespace/nssearch.c
sys/contrib/dev/acpica/source/components/namespace/nsutils.c
sys/contrib/dev/acpica/source/components/namespace/nswalk.c
sys/contrib/dev/acpica/source/components/namespace/nsxfeval.c
sys/contrib/dev/acpica/source/components/namespace/nsxfname.c
sys/contrib/dev/acpica/source/components/namespace/nsxfobj.c
sys/contrib/dev/acpica/source/components/parser/psargs.c
sys/contrib/dev/acpica/source/components/parser/psloop.c
sys/contrib/dev/acpica/source/components/parser/psobject.c
sys/contrib/dev/acpica/source/components/parser/psopcode.c
sys/contrib/dev/acpica/source/components/parser/psopinfo.c
sys/contrib/dev/acpica/source/components/parser/psparse.c
sys/contrib/dev/acpica/source/components/parser/psscope.c
sys/contrib/dev/acpica/source/components/parser/pstree.c
sys/contrib/dev/acpica/source/components/parser/psutils.c
sys/contrib/dev/acpica/source/components/parser/pswalk.c
sys/contrib/dev/acpica/source/components/parser/psxface.c
sys/contrib/dev/acpica/source/components/resources/rsaddr.c
sys/contrib/dev/acpica/source/components/resources/rscalc.c
sys/contrib/dev/acpica/source/components/resources/rscreate.c
sys/contrib/dev/acpica/source/components/resources/rsdump.c
sys/contrib/dev/acpica/source/components/resources/rsdumpinfo.c
sys/contrib/dev/acpica/source/components/resources/rsinfo.c
sys/contrib/dev/acpica/source/components/resources/rsio.c
sys/contrib/dev/acpica/source/components/resources/rsirq.c
sys/contrib/dev/acpica/source/components/resources/rslist.c
sys/contrib/dev/acpica/source/components/resources/rsmemory.c
sys/contrib/dev/acpica/source/components/resources/rsmisc.c
sys/contrib/dev/acpica/source/components/resources/rsserial.c
sys/contrib/dev/acpica/source/components/resources/rsutils.c
sys/contrib/dev/acpica/source/components/resources/rsxface.c
sys/contrib/dev/acpica/source/components/tables/tbdata.c
sys/contrib/dev/acpica/source/components/tables/tbfadt.c
sys/contrib/dev/acpica/source/components/tables/tbfind.c
sys/contrib/dev/acpica/source/components/tables/tbinstal.c
sys/contrib/dev/acpica/source/components/tables/tbprint.c
sys/contrib/dev/acpica/source/components/tables/tbutils.c
sys/contrib/dev/acpica/source/components/tables/tbxface.c
sys/contrib/dev/acpica/source/components/tables/tbxfload.c
sys/contrib/dev/acpica/source/components/tables/tbxfroot.c
sys/contrib/dev/acpica/source/components/utilities/utaddress.c
sys/contrib/dev/acpica/source/components/utilities/utalloc.c
sys/contrib/dev/acpica/source/components/utilities/utascii.c
sys/contrib/dev/acpica/source/components/utilities/utbuffer.c
sys/contrib/dev/acpica/source/components/utilities/utcache.c
sys/contrib/dev/acpica/source/components/utilities/utclib.c
sys/contrib/dev/acpica/source/components/utilities/utcopy.c
sys/contrib/dev/acpica/source/components/utilities/utdebug.c
sys/contrib/dev/acpica/source/components/utilities/utdecode.c
sys/contrib/dev/acpica/source/components/utilities/utdelete.c
sys/contrib/dev/acpica/source/components/utilities/uterror.c
sys/contrib/dev/acpica/source/components/utilities/uteval.c
sys/contrib/dev/acpica/source/components/utilities/utexcep.c
sys/contrib/dev/acpica/source/components/utilities/utglobal.c
sys/contrib/dev/acpica/source/components/utilities/uthex.c
sys/contrib/dev/acpica/source/components/utilities/utids.c
sys/contrib/dev/acpica/source/components/utilities/utinit.c
sys/contrib/dev/acpica/source/components/utilities/utlock.c
sys/contrib/dev/acpica/source/components/utilities/utmath.c
sys/contrib/dev/acpica/source/components/utilities/utmisc.c
sys/contrib/dev/acpica/source/components/utilities/utmutex.c
sys/contrib/dev/acpica/source/components/utilities/utnonansi.c
sys/contrib/dev/acpica/source/components/utilities/utobject.c
sys/contrib/dev/acpica/source/components/utilities/utosi.c
sys/contrib/dev/acpica/source/components/utilities/utownerid.c
sys/contrib/dev/acpica/source/components/utilities/utpredef.c
sys/contrib/dev/acpica/source/components/utilities/utprint.c
sys/contrib/dev/acpica/source/components/utilities/utresdecode.c
sys/contrib/dev/acpica/source/components/utilities/utresrc.c
sys/contrib/dev/acpica/source/components/utilities/utstate.c
sys/contrib/dev/acpica/source/components/utilities/utstring.c
sys/contrib/dev/acpica/source/components/utilities/utstrsuppt.c
sys/contrib/dev/acpica/source/components/utilities/utstrtoul64.c
sys/contrib/dev/acpica/source/components/utilities/uttrack.c
sys/contrib/dev/acpica/source/components/utilities/utuuid.c
sys/contrib/dev/acpica/source/components/utilities/utxface.c
sys/contrib/dev/acpica/source/components/utilities/utxferror.c
sys/contrib/dev/acpica/source/components/utilities/utxfinit.c
sys/contrib/dev/acpica/source/components/utilities/utxfmutex.c
sys/contrib/dev/acpica/source/include/acapps.h
sys/contrib/dev/acpica/source/include/acbuffer.h
sys/contrib/dev/acpica/source/include/acclib.h
sys/contrib/dev/acpica/source/include/accommon.h
sys/contrib/dev/acpica/source/include/acconfig.h
sys/contrib/dev/acpica/source/include/acconvert.h
sys/contrib/dev/acpica/source/include/acdebug.h
sys/contrib/dev/acpica/source/include/acdisasm.h
sys/contrib/dev/acpica/source/include/acdispat.h
sys/contrib/dev/acpica/source/include/acevents.h
sys/contrib/dev/acpica/source/include/acexcep.h
sys/contrib/dev/acpica/source/include/acglobal.h
sys/contrib/dev/acpica/source/include/achware.h
sys/contrib/dev/acpica/source/include/acinterp.h
sys/contrib/dev/acpica/source/include/aclocal.h
sys/contrib/dev/acpica/source/include/acmacros.h
sys/contrib/dev/acpica/source/include/acnames.h
sys/contrib/dev/acpica/source/include/acnamesp.h
sys/contrib/dev/acpica/source/include/acobject.h
sys/contrib/dev/acpica/source/include/acopcode.h
sys/contrib/dev/acpica/source/include/acoutput.h
sys/contrib/dev/acpica/source/include/acparser.h
sys/contrib/dev/acpica/source/include/acpi.h
sys/contrib/dev/acpica/source/include/acpiosxf.h
sys/contrib/dev/acpica/source/include/acpixf.h
sys/contrib/dev/acpica/source/include/acpredef.h
sys/contrib/dev/acpica/source/include/acresrc.h
sys/contrib/dev/acpica/source/include/acrestyp.h
sys/contrib/dev/acpica/source/include/acstruct.h
sys/contrib/dev/acpica/source/include/actables.h
sys/contrib/dev/acpica/source/include/actbinfo.h [new file with mode: 0644]
sys/contrib/dev/acpica/source/include/actbl.h
sys/contrib/dev/acpica/source/include/actbl1.h
sys/contrib/dev/acpica/source/include/actbl2.h
sys/contrib/dev/acpica/source/include/actbl3.h
sys/contrib/dev/acpica/source/include/actypes.h
sys/contrib/dev/acpica/source/include/acutils.h
sys/contrib/dev/acpica/source/include/acuuid.h
sys/contrib/dev/acpica/source/include/amlcode.h
sys/contrib/dev/acpica/source/include/amlresrc.h
sys/contrib/dev/acpica/source/include/platform/accygwin.h
sys/contrib/dev/acpica/source/include/platform/acdragonflyex.h
sys/contrib/dev/acpica/source/include/platform/acefi.h
sys/contrib/dev/acpica/source/include/platform/acefiex.h
sys/contrib/dev/acpica/source/include/platform/acenv.h
sys/contrib/dev/acpica/source/include/platform/acenvex.h
sys/contrib/dev/acpica/source/include/platform/acfreebsd.h
sys/contrib/dev/acpica/source/include/platform/acgcc.h
sys/contrib/dev/acpica/source/include/platform/acgccex.h
sys/contrib/dev/acpica/source/include/platform/achaiku.h
sys/contrib/dev/acpica/source/include/platform/acintel.h
sys/contrib/dev/acpica/source/include/platform/aclinux.h
sys/contrib/dev/acpica/source/include/platform/aclinuxex.h
sys/contrib/dev/acpica/source/include/platform/acmacosx.h
sys/contrib/dev/acpica/source/include/platform/acmsvc.h
sys/contrib/dev/acpica/source/include/platform/acmsvcex.h
sys/contrib/dev/acpica/source/include/platform/acnetbsd.h
sys/contrib/dev/acpica/source/include/platform/acos2.h
sys/contrib/dev/acpica/source/include/platform/acqnx.h
sys/contrib/dev/acpica/source/include/platform/acwin.h
sys/contrib/dev/acpica/source/include/platform/acwin64.h
sys/contrib/dev/acpica/source/os_specific/service_layers/osbsdtbl.c
sys/contrib/dev/acpica/source/os_specific/service_layers/osgendbg.c
sys/contrib/dev/acpica/source/os_specific/service_layers/oslinuxtbl.c
sys/contrib/dev/acpica/source/os_specific/service_layers/osunixdir.c
sys/contrib/dev/acpica/source/os_specific/service_layers/osunixmap.c
sys/contrib/dev/acpica/source/os_specific/service_layers/osunixxf.c
sys/contrib/dev/acpica/source/os_specific/service_layers/oswindir.c
sys/contrib/dev/acpica/source/os_specific/service_layers/oswintbl.c
sys/contrib/dev/acpica/source/os_specific/service_layers/oswinxf.c
sys/contrib/dev/acpica/source/tools/acpibin/abcompare.c
sys/contrib/dev/acpica/source/tools/acpibin/abmain.c
sys/contrib/dev/acpica/source/tools/acpibin/acpibin.h
sys/contrib/dev/acpica/source/tools/acpidump/acpidump.h
sys/contrib/dev/acpica/source/tools/acpidump/apdump.c
sys/contrib/dev/acpica/source/tools/acpidump/apfiles.c
sys/contrib/dev/acpica/source/tools/acpidump/apmain.c
sys/contrib/dev/acpica/source/tools/acpiexec/aecommon.h
sys/contrib/dev/acpica/source/tools/acpiexec/aeexception.c
sys/contrib/dev/acpica/source/tools/acpiexec/aeexec.c
sys/contrib/dev/acpica/source/tools/acpiexec/aehandlers.c
sys/contrib/dev/acpica/source/tools/acpiexec/aeinitfile.c
sys/contrib/dev/acpica/source/tools/acpiexec/aeinstall.c [copied from sys/contrib/dev/acpica/source/os_specific/service_layers/osgendbg.c with 60% similarity]
sys/contrib/dev/acpica/source/tools/acpiexec/aemain.c
sys/contrib/dev/acpica/source/tools/acpiexec/aeregion.c
sys/contrib/dev/acpica/source/tools/acpiexec/aetables.c
sys/contrib/dev/acpica/source/tools/acpiexec/aetables.h
sys/contrib/dev/acpica/source/tools/acpiexec/aetests.c [copied from sys/contrib/dev/acpica/source/tools/acpiexec/aeexec.c with 66% similarity]
sys/contrib/dev/acpica/source/tools/acpihelp/acpihelp.h
sys/contrib/dev/acpica/source/tools/acpihelp/ahaml.c
sys/contrib/dev/acpica/source/tools/acpihelp/ahamlops.c
sys/contrib/dev/acpica/source/tools/acpihelp/ahasl.c
sys/contrib/dev/acpica/source/tools/acpihelp/ahaslkey.c
sys/contrib/dev/acpica/source/tools/acpihelp/ahaslops.c
sys/contrib/dev/acpica/source/tools/acpihelp/ahdecode.c
sys/contrib/dev/acpica/source/tools/acpihelp/ahgrammar.c
sys/contrib/dev/acpica/source/tools/acpihelp/ahmain.c
sys/contrib/dev/acpica/source/tools/acpinames/acpinames.h
sys/contrib/dev/acpica/source/tools/acpinames/anmain.c
sys/contrib/dev/acpica/source/tools/acpinames/anstubs.c
sys/contrib/dev/acpica/source/tools/acpinames/antables.c
sys/contrib/dev/acpica/source/tools/acpisrc/acpisrc.h
sys/contrib/dev/acpica/source/tools/acpisrc/ascase.c
sys/contrib/dev/acpica/source/tools/acpisrc/asconvrt.c
sys/contrib/dev/acpica/source/tools/acpisrc/asfile.c
sys/contrib/dev/acpica/source/tools/acpisrc/asmain.c
sys/contrib/dev/acpica/source/tools/acpisrc/asremove.c
sys/contrib/dev/acpica/source/tools/acpisrc/astable.c
sys/contrib/dev/acpica/source/tools/acpisrc/asutils.c
sys/contrib/dev/acpica/source/tools/acpixtract/acpixtract.c
sys/contrib/dev/acpica/source/tools/acpixtract/acpixtract.h
sys/contrib/dev/acpica/source/tools/acpixtract/axmain.c
sys/contrib/dev/acpica/source/tools/acpixtract/axutils.c
sys/contrib/dev/acpica/source/tools/efihello/efihello.c
sys/contrib/dev/acpica/source/tools/examples/examples.c
sys/contrib/dev/acpica/source/tools/examples/examples.h
sys/contrib/dev/acpica/source/tools/examples/exstubs.c
sys/contrib/dev/acpica/source/tools/examples/extables.c
sys/contrib/dev/acpica/tests/misc/badcode.asl
sys/contrib/dev/acpica/tests/misc/converterSample.asl
sys/contrib/dev/acpica/tests/misc/grammar.asl
sys/dev/acpica/acpi.c
usr.sbin/acpi/acpibin/acpibin.8
usr.sbin/acpi/acpidump/acpidump.8
usr.sbin/acpi/acpiexec/Makefile
usr.sbin/acpi/acpiexec/acpiexec.8
usr.sbin/acpi/acpihelp/acpihelp.8
usr.sbin/acpi/acpinames/Makefile
usr.sbin/acpi/acpinames/acpinames.8
usr.sbin/acpi/acpixtract/acpixtract.8
usr.sbin/acpi/iasl/Makefile

index db25f7e..8273d37 100644 (file)
@@ -1,3 +1,407 @@
+----------------------------------------
+8 May 2018. Summary of changes for version 20180508:
+
+
+1) ACPICA kernel-resident subsystem:
+
+Completed the new (recently deployed) package resolution mechanism for 
+the Load and LoadTable ASL/AML operators. This fixes a regression that 
+was introduced in version 20180209 that could result in an 
+AE_AML_INTERNAL exception during the loading of a dynamic ACPI/AML table 
+(SSDT) that contains package objects.
+
+
+2) iASL Compiler/Disassembler and Tools:
+
+AcpiDump and AcpiXtract: Implemented support for ACPI tables larger than 
+1 MB. This change allows for table offsets within the acpidump file to be 
+up to 8 characters. These changes are backwards compatible with existing 
+acpidump files.
+
+
+----------------------------------------
+27 April 2018. Summary of changes for version 20180427: 
+
+
+1) ACPICA kernel-resident subsystem:
+
+Debugger: Added support for Package objects in the "Test Objects" 
+command. This command walks the entire namespace and evaluates all named 
+data objects (Integers, Strings, Buffers, and now Packages).
+
+Improved error messages for the namespace root node. Originally, the root 
+was referred to by the confusing string "\___". This has been replaced by 
+"Namespace Root" for clarification.
+
+Fixed a potential infinite loop in the AcpiRsDumpByteList function. Colin 
+Ian King <colin.king@canonical.com>.
+
+
+2) iASL Compiler/Disassembler and Tools: 
+
+iASL: Implemented support to detect and flag illegal forward references. 
+For compatibility with other ACPI implementations, these references are 
+now illegal at the root level of the DSDT or SSDTs. Forward references 
+have always been illegal within control methods. This change should not 
+affect existing ASL/AML code because of the fact that these references 
+have always been illegal in the other ACPI implementation.
+
+iASL: Added error messages for the case where a table OEM ID and OEM 
+TABLE ID strings are longer than the ACPI-defined length. Previously, 
+these strings were simply silently truncated.
+
+iASL: Enhanced the -tc option (which creates an AML hex file in C, 
+suitable for import into a firmware project):
+  1) Create a unique name for the table, to simplify use of multiple 
+SSDTs.
+  2) Add a protection #ifdef in the file, similar to a .h header file.
+With assistance from Sami Mujawar, sami.mujawar@arm.com and Evan Lloyd, 
+evan.lloyd@arm.com
+
+AcpiExec: Added a new option, -df, to disable the local fault handler. 
+This is useful during debugging, where it may be desired to drop into a 
+debugger on a fault.
+
+----------------------------------------
+13 March 2018. Summary of changes for version 20180313:
+
+
+1) ACPICA kernel-resident subsystem:
+
+Implemented various improvements to the GPE support:
+
+1) Dispatch all active GPEs at initialization time so that no GPEs are 
+lost.
+2) Enable runtime GPEs earlier. Some systems expect GPEs to be enabled 
+before devices are enumerated.
+3) Don't unconditionally clear ACPI IRQs during suspend/resume, so that 
+IRQs are not lost.
+4) Add parallel GPE handling to eliminate the possibility of dispatching 
+the same GPE twice.
+5) Dispatch any pending GPEs after enabling for the first time.
+
+AcpiGetObjectInfo - removed support for the _STA method. This was causing 
+problems on some platforms.
+
+Added a new _OSI string, "Windows 2017.2".
+
+Cleaned up and simplified the module-level code support. These changes 
+are in preparation for the eventual removal of the legacy MLC support 
+(deferred execution), replaced by the new MLC architecture which executes 
+the MLC as a table is loaded (DSDT/SSDTs).
+
+Changed a compile-time option to a runtime option. Changes the option to 
+ignore ACPI table load-time package resolution errors into a runtime 
+option. Used only for platforms that generate many AE_NOT_FOUND errors 
+during boot. AcpiGbl_IgnorePackageResolutionErrors.
+
+Fixed the ACPI_ERROR_NAMESPACE macro. This change involves putting some 
+ACPI_ERROR_NAMESPACE parameters inside macros. By doing so, we avoid 
+compilation errors from unused variables (seen with some compilers).
+
+
+2) iASL Compiler/Disassembler and Tools:
+
+ASLTS: parallelized execution in order to achieve an (approximately) 2X 
+performance increase.
+
+ASLTS: Updated to use the iASL __LINE__ and __METHOD__ macros. Improves 
+error reporting.
+
+----------------------------------------
+09 February 2018. Summary of changes for version 20180209:
+
+
+1) ACPICA kernel-resident subsystem:
+
+Completed the final integration of the recent changes to Package Object 
+handling and the module-level AML code support. This allows forward 
+references from individual package elements when the package object is 
+declared from within module-level code blocks. Provides compatibility 
+with other ACPI implementations.
+
+The new architecture for the AML module-level code has been completed and 
+is now the default for the ACPICA code. This new architecture executes 
+the module-level code in-line as the ACPI table is loaded/parsed instead 
+of the previous architecture which deferred this code until after the 
+table was fully loaded. This solves some ASL code ordering issues and 
+provides compatibility with other ACPI implementations. At this time, 
+there is an option to fallback to the earlier architecture, but this 
+support is deprecated and is planned to be completely removed later this 
+year.
+
+Added a compile-time option to ignore AE_NOT_FOUND exceptions during 
+resolution of named reference elements within Package objects. Although 
+this is potentially a serious problem, it can generate a lot of 
+noise/errors on platforms whose firmware carries around a bunch of unused 
+Package objects. To disable these errors, define 
+ACPI_IGNORE_PACKAGE_RESOLUTION_ERRORS in the OS-specific header. All 
+errors are always reported for ACPICA applications such as AcpiExec.
+
+Fixed a regression related to the explicit type-conversion AML operators 
+(ToXXXX). The regression was introduced early in 2017 but was not seen 
+until recently because these operators are not fully supported by other 
+ACPI implementations and are thus rarely used by firmware developers. The 
+operators are defined by the ACPI specification to not implement the 
+"implicit result object conversion". The regression incorrectly 
+introduced this object conversion for the following explicit conversion 
+operators:
+    ToInteger
+    ToString
+    ToBuffer
+    ToDecimalString
+    ToHexString
+    ToBCD
+    FromBCD
+
+
+2) iASL Compiler/Disassembler and Tools:
+
+iASL: Fixed a problem with the compiler constant folding feature as 
+related to the ToXXXX explicit conversion operators. These operators do 
+not support the "implicit result object conversion" by definition. Thus, 
+ASL expressions that use these operators cannot be folded to a simple 
+Store operator because Store implements the implicit conversion. This 
+change uses the CopyObject operator for the ToXXXX operator folding 
+instead. CopyObject is defined to not implement implicit result 
+conversions and is thus appropriate for folding the ToXXXX operators.
+
+iASL: Changed the severity of an error condition to a simple warning for 
+the case where a symbol is declared both locally and as an external 
+symbol. This accommodates existing ASL code.
+
+AcpiExec: The -ep option to enable the new architecture for module-level 
+code has been removed. It is replaced by the -dp option which instead has 
+the opposite effect: it disables the new architecture (the default) and 
+enables the legacy architecture. When the legacy code is removed in the 
+future, the -dp option will be removed also.
+
+----------------------------------------
+05 January 2018. Summary of changes for version 20180105:
+
+
+1) ACPICA kernel-resident subsystem:
+
+Updated all copyrights to 2018. This affects all source code modules.
+
+Fixed a possible build error caused by an unresolved reference to the 
+AcpiUtSafeStrncpy function.
+
+Removed NULL pointer arithmetic in the various pointer manipulation 
+macros. All "(void *) NULL" constructs are converted to "(void *) 0". 
+This eliminates warnings/errors in newer C compilers. Jung-uk Kim.
+
+Added support for A32 ABI compilation, which uses the ILP32 model. Anuj 
+Mittal.
+
+
+2) iASL Compiler/Disassembler and Tools:
+
+ASLTS: Updated all copyrights to 2018.
+
+Tools: Updated all signon copyrights to 2018.
+
+AcpiXtract: Fixed a regression related to ACPI table signatures where the 
+signature was truncated to 3 characters (instead of 4).
+
+AcpiExec: Restore the original terminal mode after the use of the -v and 
+-vd options.
+
+ASLTS: Deployed the iASL __METHOD__ macro across the test suite.
+
+----------------------------------------
+14 December 2017. Summary of changes for version 20171214:
+
+
+1) ACPICA kernel-resident subsystem:
+
+Fixed a regression in the external (public) AcpiEvaluateObjectTyped 
+interface where the optional "pathname" argument had inadvertently become 
+a required argument returning an error if omitted (NULL pointer 
+argument).
+
+Fixed two possible memory leaks related to the recently developed "late 
+resolution" of reference objects within ASL Package Object definitions.
+
+Added two recently defined _OSI strings: "Windows 2016" and "Windows 
+2017". Mario Limonciello.
+
+Implemented and deployed a safer version of the C library function 
+strncpy:  AcpiUtSafeStrncpy. The intent is to at least prevent the 
+creation of unterminated strings as a possible result of a standard 
+strncpy.
+
+Cleaned up and restructured the global variable file (acglobal.h). There 
+are many changes, but no functional changes.
+
+
+2) iASL Compiler/Disassembler and Tools:
+
+iASL Table Compiler: Fixed a problem with the DBG2 ACPI table where the 
+optional OemData field at the end of the table was incorrectly required 
+for proper compilation. It is now correctly an optional field.
+
+ASLTS: The entire suite was converted from standard ASL to the ASL+ 
+language, using the ASL-to-ASL+ converter which is integrated into the 
+iASL compiler. A binary compare of all output files has verified the 
+correctness of the conversion.
+
+iASL: Fixed the source code build for platforms where "char" is unsigned. 
+This affected the iASL lexer only. Jung-uk Kim.
+
+----------------------------------------
+10 November 2017. Summary of changes for version 20171110:
+
+
+1) ACPICA kernel-resident subsystem:
+
+This release implements full support for ACPI 6.2A:
+    NFIT - Added a new subtable, "Platform Capabilities Structure"
+No other changes to ACPICA were required, since ACPI 6.2A is primarily an 
+errata release of the specification.
+
+Other ACPI table changes:
+    IORT: Added the SMMUv3 Device ID mapping index. Hanjun Guo
+    PPTT: Added cache attribute flag definitions to actbl1.h. Jeremy 
+Linton
+
+Utilities: Modified the string/integer conversion functions to use 
+internal 64-bit divide support instead of a native divide. On 32-bit 
+platforms, a 64-bit divide typically requires a library function which 
+may not be present in the build (kernel or otherwise).
+
+Implemented a targeted error message for timeouts returned from the 
+Embedded Controller device driver. This is seen frequently enough to 
+special-case an AE_TIME returned from an EC operation region access:
+    "Timeout from EC hardware or EC device driver"
+
+Changed the "ACPI Exception" message prefix to "ACPI Error" so that all 
+runtime error messages have the identical prefix.
+
+
+2) iASL Compiler/Disassembler and Tools:
+
+AcpiXtract: Fixed a problem with table header detection within the 
+acpidump file. Processing a table could be ended early if a 0x40 (@) 
+appears in the original binary table, resulting in the @ symbol appearing 
+in the decoded ASCII field at the end of the acpidump text line. The 
+symbol caused acpixtract to incorrectly think it had reached the end of 
+the current table and the beginning of a new table.
+
+AcpiXtract: Added an option (-f) to ignore some errors during table 
+extraction. This initial implementation ignores non-ASCII and non-
+printable characters found in the acpidump text file.
+
+TestSuite(ASLTS)/AcpiExec: Fixed and restored the memory usage statistics 
+for ASLTS. This feature is used to track memory allocations from 
+different memory caches within the ACPICA code. At the end of an ASLTS 
+run, these memory statistics are recorded and stored in a log file.
+
+Debugger (user-space version): Implemented a simple "Background" command. 
+Creates a new thread to execute a control method in the background, while 
+control returns to the debugger prompt to allow additional commands.
+    Syntax: Background <Namepath> [Arguments]
+
+----------------------------------------
+29 September 2017. Summary of changes for version 20170929:
+
+
+1) ACPICA kernel-resident subsystem:
+
+Redesigned and implemented an improved ASL While() loop timeout 
+mechanism. This mechanism is used to prevent infinite loops in the kernel 
+AML interpreter caused by either non-responsive hardware or incorrect AML 
+code. The new implementation uses AcpiOsGetTimer instead of a simple 
+maximum loop count, and is thus more accurate and constant across 
+different machines. The default timeout is currently 30 seconds, but this 
+may be adjusted later.
+
+Renamed the ACPI_AML_INFINITE_LOOP exception to AE_AML_LOOP_TIMEOUT to 
+better reflect the new implementation of the loop timeout mechanism.
+
+Updated the AcpiGetTimerDuration interface to cleanup the 64-bit support 
+and to fix an off-by-one error. Jung-uk Kim.
+
+Fixed an EFI build problem by updating the makefiles to for a new file 
+that was added, utstrsuppt.c
+
+
+2) iASL Compiler/Disassembler and Tools:
+
+Implemented full support for the PDTT, SDEV, and TPM2 ACPI tables. This 
+includes support in the table disassembler, compiler, and template 
+generator.
+
+iASL: Added an exception for an illegal type of recursive method 
+invocation. If a method creates named objects, the first recursive call 
+will fail at runtime. This change adds an error detection at compile time 
+to catch the problem up front. Note: Marking such a method as 
+"serialized" will not help with this problem, because the same thread can 
+acquire the method mutex more than once. Example compiler and runtime 
+output:
+
+    Method (MTH1)
+    {
+        Name (INT1, 1)
+        MTH1 ()
+    }
+
+    dsdt.asl     22: MTH1 ()
+    Error    6152 -  ^ Illegal recursive call to method
+                       that creates named objects (MTH1)
+
+Previous runtime exception:
+    ACPI Error: [INT1] Namespace lookup failure,
+    AE_ALREADY_EXISTS (20170831/dswload2-465)
+
+iASL: Updated support for External() opcodes to improve namespace 
+management and error detection. These changes are related to issues seen 
+with multiple-segment namespace pathnames within External declarations, 
+such as below:
+
+    External(\_SB.PCI0.GFX0, DeviceObj)
+    External(\_SB.PCI0.GFX0.ALSI)
+
+iASL: Implemented support for multi-line error/warning messages. This 
+enables more detailed and helpful error messages as below, from the 
+initial deployment for the duplicate names error:
+
+    DSDT.iiii   1692:       Device(PEG2) {
+    Error    6074 -                  ^ Name already exists in scope 
+(PEG2)
+
+        Original name creation/declaration below:
+        DSDT.iiii     93:   External(\_SB.PCI0.PEG2, DeviceObj)
+
+AcpiXtract: Added additional flexibility to support differing input hex 
+dump formats. Specifically, hex dumps that contain partial disassembly 
+and/or comments within the ACPI table data definition. There exist some 
+dump utilities seen in the field that create this type of hex dump (such 
+as Simics). For example:
+
+    DSDT @ 0xdfffd0c0 (10999 bytes)
+        Signature DSDT
+        Length 10999
+        Revision 1
+        Checksum 0xf3 (Ok)
+        OEM_ID BXPC
+        OEM_table_id BXDSDT
+        OEM_revision 1
+        Creator_id 1280593481
+        Creator_revision 537399345
+      0000: 44 53 44 54 f7 2a 00 00 01 f3 42 58 50 43 00 00
+      ...
+      2af0: 5f 4c 30 46 00 a4 01
+
+Test suite: Miscellaneous changes/fixes:
+    More cleanup and simplification of makefiles
+    Continue compilation of test cases after a compile failure
+    Do not perform binary compare unless both files actually exist
+
+iASL: Performed some code/module restructuring. Moved all memory 
+allocation functions to new modules. Two new files, aslallocate.c and 
+aslcache.c
+
 ----------------------------------------
 31 August 2017. Summary of changes for version 20170831:
 
index 9707be3..a8f9fed 100644 (file)
@@ -35,7 +35,7 @@
 .SUFFIXES :
 PROGS = acpibin acpidump acpiexamples acpiexec acpihelp acpinames acpisrc acpixtract iasl
 HOST ?= _CYGWIN
-CC =    gcc
+CC ?=    gcc
 
 #
 # Common defines
index 681442c..9118397 100644 (file)
@@ -45,9 +45,11 @@ OBJECTS = \
        $(OBJDIR)/aeexception.o\
        $(OBJDIR)/aehandlers.o\
        $(OBJDIR)/aeinitfile.o\
+       $(OBJDIR)/aeinstall.o\
        $(OBJDIR)/aemain.o\
        $(OBJDIR)/aeregion.o\
        $(OBJDIR)/aetables.o\
+       $(OBJDIR)/aetests.o\
        $(OBJDIR)/ahids.o\
        $(OBJDIR)/ahuuids.o\
        $(OBJDIR)/cmfsize.o\
@@ -140,6 +142,7 @@ OBJECTS = \
        $(OBJDIR)/hwpci.o\
        $(OBJDIR)/hwregs.o\
        $(OBJDIR)/hwsleep.o\
+       $(OBJDIR)/hwtimer.o\
        $(OBJDIR)/hwvalid.o\
        $(OBJDIR)/hwxface.o\
        $(OBJDIR)/hwxfsleep.o\
index 7bc69e8..db87d88 100644 (file)
@@ -113,6 +113,7 @@ OBJECTS = \
        $(OBJDIR)/utmath.o\
        $(OBJDIR)/utmisc.o\
        $(OBJDIR)/utmutex.o\
+       $(OBJDIR)/utnonansi.o\
        $(OBJDIR)/utobject.o\
        $(OBJDIR)/utosi.o\
        $(OBJDIR)/utownerid.o\
index 02390ea..98dac71 100644 (file)
@@ -51,9 +51,11 @@ OBJECTS = \
        $(OBJDIR)/ahpredef.o\
        $(OBJDIR)/ahtable.o\
        $(OBJDIR)/ahuuids.o\
+       $(OBJDIR)/aslallocate.o\
        $(OBJDIR)/aslanalyze.o\
        $(OBJDIR)/aslascii.o\
        $(OBJDIR)/aslbtypes.o\
+       $(OBJDIR)/aslcache.o\
        $(OBJDIR)/aslcodegen.o\
        $(OBJDIR)/aslcompile.o\
        $(OBJDIR)/asldebug.o\
@@ -126,7 +128,13 @@ OBJECTS = \
        $(OBJDIR)/dmtable.o\
        $(OBJDIR)/dmtables.o\
        $(OBJDIR)/dmtbdump.o\
+       $(OBJDIR)/dmtbdump1.o\
+       $(OBJDIR)/dmtbdump2.o\
+       $(OBJDIR)/dmtbdump3.o\
        $(OBJDIR)/dmtbinfo.o\
+       $(OBJDIR)/dmtbinfo1.o\
+       $(OBJDIR)/dmtbinfo2.o\
+       $(OBJDIR)/dmtbinfo3.o\
        $(OBJDIR)/dmutils.o\
        $(OBJDIR)/dmwalk.o\
        $(OBJDIR)/dsargs.o\
index a4e227a..8aabeb4 100644 (file)
@@ -8,7 +8,7 @@
  *
  * 1. Copyright Notice
  *
- * Some or all of this work - Copyright (c) 1999 - 2017, Intel Corp.
+ * Some or all of this work - Copyright (c) 1999 - 2018, Intel Corp.
  * All rights reserved.
  *
  * 2. License
index eda4ea7..d0e1e0a 100644 (file)
@@ -8,7 +8,7 @@
  *
  * 1. Copyright Notice
  *
- * Some or all of this work - Copyright (c) 1999 - 2017, Intel Corp.
+ * Some or all of this work - Copyright (c) 1999 - 2018, Intel Corp.
  * All rights reserved.
  *
  * 2. License
index ac96156..5e6dd89 100644 (file)
@@ -8,7 +8,7 @@
  *
  * 1. Copyright Notice
  *
- * Some or all of this work - Copyright (c) 1999 - 2017, Intel Corp.
+ * Some or all of this work - Copyright (c) 1999 - 2018, Intel Corp.
  * All rights reserved.
  *
  * 2. License
@@ -314,7 +314,7 @@ FlGenerateFilename (
      * Copy the original filename to a new buffer. Leave room for the worst
      * case where we append the suffix, an added dot and the null terminator.
      */
-    NewFilename = UtStringCacheCalloc ((ACPI_SIZE)
+    NewFilename = UtLocalCacheCalloc ((ACPI_SIZE)
         strlen (InputFilename) + strlen (Suffix) + 2);
     strcpy (NewFilename, InputFilename);
 
@@ -358,7 +358,7 @@ FlStrdup (
     char                *NewString;
 
 
-    NewString = UtStringCacheCalloc ((ACPI_SIZE) strlen (String) + 1);
+    NewString = UtLocalCacheCalloc ((ACPI_SIZE) strlen (String) + 1);
     strcpy (NewString, String);
     return (NewString);
 }
@@ -454,3 +454,59 @@ FlSplitInputPathname (
 
     return (AE_OK);
 }
+
+
+/*******************************************************************************
+ *
+ * FUNCTION:    FlGetFileBasename
+ *
+ * PARAMETERS:  FilePathname            - File path to be split
+ *
+ * RETURN:      The extracted base name of the file, in upper case
+ *
+ * DESCRIPTION: Extract the file base name (the file name with no extension)
+ *              from the input pathname.
+ *
+ *              Note: Any backslashes in the pathname should be previously
+ *              converted to forward slashes before calling this function.
+ *
+ ******************************************************************************/
+
+char *
+FlGetFileBasename (
+    char                    *FilePathname)
+{
+    char                    *FileBasename;
+    char                    *Substring;
+
+
+    /* Backup to last slash or colon */
+
+    Substring = strrchr (FilePathname, '/');
+    if (!Substring)
+    {
+        Substring = strrchr (FilePathname, ':');
+    }
+
+    /* Extract the full filename (base + extension) */
+
+    if (Substring)
+    {
+        FileBasename = FlStrdup (Substring + 1);
+    }
+    else
+    {
+        FileBasename = FlStrdup (FilePathname);
+    }
+
+    /* Remove the filename extension if present */
+
+    Substring = strchr (FileBasename, '.');
+    if (Substring)
+    {
+        *Substring = 0;
+    }
+
+    AcpiUtStrupr (FileBasename);
+    return (FileBasename);
+}
index e6f0e0f..883039a 100644 (file)
@@ -8,7 +8,7 @@
  *
  * 1. Copyright Notice
  *
- * Some or all of this work - Copyright (c) 1999 - 2017, Intel Corp.
+ * Some or all of this work - Copyright (c) 1999 - 2018, Intel Corp.
  * All rights reserved.
  *
  * 2. License
@@ -457,9 +457,9 @@ AdDisassembleOneTable (
      * (.xxx) file produced from the converter in case if
      * it fails to get deleted.
      */
-    if (Gbl_CaptureComments)
+    if (AcpiGbl_CaptureComments)
     {
-        strncpy (Table->Signature, AcpiGbl_TableSig, 4);
+        strncpy (Table->Signature, AcpiGbl_TableSig, ACPI_NAME_SIZE);
     }
 #endif
 
index e7bb924..6463ee5 100644 (file)
@@ -8,7 +8,7 @@
  *
  * 1. Copyright Notice
  *
- * Some or all of this work - Copyright (c) 1999 - 2017, Intel Corp.
+ * Some or all of this work - Copyright (c) 1999 - 2018, Intel Corp.
  * All rights reserved.
  *
  * 2. License
index 701d9f4..c519aa6 100644 (file)
@@ -8,7 +8,7 @@
  *
  * 1. Copyright Notice
  *
- * Some or all of this work - Copyright (c) 1999 - 2017, Intel Corp.
+ * Some or all of this work - Copyright (c) 1999 - 2018, Intel Corp.
  * All rights reserved.
  *
  * 2. License
index 5cd1064..0a55872 100644 (file)
@@ -8,7 +8,7 @@
  *
  * 1. Copyright Notice
  *
- * Some or all of this work - Copyright (c) 1999 - 2017, Intel Corp.
+ * Some or all of this work - Copyright (c) 1999 - 2018, Intel Corp.
  * All rights reserved.
  *
  * 2. License
index 7aee3c6..740ab53 100644 (file)
@@ -8,7 +8,7 @@
  *
  * 1. Copyright Notice
  *
- * Some or all of this work - Copyright (c) 1999 - 2017, Intel Corp.
+ * Some or all of this work - Copyright (c) 1999 - 2018, Intel Corp.
  * All rights reserved.
  *
  * 2. License
@@ -232,6 +232,7 @@ const AH_TABLE      Gbl_AcpiSupportedTables[] =
     {ACPI_SIG_MTMR, "MID Timer Table"},
     {ACPI_SIG_NFIT, "NVDIMM Firmware Interface Table"},
     {ACPI_SIG_PCCT, "Platform Communications Channel Table"},
+    {ACPI_SIG_PDTT, "Platform Debug Trigger Table"},
     {ACPI_SIG_PMTT, "Platform Memory Topology Table"},
     {ACPI_SIG_PPTT, "Processor Properties Topology Table"},
     {ACPI_SIG_RASF, "RAS Features Table"},
@@ -240,6 +241,7 @@ const AH_TABLE      Gbl_AcpiSupportedTables[] =
     {ACPI_SIG_S3PT, "S3 Performance Table"},
     {ACPI_SIG_SBST, "Smart Battery Specification Table"},
     {ACPI_SIG_SDEI, "Software Delegated Exception Interface Table"},
+    {ACPI_SIG_SDEV, "Secure Devices table"},
     {ACPI_SIG_SLIC, "Software Licensing Description Table"},
     {ACPI_SIG_SLIT, "System Locality Information Table"},
     {ACPI_SIG_SPCR, "Serial Port Console Redirection table"},
index 6e018a3..f99578c 100644 (file)
@@ -8,7 +8,7 @@
  *
  * 1. Copyright Notice
  *
- * Some or all of this work - Copyright (c) 1999 - 2017, Intel Corp.
+ * Some or all of this work - Copyright (c) 1999 - 2018, Intel Corp.
  * All rights reserved.
  *
  * 2. License
index 2e3197c..a385464 100644 (file)
@@ -8,7 +8,7 @@
  *
  * 1. Copyright Notice
  *
- * Some or all of this work - Copyright (c) 1999 - 2017, Intel Corp.
+ * Some or all of this work - Copyright (c) 1999 - 2018, Intel Corp.
  * All rights reserved.
  *
  * 2. License
index 6ae3c37..8aab480 100644 (file)
@@ -8,7 +8,7 @@
  *
  * 1. Copyright Notice
  *
- * Some or all of this work - Copyright (c) 1999 - 2017, Intel Corp.
+ * Some or all of this work - Copyright (c) 1999 - 2018, Intel Corp.
  * All rights reserved.
  *
  * 2. License
index 5ba0f6b..f3b08b6 100644 (file)
@@ -8,7 +8,7 @@
  *
  * 1. Copyright Notice
  *
- * Some or all of this work - Copyright (c) 1999 - 2017, Intel Corp.
+ * Some or all of this work - Copyright (c) 1999 - 2018, Intel Corp.
  * All rights reserved.
  *
  * 2. License
index 1641cbf..f04ec74 100644 (file)
@@ -8,7 +8,7 @@
  *
  * 1. Copyright Notice
  *
- * Some or all of this work - Copyright (c) 1999 - 2017, Intel Corp.
+ * Some or all of this work - Copyright (c) 1999 - 2018, Intel Corp.
  * All rights reserved.
  *
  * 2. License
@@ -543,6 +543,10 @@ AcpiDmIsSwitchBlock (
      * statement, so check for it.
      */
     CurrentOp = StoreOp->Common.Next->Common.Next;
+    if (!CurrentOp)
+    {
+        return (FALSE);
+    }
     if (CurrentOp->Common.AmlOpcode == AML_ELSE_OP)
     {
         CurrentOp = CurrentOp->Common.Next;
index 38248c2..07df5d3 100644 (file)
@@ -8,7 +8,7 @@
  *
  * 1. Copyright Notice
  *
- * Some or all of this work - Copyright (c) 1999 - 2017, Intel Corp.
+ * Some or all of this work - Copyright (c) 1999 - 2018, Intel Corp.
  * All rights reserved.
  *
  * 2. License
 #include "acdisasm.h"
 #include "actables.h"
 #include "aslcompiler.h"
-#include "dtcompiler.h"
 
 /* This module used for application-level code only */
 
@@ -290,9 +289,9 @@ static const char           *AcpiDmHestSubnames[] =
     "IA-32 Machine Check Exception",
     "IA-32 Corrected Machine Check",
     "IA-32 Non-Maskable Interrupt",
-    "Unknown SubTable Type",        /* 3 - Reserved */
-    "Unknown SubTable Type",        /* 4 - Reserved */
-    "Unknown SubTable Type",        /* 5 - Reserved */
+    "Unknown Subtable Type",        /* 3 - Reserved */
+    "Unknown Subtable Type",        /* 4 - Reserved */
+    "Unknown Subtable Type",        /* 5 - Reserved */
     "PCI Express Root Port AER",
     "PCI Express AER (AER Endpoint)",
     "PCI Express/PCI-X Bridge AER",
@@ -357,6 +356,7 @@ static const char           *AcpiDmNfitSubnames[] =
     "NVDIMM Control Region",            /* ACPI_NFIT_TYPE_CONTROL_REGION */
     "NVDIMM Block Data Window Region",  /* ACPI_NFIT_TYPE_DATA_REGION */
     "Flush Hint Address",               /* ACPI_NFIT_TYPE_FLUSH_ADDRESS */
+    "Platform Capabilities",            /* ACPI_NFIT_TYPE_CAPABILITIES */
     "Unknown Subtable Type"             /* Reserved */
 };
 
@@ -374,7 +374,7 @@ static const char           *AcpiDmPmttSubnames[] =
 {
     "Socket",                       /* ACPI_PMTT_TYPE_SOCKET */
     "Memory Controller",            /* ACPI_PMTT_TYPE_CONTROLLER */
-    "Physical Component (DIMM)",    /* ACPI_PMTT_TYPE_DIMM  */
+    "Physical Component (DIMM)",    /* ACPI_PMTT_TYPE_DIMM */
     "Unknown Subtable Type"         /* Reserved */
 };
 
@@ -382,7 +382,14 @@ static const char           *AcpiDmPpttSubnames[] =
 {
     "Processor Hierarchy Node",     /* ACPI_PPTT_TYPE_PROCESSOR */
     "Cache Type",                   /* ACPI_PPTT_TYPE_CACHE */
-    "ID",                           /* ACPI_PMTT_TYPE_ID  */
+    "ID",                           /* ACPI_PPTT_TYPE_ID */
+    "Unknown Subtable Type"         /* Reserved */
+};
+
+static const char           *AcpiDmSdevSubnames[] =
+{
+    "Namespace Device",             /* ACPI_SDEV_TYPE_NAMESPACE_DEVICE */
+    "PCIe Endpoint Device",         /* ACPI_SDEV_TYPE_PCIE_ENDPOINT_DEVICE */
     "Unknown Subtable Type"         /* Reserved */
 };
 
@@ -396,6 +403,23 @@ static const char           *AcpiDmSratSubnames[] =
     "Unknown Subtable Type"         /* Reserved */
 };
 
+static const char           *AcpiDmTpm2Subnames[] =
+{
+    "Illegal Start Method value",
+    "Reserved",
+    "ACPI Start Method",
+    "Reserved",
+    "Reserved",
+    "Reserved",
+    "Memory Mapped I/O",
+    "Command Response Buffer",
+    "Command Response Buffer with ACPI Start Method",
+    "Reserved",
+    "Reserved",
+    "Command Response Buffer with ARM SMC",
+    "Unknown Subtable Type"         /* Reserved */
+};
+
 static const char           *AcpiDmIvrsSubnames[] =
 {
     "Hardware Definition Block",
@@ -487,6 +511,7 @@ const ACPI_DMTABLE_DATA     AcpiDmTableData[] =
     {ACPI_SIG_MTMR, NULL,                   AcpiDmDumpMtmr, DtCompileMtmr,  TemplateMtmr},
     {ACPI_SIG_NFIT, AcpiDmTableInfoNfit,    AcpiDmDumpNfit, DtCompileNfit,  TemplateNfit},
     {ACPI_SIG_PCCT, AcpiDmTableInfoPcct,    AcpiDmDumpPcct, DtCompilePcct,  TemplatePcct},
+    {ACPI_SIG_PDTT, AcpiDmTableInfoPdtt,    AcpiDmDumpPdtt, DtCompilePdtt,  TemplatePdtt},
     {ACPI_SIG_PMTT, NULL,                   AcpiDmDumpPmtt, DtCompilePmtt,  TemplatePmtt},
     {ACPI_SIG_PPTT, NULL,                   AcpiDmDumpPptt, DtCompilePptt,  TemplatePptt},
     {ACPI_SIG_RASF, AcpiDmTableInfoRasf,    NULL,           NULL,           TemplateRasf},
@@ -494,6 +519,7 @@ const ACPI_DMTABLE_DATA     AcpiDmTableData[] =
     {ACPI_SIG_S3PT, NULL,                   NULL,           NULL,           TemplateS3pt},
     {ACPI_SIG_SBST, AcpiDmTableInfoSbst,    NULL,           NULL,           TemplateSbst},
     {ACPI_SIG_SDEI, AcpiDmTableInfoSdei,    NULL,           NULL,           TemplateSdei},
+    {ACPI_SIG_SDEV, AcpiDmTableInfoSdev,    AcpiDmDumpSdev, DtCompileSdev,  TemplateSdev},
     {ACPI_SIG_SLIC, NULL,                   AcpiDmDumpSlic, DtCompileSlic,  TemplateSlic},
     {ACPI_SIG_SLIT, NULL,                   AcpiDmDumpSlit, DtCompileSlit,  TemplateSlit},
     {ACPI_SIG_SPCR, AcpiDmTableInfoSpcr,    NULL,           NULL,           TemplateSpcr},
@@ -501,7 +527,7 @@ const ACPI_DMTABLE_DATA     AcpiDmTableData[] =
     {ACPI_SIG_SRAT, NULL,                   AcpiDmDumpSrat, DtCompileSrat,  TemplateSrat},
     {ACPI_SIG_STAO, NULL,                   AcpiDmDumpStao, DtCompileStao,  TemplateStao},
     {ACPI_SIG_TCPA, NULL,                   AcpiDmDumpTcpa, DtCompileTcpa,  TemplateTcpa},
-    {ACPI_SIG_TPM2, AcpiDmTableInfoTpm2,    NULL,           NULL,           TemplateTpm2},
+    {ACPI_SIG_TPM2, AcpiDmTableInfoTpm2,    AcpiDmDumpTpm2, DtCompileTpm2,  TemplateTpm2},
     {ACPI_SIG_UEFI, AcpiDmTableInfoUefi,    NULL,           DtCompileUefi,  TemplateUefi},
     {ACPI_SIG_VRTC, AcpiDmTableInfoVrtc,    AcpiDmDumpVrtc, DtCompileVrtc,  TemplateVrtc},
     {ACPI_SIG_WAET, AcpiDmTableInfoWaet,    NULL,           NULL,           TemplateWaet},
@@ -917,6 +943,7 @@ AcpiDmDumpTable (
         case ACPI_DMT_PCCT:
         case ACPI_DMT_PMTT:
         case ACPI_DMT_PPTT:
+        case ACPI_DMT_SDEV:
         case ACPI_DMT_SRAT:
         case ACPI_DMT_ASF:
         case ACPI_DMT_HESTNTYP:
@@ -948,6 +975,7 @@ AcpiDmDumpTable (
         case ACPI_DMT_NAME4:
         case ACPI_DMT_SIG:
         case ACPI_DMT_LPIT:
+        case ACPI_DMT_TPM2:
 
             ByteLength = 4;
             break;
@@ -1583,6 +1611,20 @@ AcpiDmDumpTable (
                 CurrentOffset, NULL);
             break;
 
+        case ACPI_DMT_SDEV:
+
+            /* SDEV subtable types */
+
+            Temp8 = *Target;
+            if (Temp8 > ACPI_SDEV_TYPE_RESERVED)
+            {
+                Temp8 = ACPI_SDEV_TYPE_RESERVED;
+            }
+
+            AcpiOsPrintf (UINT8_FORMAT, *Target,
+                AcpiDmSdevSubnames[Temp8]);
+            break;
+
         case ACPI_DMT_SRAT:
 
             /* SRAT subtable types */
@@ -1597,6 +1639,21 @@ AcpiDmDumpTable (
                 AcpiDmSratSubnames[Temp8]);
             break;
 
+        case ACPI_DMT_TPM2:
+
+            /* TPM2 Start Method types */
+
+            Temp8 = *Target;
+            if (Temp8 > ACPI_TPM2_RESERVED)
+            {
+                Temp8 = ACPI_TPM2_RESERVED;
+            }
+
+            AcpiOsPrintf (UINT8_FORMAT, *Target,
+                AcpiDmTpm2Subnames[Temp8]);
+            break;
+
+
         case ACPI_DMT_FADTPM:
 
             /* FADT Preferred PM Profile names */
index 0ec69ab..293b3d8 100644 (file)
@@ -8,7 +8,7 @@
  *
  * 1. Copyright Notice
  *
- * Some or all of this work - Copyright (c) 1999 - 2017, Intel Corp.
+ * Some or all of this work - Copyright (c) 1999 - 2018, Intel Corp.
  * All rights reserved.
  *
  * 2. License
@@ -314,7 +314,7 @@ AdCreateTableHeader (
     /*
      * Print comments that come before this definition block.
      */
-    if (Gbl_CaptureComments)
+    if (AcpiGbl_CaptureComments)
     {
         ASL_CV_PRINT_ONE_COMMENT(AcpiGbl_ParseOpRoot,AML_COMMENT_STANDARD, NULL, 0);
     }
@@ -517,7 +517,7 @@ AdParseTable (
     }
 
 #ifdef ACPI_ASL_COMPILER
-    if (Gbl_CaptureComments)
+    if (AcpiGbl_CaptureComments)
     {
         AcpiGbl_ParseOpRoot->Common.CvFilename = AcpiGbl_FileTreeRoot->Filename;
     }
index 9441ca4..cf2ed6d 100644 (file)
@@ -8,7 +8,7 @@
  *
  * 1. Copyright Notice
  *
- * Some or all of this work - Copyright (c) 1999 - 2017, Intel Corp.
+ * Some or all of this work - Copyright (c) 1999 - 2018, Intel Corp.
  * All rights reserved.
  *
  * 2. License
@@ -603,3548 +603,3 @@ AcpiDmValidateFadtLength (
         "found %X expected %X\n",
         Revision, Length, ExpectedLength);
 }
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpAsf
- *
- * PARAMETERS:  Table               - A ASF table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a ASF table
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpAsf (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    UINT32                  Offset = sizeof (ACPI_TABLE_HEADER);
-    ACPI_ASF_INFO           *SubTable;
-    ACPI_DMTABLE_INFO       *InfoTable;
-    ACPI_DMTABLE_INFO       *DataInfoTable = NULL;
-    UINT8                   *DataTable = NULL;
-    UINT32                  DataCount = 0;
-    UINT32                  DataLength = 0;
-    UINT32                  DataOffset = 0;
-    UINT32                  i;
-    UINT8                   Type;
-
-
-    /* No main table, only subtables */
-
-    SubTable = ACPI_ADD_PTR (ACPI_ASF_INFO, Table, Offset);
-    while (Offset < Table->Length)
-    {
-        /* Common subtable header */
-
-        Status = AcpiDmDumpTable (Table->Length, Offset, SubTable,
-            SubTable->Header.Length, AcpiDmTableInfoAsfHdr);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        /* The actual type is the lower 7 bits of Type */
-
-        Type = (UINT8) (SubTable->Header.Type & 0x7F);
-
-        switch (Type)
-        {
-        case ACPI_ASF_TYPE_INFO:
-
-            InfoTable = AcpiDmTableInfoAsf0;
-            break;
-
-        case ACPI_ASF_TYPE_ALERT:
-
-            InfoTable = AcpiDmTableInfoAsf1;
-            DataInfoTable = AcpiDmTableInfoAsf1a;
-            DataTable = ACPI_ADD_PTR (UINT8, SubTable, sizeof (ACPI_ASF_ALERT));
-            DataCount = ACPI_CAST_PTR (ACPI_ASF_ALERT, SubTable)->Alerts;
-            DataLength = ACPI_CAST_PTR (ACPI_ASF_ALERT, SubTable)->DataLength;
-            DataOffset = Offset + sizeof (ACPI_ASF_ALERT);
-            break;
-
-        case ACPI_ASF_TYPE_CONTROL:
-
-            InfoTable = AcpiDmTableInfoAsf2;
-            DataInfoTable = AcpiDmTableInfoAsf2a;
-            DataTable = ACPI_ADD_PTR (UINT8, SubTable, sizeof (ACPI_ASF_REMOTE));
-            DataCount = ACPI_CAST_PTR (ACPI_ASF_REMOTE, SubTable)->Controls;
-            DataLength = ACPI_CAST_PTR (ACPI_ASF_REMOTE, SubTable)->DataLength;
-            DataOffset = Offset + sizeof (ACPI_ASF_REMOTE);
-            break;
-
-        case ACPI_ASF_TYPE_BOOT:
-
-            InfoTable = AcpiDmTableInfoAsf3;
-            break;
-
-        case ACPI_ASF_TYPE_ADDRESS:
-
-            InfoTable = AcpiDmTableInfoAsf4;
-            DataTable = ACPI_ADD_PTR (UINT8, SubTable, sizeof (ACPI_ASF_ADDRESS));
-            DataLength = ACPI_CAST_PTR (ACPI_ASF_ADDRESS, SubTable)->Devices;
-            DataOffset = Offset + sizeof (ACPI_ASF_ADDRESS);
-            break;
-
-        default:
-
-            AcpiOsPrintf ("\n**** Unknown ASF subtable type 0x%X\n",
-                SubTable->Header.Type);
-            return;
-        }
-
-        Status = AcpiDmDumpTable (Table->Length, Offset, SubTable,
-            SubTable->Header.Length, InfoTable);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        /* Dump variable-length extra data */
-
-        switch (Type)
-        {
-        case ACPI_ASF_TYPE_ALERT:
-        case ACPI_ASF_TYPE_CONTROL:
-
-            for (i = 0; i < DataCount; i++)
-            {
-                AcpiOsPrintf ("\n");
-                Status = AcpiDmDumpTable (Table->Length, DataOffset,
-                    DataTable, DataLength, DataInfoTable);
-                if (ACPI_FAILURE (Status))
-                {
-                    return;
-                }
-
-                DataTable = ACPI_ADD_PTR (UINT8, DataTable, DataLength);
-                DataOffset += DataLength;
-            }
-            break;
-
-        case ACPI_ASF_TYPE_ADDRESS:
-
-            for (i = 0; i < DataLength; i++)
-            {
-                if (!(i % 16))
-                {
-                    AcpiDmLineHeader (DataOffset, 1, "Addresses");
-                }
-
-                AcpiOsPrintf ("%2.2X ", *DataTable);
-                DataTable++;
-                DataOffset++;
-
-                if (DataOffset > Table->Length)
-                {
-                    AcpiOsPrintf (
-                        "**** ACPI table terminates in the middle of a "
-                        "data structure! (ASF! table)\n");
-                    return;
-                }
-            }
-
-            AcpiOsPrintf ("\n");
-            break;
-
-        default:
-
-            break;
-        }
-
-        AcpiOsPrintf ("\n");
-
-        /* Point to next subtable */
-
-        if (!SubTable->Header.Length)
-        {
-            AcpiOsPrintf ("Invalid zero subtable header length\n");
-            return;
-        }
-
-        Offset += SubTable->Header.Length;
-        SubTable = ACPI_ADD_PTR (ACPI_ASF_INFO, SubTable,
-            SubTable->Header.Length);
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpCpep
- *
- * PARAMETERS:  Table               - A CPEP table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a CPEP. This table type consists
- *              of an open-ended number of subtables.
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpCpep (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    ACPI_CPEP_POLLING       *SubTable;
-    UINT32                  Length = Table->Length;
-    UINT32                  Offset = sizeof (ACPI_TABLE_CPEP);
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Length, 0, Table, 0, AcpiDmTableInfoCpep);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    /* Subtables */
-
-    SubTable = ACPI_ADD_PTR (ACPI_CPEP_POLLING, Table, Offset);
-    while (Offset < Table->Length)
-    {
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Length, Offset, SubTable,
-            SubTable->Header.Length, AcpiDmTableInfoCpep0);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        /* Point to next subtable */
-
-        Offset += SubTable->Header.Length;
-        SubTable = ACPI_ADD_PTR (ACPI_CPEP_POLLING, SubTable,
-            SubTable->Header.Length);
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpCsrt
- *
- * PARAMETERS:  Table               - A CSRT table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a CSRT. This table type consists
- *              of an open-ended number of subtables.
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpCsrt (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    ACPI_CSRT_GROUP         *SubTable;
-    ACPI_CSRT_SHARED_INFO   *SharedInfoTable;
-    ACPI_CSRT_DESCRIPTOR    *SubSubTable;
-    UINT32                  Length = Table->Length;
-    UINT32                  Offset = sizeof (ACPI_TABLE_CSRT);
-    UINT32                  SubOffset;
-    UINT32                  SubSubOffset;
-    UINT32                  InfoLength;
-
-
-    /* The main table only contains the ACPI header, thus already handled */
-
-    /* Subtables (Resource Groups) */
-
-    SubTable = ACPI_ADD_PTR (ACPI_CSRT_GROUP, Table, Offset);
-    while (Offset < Table->Length)
-    {
-        /* Resource group subtable */
-
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Length, Offset, SubTable,
-            SubTable->Length, AcpiDmTableInfoCsrt0);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        /* Shared info subtable (One per resource group) */
-
-        SubOffset = sizeof (ACPI_CSRT_GROUP);
-        SharedInfoTable = ACPI_ADD_PTR (ACPI_CSRT_SHARED_INFO, Table,
-            Offset + SubOffset);
-
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Length, Offset + SubOffset, SharedInfoTable,
-            sizeof (ACPI_CSRT_SHARED_INFO), AcpiDmTableInfoCsrt1);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        SubOffset += SubTable->SharedInfoLength;
-
-        /* Sub-Subtables (Resource Descriptors) */
-
-        SubSubTable = ACPI_ADD_PTR (ACPI_CSRT_DESCRIPTOR, Table,
-            Offset + SubOffset);
-
-        while ((SubOffset < SubTable->Length) &&
-              ((Offset + SubOffset) < Table->Length))
-        {
-            AcpiOsPrintf ("\n");
-            Status = AcpiDmDumpTable (Length, Offset + SubOffset, SubSubTable,
-                SubSubTable->Length, AcpiDmTableInfoCsrt2);
-            if (ACPI_FAILURE (Status))
-            {
-                return;
-            }
-
-            SubSubOffset = sizeof (ACPI_CSRT_DESCRIPTOR);
-
-            /* Resource-specific info buffer */
-
-            InfoLength = SubSubTable->Length - SubSubOffset;
-            if (InfoLength)
-            {
-                Status = AcpiDmDumpTable (Length,
-                    Offset + SubOffset + SubSubOffset, Table,
-                    InfoLength, AcpiDmTableInfoCsrt2a);
-                if (ACPI_FAILURE (Status))
-                {
-                    return;
-                }
-                SubSubOffset += InfoLength;
-            }
-
-            /* Point to next sub-subtable */
-
-            SubOffset += SubSubTable->Length;
-            SubSubTable = ACPI_ADD_PTR (ACPI_CSRT_DESCRIPTOR, SubSubTable,
-                SubSubTable->Length);
-        }
-
-        /* Point to next subtable */
-
-        Offset += SubTable->Length;
-        SubTable = ACPI_ADD_PTR (ACPI_CSRT_GROUP, SubTable,
-            SubTable->Length);
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpDbg2
- *
- * PARAMETERS:  Table               - A DBG2 table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a DBG2. This table type consists
- *              of an open-ended number of subtables.
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpDbg2 (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    ACPI_DBG2_DEVICE        *SubTable;
-    UINT32                  Length = Table->Length;
-    UINT32                  Offset = sizeof (ACPI_TABLE_DBG2);
-    UINT32                  i;
-    UINT32                  ArrayOffset;
-    UINT32                  AbsoluteOffset;
-    UINT8                   *Array;
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Length, 0, Table, 0, AcpiDmTableInfoDbg2);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    /* Subtables */
-
-    SubTable = ACPI_ADD_PTR (ACPI_DBG2_DEVICE, Table, Offset);
-    while (Offset < Table->Length)
-    {
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Length, Offset, SubTable,
-            SubTable->Length, AcpiDmTableInfoDbg2Device);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        /* Dump the BaseAddress array */
-
-        for (i = 0; i < SubTable->RegisterCount; i++)
-        {
-            ArrayOffset = SubTable->BaseAddressOffset +
-                (sizeof (ACPI_GENERIC_ADDRESS) * i);
-            AbsoluteOffset = Offset + ArrayOffset;
-            Array = (UINT8 *) SubTable + ArrayOffset;
-
-            Status = AcpiDmDumpTable (Length, AbsoluteOffset, Array,
-                SubTable->Length, AcpiDmTableInfoDbg2Addr);
-            if (ACPI_FAILURE (Status))
-            {
-                return;
-            }
-        }
-
-        /* Dump the AddressSize array */
-
-        for (i = 0; i < SubTable->RegisterCount; i++)
-        {
-            ArrayOffset = SubTable->AddressSizeOffset +
-                (sizeof (UINT32) * i);
-            AbsoluteOffset = Offset + ArrayOffset;
-            Array = (UINT8 *) SubTable + ArrayOffset;
-
-            Status = AcpiDmDumpTable (Length, AbsoluteOffset, Array,
-                SubTable->Length, AcpiDmTableInfoDbg2Size);
-            if (ACPI_FAILURE (Status))
-            {
-                return;
-            }
-        }
-
-        /* Dump the Namestring (required) */
-
-        AcpiOsPrintf ("\n");
-        ArrayOffset = SubTable->NamepathOffset;
-        AbsoluteOffset = Offset + ArrayOffset;
-        Array = (UINT8 *) SubTable + ArrayOffset;
-
-        Status = AcpiDmDumpTable (Length, AbsoluteOffset, Array,
-            SubTable->Length, AcpiDmTableInfoDbg2Name);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        /* Dump the OemData (optional) */
-
-        if (SubTable->OemDataOffset)
-        {
-            Status = AcpiDmDumpTable (Length, Offset + SubTable->OemDataOffset,
-                Table, SubTable->OemDataLength,
-                AcpiDmTableInfoDbg2OemData);
-            if (ACPI_FAILURE (Status))
-            {
-                return;
-            }
-        }
-
-        /* Point to next subtable */
-
-        Offset += SubTable->Length;
-        SubTable = ACPI_ADD_PTR (ACPI_DBG2_DEVICE, SubTable,
-            SubTable->Length);
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpDmar
- *
- * PARAMETERS:  Table               - A DMAR table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a DMAR. This table type consists
- *              of an open-ended number of subtables.
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpDmar (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    ACPI_DMAR_HEADER        *SubTable;
-    UINT32                  Length = Table->Length;
-    UINT32                  Offset = sizeof (ACPI_TABLE_DMAR);
-    ACPI_DMTABLE_INFO       *InfoTable;
-    ACPI_DMAR_DEVICE_SCOPE  *ScopeTable;
-    UINT32                  ScopeOffset;
-    UINT8                   *PciPath;
-    UINT32                  PathOffset;
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Length, 0, Table, 0, AcpiDmTableInfoDmar);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    /* Subtables */
-
-    SubTable = ACPI_ADD_PTR (ACPI_DMAR_HEADER, Table, Offset);
-    while (Offset < Table->Length)
-    {
-        /* Common subtable header */
-
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Length, Offset, SubTable,
-            SubTable->Length, AcpiDmTableInfoDmarHdr);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        AcpiOsPrintf ("\n");
-
-        switch (SubTable->Type)
-        {
-        case ACPI_DMAR_TYPE_HARDWARE_UNIT:
-
-            InfoTable = AcpiDmTableInfoDmar0;
-            ScopeOffset = sizeof (ACPI_DMAR_HARDWARE_UNIT);
-            break;
-
-        case ACPI_DMAR_TYPE_RESERVED_MEMORY:
-
-            InfoTable = AcpiDmTableInfoDmar1;
-            ScopeOffset = sizeof (ACPI_DMAR_RESERVED_MEMORY);
-            break;
-
-        case ACPI_DMAR_TYPE_ROOT_ATS:
-
-            InfoTable = AcpiDmTableInfoDmar2;
-            ScopeOffset = sizeof (ACPI_DMAR_ATSR);
-            break;
-
-        case ACPI_DMAR_TYPE_HARDWARE_AFFINITY:
-
-            InfoTable = AcpiDmTableInfoDmar3;
-            ScopeOffset = sizeof (ACPI_DMAR_RHSA);
-            break;
-
-        case ACPI_DMAR_TYPE_NAMESPACE:
-
-            InfoTable = AcpiDmTableInfoDmar4;
-            ScopeOffset = sizeof (ACPI_DMAR_ANDD);
-            break;
-
-        default:
-
-            AcpiOsPrintf ("\n**** Unknown DMAR subtable type 0x%X\n\n",
-                SubTable->Type);
-            return;
-        }
-
-        Status = AcpiDmDumpTable (Length, Offset, SubTable,
-            SubTable->Length, InfoTable);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        /*
-         * Dump the optional device scope entries
-         */
-        if ((SubTable->Type == ACPI_DMAR_TYPE_HARDWARE_AFFINITY) ||
-            (SubTable->Type == ACPI_DMAR_TYPE_NAMESPACE))
-        {
-            /* These types do not support device scopes */
-
-            goto NextSubtable;
-        }
-
-        ScopeTable = ACPI_ADD_PTR (ACPI_DMAR_DEVICE_SCOPE, SubTable, ScopeOffset);
-        while (ScopeOffset < SubTable->Length)
-        {
-            AcpiOsPrintf ("\n");
-            Status = AcpiDmDumpTable (Length, Offset + ScopeOffset, ScopeTable,
-                ScopeTable->Length, AcpiDmTableInfoDmarScope);
-            if (ACPI_FAILURE (Status))
-            {
-                return;
-            }
-            AcpiOsPrintf ("\n");
-
-            /* Dump the PCI Path entries for this device scope */
-
-            PathOffset = sizeof (ACPI_DMAR_DEVICE_SCOPE); /* Path entries start at this offset */
-
-            PciPath = ACPI_ADD_PTR (UINT8, ScopeTable,
-                sizeof (ACPI_DMAR_DEVICE_SCOPE));
-
-            while (PathOffset < ScopeTable->Length)
-            {
-                AcpiDmLineHeader ((PathOffset + ScopeOffset + Offset), 2,
-                    "PCI Path");
-                AcpiOsPrintf ("%2.2X,%2.2X\n", PciPath[0], PciPath[1]);
-
-                /* Point to next PCI Path entry */
-
-                PathOffset += 2;
-                PciPath += 2;
-                AcpiOsPrintf ("\n");
-            }
-
-            /* Point to next device scope entry */
-
-            ScopeOffset += ScopeTable->Length;
-            ScopeTable = ACPI_ADD_PTR (ACPI_DMAR_DEVICE_SCOPE,
-                ScopeTable, ScopeTable->Length);
-        }
-
-NextSubtable:
-        /* Point to next subtable */
-
-        Offset += SubTable->Length;
-        SubTable = ACPI_ADD_PTR (ACPI_DMAR_HEADER, SubTable,
-            SubTable->Length);
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpDrtm
- *
- * PARAMETERS:  Table               - A DRTM table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a DRTM.
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpDrtm (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    UINT32                  Offset;
-    ACPI_DRTM_VTABLE_LIST   *DrtmVtl;
-    ACPI_DRTM_RESOURCE_LIST *DrtmRl;
-    ACPI_DRTM_DPS_ID        *DrtmDps;
-    UINT32                  Count;
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Table->Length, 0, Table, 0,
-        AcpiDmTableInfoDrtm);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    Offset = sizeof (ACPI_TABLE_DRTM);
-
-    /* Sub-tables */
-
-    /* Dump ValidatedTable length */
-
-    DrtmVtl = ACPI_ADD_PTR (ACPI_DRTM_VTABLE_LIST, Table, Offset);
-    AcpiOsPrintf ("\n");
-    Status = AcpiDmDumpTable (Table->Length, Offset,
-        DrtmVtl, ACPI_OFFSET (ACPI_DRTM_VTABLE_LIST, ValidatedTables),
-        AcpiDmTableInfoDrtm0);
-    if (ACPI_FAILURE (Status))
-    {
-            return;
-    }
-
-    Offset += ACPI_OFFSET (ACPI_DRTM_VTABLE_LIST, ValidatedTables);
-
-    /* Dump Validated table addresses */
-
-    Count = 0;
-    while ((Offset < Table->Length) &&
-            (DrtmVtl->ValidatedTableCount > Count))
-    {
-        Status = AcpiDmDumpTable (Table->Length, Offset,
-            ACPI_ADD_PTR (void, Table, Offset), sizeof (UINT64),
-            AcpiDmTableInfoDrtm0a);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        Offset += sizeof (UINT64);
-        Count++;
-    }
-
-    /* Dump ResourceList length */
-
-    DrtmRl = ACPI_ADD_PTR (ACPI_DRTM_RESOURCE_LIST, Table, Offset);
-    AcpiOsPrintf ("\n");
-    Status = AcpiDmDumpTable (Table->Length, Offset,
-        DrtmRl, ACPI_OFFSET (ACPI_DRTM_RESOURCE_LIST, Resources),
-        AcpiDmTableInfoDrtm1);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    Offset += ACPI_OFFSET (ACPI_DRTM_RESOURCE_LIST, Resources);
-
-    /* Dump the Resource List */
-
-    Count = 0;
-    while ((Offset < Table->Length) &&
-           (DrtmRl->ResourceCount > Count))
-    {
-        Status = AcpiDmDumpTable (Table->Length, Offset,
-            ACPI_ADD_PTR (void, Table, Offset),
-            sizeof (ACPI_DRTM_RESOURCE), AcpiDmTableInfoDrtm1a);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        Offset += sizeof (ACPI_DRTM_RESOURCE);
-        Count++;
-    }
-
-    /* Dump DPS */
-
-    DrtmDps = ACPI_ADD_PTR (ACPI_DRTM_DPS_ID, Table, Offset);
-    AcpiOsPrintf ("\n");
-    (void) AcpiDmDumpTable (Table->Length, Offset,
-        DrtmDps, sizeof (ACPI_DRTM_DPS_ID), AcpiDmTableInfoDrtm2);
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpEinj
- *
- * PARAMETERS:  Table               - A EINJ table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a EINJ. This table type consists
- *              of an open-ended number of subtables.
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpEinj (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    ACPI_WHEA_HEADER        *SubTable;
-    UINT32                  Length = Table->Length;
-    UINT32                  Offset = sizeof (ACPI_TABLE_EINJ);
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Length, 0, Table, 0, AcpiDmTableInfoEinj);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    /* Subtables */
-
-    SubTable = ACPI_ADD_PTR (ACPI_WHEA_HEADER, Table, Offset);
-    while (Offset < Table->Length)
-    {
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Length, Offset, SubTable,
-            sizeof (ACPI_WHEA_HEADER), AcpiDmTableInfoEinj0);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        /* Point to next subtable (each subtable is of fixed length) */
-
-        Offset += sizeof (ACPI_WHEA_HEADER);
-        SubTable = ACPI_ADD_PTR (ACPI_WHEA_HEADER, SubTable,
-            sizeof (ACPI_WHEA_HEADER));
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpErst
- *
- * PARAMETERS:  Table               - A ERST table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a ERST. This table type consists
- *              of an open-ended number of subtables.
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpErst (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    ACPI_WHEA_HEADER        *SubTable;
-    UINT32                  Length = Table->Length;
-    UINT32                  Offset = sizeof (ACPI_TABLE_ERST);
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Length, 0, Table, 0, AcpiDmTableInfoErst);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    /* Subtables */
-
-    SubTable = ACPI_ADD_PTR (ACPI_WHEA_HEADER, Table, Offset);
-    while (Offset < Table->Length)
-    {
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Length, Offset, SubTable,
-            sizeof (ACPI_WHEA_HEADER), AcpiDmTableInfoErst0);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        /* Point to next subtable (each subtable is of fixed length) */
-
-        Offset += sizeof (ACPI_WHEA_HEADER);
-        SubTable = ACPI_ADD_PTR (ACPI_WHEA_HEADER, SubTable,
-            sizeof (ACPI_WHEA_HEADER));
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpFpdt
- *
- * PARAMETERS:  Table               - A FPDT table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a FPDT. This table type consists
- *              of an open-ended number of subtables.
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpFpdt (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    ACPI_FPDT_HEADER        *SubTable;
-    UINT32                  Length = Table->Length;
-    UINT32                  Offset = sizeof (ACPI_TABLE_FPDT);
-    ACPI_DMTABLE_INFO       *InfoTable;
-
-
-    /* There is no main table (other than the standard ACPI header) */
-
-    /* Subtables */
-
-    SubTable = ACPI_ADD_PTR (ACPI_FPDT_HEADER, Table, Offset);
-    while (Offset < Table->Length)
-    {
-        /* Common subtable header */
-
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Length, Offset, SubTable,
-            SubTable->Length, AcpiDmTableInfoFpdtHdr);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        switch (SubTable->Type)
-        {
-        case ACPI_FPDT_TYPE_BOOT:
-
-            InfoTable = AcpiDmTableInfoFpdt0;
-            break;
-
-        case ACPI_FPDT_TYPE_S3PERF:
-
-            InfoTable = AcpiDmTableInfoFpdt1;
-            break;
-
-        default:
-
-            AcpiOsPrintf ("\n**** Unknown FPDT subtable type 0x%X\n\n",
-                SubTable->Type);
-
-            /* Attempt to continue */
-
-            if (!SubTable->Length)
-            {
-                AcpiOsPrintf ("Invalid zero length subtable\n");
-                return;
-            }
-            goto NextSubTable;
-        }
-
-        Status = AcpiDmDumpTable (Length, Offset, SubTable,
-            SubTable->Length, InfoTable);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-NextSubTable:
-        /* Point to next subtable */
-
-        Offset += SubTable->Length;
-        SubTable = ACPI_ADD_PTR (ACPI_FPDT_HEADER, SubTable,
-            SubTable->Length);
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpGtdt
- *
- * PARAMETERS:  Table               - A GTDT table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a GTDT. This table type consists
- *              of an open-ended number of subtables.
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpGtdt (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    ACPI_GTDT_HEADER        *SubTable;
-    UINT32                  Length = Table->Length;
-    UINT32                  Offset = sizeof (ACPI_TABLE_GTDT);
-    ACPI_DMTABLE_INFO       *InfoTable;
-    UINT32                  SubTableLength;
-    UINT32                  GtCount;
-    ACPI_GTDT_TIMER_ENTRY   *GtxTable;
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Length, 0, Table, 0, AcpiDmTableInfoGtdt);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    /* Subtables */
-
-    SubTable = ACPI_ADD_PTR (ACPI_GTDT_HEADER, Table, Offset);
-    while (Offset < Table->Length)
-    {
-        /* Common subtable header */
-
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Length, Offset, SubTable,
-            SubTable->Length, AcpiDmTableInfoGtdtHdr);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        GtCount = 0;
-        switch (SubTable->Type)
-        {
-        case ACPI_GTDT_TYPE_TIMER_BLOCK:
-
-            SubTableLength = sizeof (ACPI_GTDT_TIMER_BLOCK);
-            GtCount = (ACPI_CAST_PTR (ACPI_GTDT_TIMER_BLOCK,
-                SubTable))->TimerCount;
-
-            InfoTable = AcpiDmTableInfoGtdt0;
-            break;
-
-        case ACPI_GTDT_TYPE_WATCHDOG:
-
-            SubTableLength = sizeof (ACPI_GTDT_WATCHDOG);
-
-            InfoTable = AcpiDmTableInfoGtdt1;
-            break;
-
-        default:
-
-            /* Cannot continue on unknown type - no length */
-
-            AcpiOsPrintf ("\n**** Unknown GTDT subtable type 0x%X\n",
-                SubTable->Type);
-            return;
-        }
-
-        Status = AcpiDmDumpTable (Length, Offset, SubTable,
-            SubTable->Length, InfoTable);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        /* Point to end of current subtable (each subtable above is of fixed length) */
-
-        Offset += SubTableLength;
-
-        /* If there are any Gt Timer Blocks from above, dump them now */
-
-        if (GtCount)
-        {
-            GtxTable = ACPI_ADD_PTR (
-                ACPI_GTDT_TIMER_ENTRY, SubTable, SubTableLength);
-            SubTableLength += GtCount * sizeof (ACPI_GTDT_TIMER_ENTRY);
-
-            while (GtCount)
-            {
-                AcpiOsPrintf ("\n");
-                Status = AcpiDmDumpTable (Length, Offset, GtxTable,
-                    sizeof (ACPI_GTDT_TIMER_ENTRY), AcpiDmTableInfoGtdt0a);
-                if (ACPI_FAILURE (Status))
-                {
-                    return;
-                }
-                Offset += sizeof (ACPI_GTDT_TIMER_ENTRY);
-                GtxTable++;
-                GtCount--;
-            }
-        }
-
-        /* Point to next subtable */
-
-        SubTable = ACPI_ADD_PTR (ACPI_GTDT_HEADER, SubTable, SubTableLength);
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpHest
- *
- * PARAMETERS:  Table               - A HEST table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a HEST. This table type consists
- *              of an open-ended number of subtables.
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpHest (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    ACPI_HEST_HEADER        *SubTable;
-    UINT32                  Length = Table->Length;
-    UINT32                  Offset = sizeof (ACPI_TABLE_HEST);
-    ACPI_DMTABLE_INFO       *InfoTable;
-    UINT32                  SubTableLength;
-    UINT32                  BankCount;
-    ACPI_HEST_IA_ERROR_BANK *BankTable;
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Length, 0, Table, 0, AcpiDmTableInfoHest);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    /* Subtables */
-
-    SubTable = ACPI_ADD_PTR (ACPI_HEST_HEADER, Table, Offset);
-    while (Offset < Table->Length)
-    {
-        BankCount = 0;
-        switch (SubTable->Type)
-        {
-        case ACPI_HEST_TYPE_IA32_CHECK:
-
-            InfoTable = AcpiDmTableInfoHest0;
-            SubTableLength = sizeof (ACPI_HEST_IA_MACHINE_CHECK);
-            BankCount = (ACPI_CAST_PTR (ACPI_HEST_IA_MACHINE_CHECK,
-                SubTable))->NumHardwareBanks;
-            break;
-
-        case ACPI_HEST_TYPE_IA32_CORRECTED_CHECK:
-
-            InfoTable = AcpiDmTableInfoHest1;
-            SubTableLength = sizeof (ACPI_HEST_IA_CORRECTED);
-            BankCount = (ACPI_CAST_PTR (ACPI_HEST_IA_CORRECTED,
-                SubTable))->NumHardwareBanks;
-            break;
-
-        case ACPI_HEST_TYPE_IA32_NMI:
-
-            InfoTable = AcpiDmTableInfoHest2;
-            SubTableLength = sizeof (ACPI_HEST_IA_NMI);
-            break;
-
-        case ACPI_HEST_TYPE_AER_ROOT_PORT:
-
-            InfoTable = AcpiDmTableInfoHest6;
-            SubTableLength = sizeof (ACPI_HEST_AER_ROOT);
-            break;
-
-        case ACPI_HEST_TYPE_AER_ENDPOINT:
-
-            InfoTable = AcpiDmTableInfoHest7;
-            SubTableLength = sizeof (ACPI_HEST_AER);
-            break;
-
-        case ACPI_HEST_TYPE_AER_BRIDGE:
-
-            InfoTable = AcpiDmTableInfoHest8;
-            SubTableLength = sizeof (ACPI_HEST_AER_BRIDGE);
-            break;
-
-        case ACPI_HEST_TYPE_GENERIC_ERROR:
-
-            InfoTable = AcpiDmTableInfoHest9;
-            SubTableLength = sizeof (ACPI_HEST_GENERIC);
-            break;
-
-        case ACPI_HEST_TYPE_GENERIC_ERROR_V2:
-
-            InfoTable = AcpiDmTableInfoHest10;
-            SubTableLength = sizeof (ACPI_HEST_GENERIC_V2);
-            break;
-
-        case ACPI_HEST_TYPE_IA32_DEFERRED_CHECK:
-
-            InfoTable = AcpiDmTableInfoHest11;
-            SubTableLength = sizeof (ACPI_HEST_IA_DEFERRED_CHECK);
-            BankCount = (ACPI_CAST_PTR (ACPI_HEST_IA_DEFERRED_CHECK,
-                SubTable))->NumHardwareBanks;
-            break;
-
-        default:
-
-            /* Cannot continue on unknown type - no length */
-
-            AcpiOsPrintf ("\n**** Unknown HEST subtable type 0x%X\n",
-                SubTable->Type);
-            return;
-        }
-
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Length, Offset, SubTable,
-            SubTableLength, InfoTable);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        /* Point to end of current subtable (each subtable above is of fixed length) */
-
-        Offset += SubTableLength;
-
-        /* If there are any (fixed-length) Error Banks from above, dump them now */
-
-        if (BankCount)
-        {
-            BankTable = ACPI_ADD_PTR (ACPI_HEST_IA_ERROR_BANK, SubTable,
-                SubTableLength);
-            SubTableLength += BankCount * sizeof (ACPI_HEST_IA_ERROR_BANK);
-
-            while (BankCount)
-            {
-                AcpiOsPrintf ("\n");
-                Status = AcpiDmDumpTable (Length, Offset, BankTable,
-                    sizeof (ACPI_HEST_IA_ERROR_BANK), AcpiDmTableInfoHestBank);
-                if (ACPI_FAILURE (Status))
-                {
-                    return;
-                }
-
-                Offset += sizeof (ACPI_HEST_IA_ERROR_BANK);
-                BankTable++;
-                BankCount--;
-            }
-        }
-
-        /* Point to next subtable */
-
-        SubTable = ACPI_ADD_PTR (ACPI_HEST_HEADER, SubTable, SubTableLength);
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpHmat
- *
- * PARAMETERS:  Table               - A HMAT table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a HMAT.
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpHmat (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    ACPI_HMAT_STRUCTURE     *HmatStruct;
-    ACPI_HMAT_LOCALITY      *HmatLocality;
-    ACPI_HMAT_CACHE         *HmatCache;
-    UINT32                  Offset;
-    UINT32                  SubTableOffset;
-    UINT32                  Length;
-    ACPI_DMTABLE_INFO       *InfoTable;
-    UINT32                  i, j;
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Table->Length, 0, Table, 0, AcpiDmTableInfoHmat);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-    Offset = sizeof (ACPI_TABLE_HMAT);
-
-    while (Offset < Table->Length)
-    {
-        AcpiOsPrintf ("\n");
-        SubTableOffset = 0;
-
-        /* Dump HMAT structure header */
-
-        HmatStruct = ACPI_ADD_PTR (ACPI_HMAT_STRUCTURE, Table, Offset);
-        if (HmatStruct->Length < sizeof (ACPI_HMAT_STRUCTURE))
-        {
-            AcpiOsPrintf ("Invalid HMAT structure length\n");
-            return;
-        }
-        Status = AcpiDmDumpTable (Table->Length, Offset, HmatStruct,
-            HmatStruct->Length, AcpiDmTableInfoHmatHdr);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        switch (HmatStruct->Type)
-        {
-        case ACPI_HMAT_TYPE_ADDRESS_RANGE:
-
-            InfoTable = AcpiDmTableInfoHmat0;
-            Length = sizeof (ACPI_HMAT_ADDRESS_RANGE);
-            break;
-
-        case ACPI_HMAT_TYPE_LOCALITY:
-
-            InfoTable = AcpiDmTableInfoHmat1;
-            Length = sizeof (ACPI_HMAT_LOCALITY);
-            break;
-
-        case ACPI_HMAT_TYPE_CACHE:
-
-            InfoTable = AcpiDmTableInfoHmat2;
-            Length = sizeof (ACPI_HMAT_CACHE);
-            break;
-
-        default:
-
-            AcpiOsPrintf ("\n**** Unknown HMAT structure type 0x%X\n",
-                HmatStruct->Type);
-
-            /* Attempt to continue */
-
-            goto NextSubTable;
-        }
-
-        /* Dump HMAT structure body */
-
-        if (HmatStruct->Length < Length)
-        {
-            AcpiOsPrintf ("Invalid HMAT structure length\n");
-            return;
-        }
-        Status = AcpiDmDumpTable (Table->Length, Offset, HmatStruct,
-            HmatStruct->Length, InfoTable);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        /* Dump HMAT structure additionals */
-
-        switch (HmatStruct->Type)
-        {
-        case ACPI_HMAT_TYPE_LOCALITY:
-
-            HmatLocality = ACPI_CAST_PTR (ACPI_HMAT_LOCALITY, HmatStruct);
-            SubTableOffset = sizeof (ACPI_HMAT_LOCALITY);
-
-            /* Dump initiator proximity domains */
-
-            if ((UINT32)(HmatStruct->Length - SubTableOffset) <
-                (UINT32)(HmatLocality->NumberOfInitiatorPDs * 4))
-            {
-                AcpiOsPrintf ("Invalid initiator proximity domain number\n");
-                return;
-            }
-            for (i = 0; i < HmatLocality->NumberOfInitiatorPDs; i++)
-            {
-                Status = AcpiDmDumpTable (Table->Length, Offset + SubTableOffset,
-                    ACPI_ADD_PTR (ACPI_HMAT_STRUCTURE, HmatStruct, SubTableOffset),
-                    4, AcpiDmTableInfoHmat1a);
-                SubTableOffset += 4;
-            }
-
-            /* Dump target proximity domains */
-
-            if ((UINT32)(HmatStruct->Length - SubTableOffset) <
-                (UINT32)(HmatLocality->NumberOfTargetPDs * 4))
-            {
-                AcpiOsPrintf ("Invalid target proximity domain number\n");
-                return;
-            }
-            for (i = 0; i < HmatLocality->NumberOfTargetPDs; i++)
-            {
-                Status = AcpiDmDumpTable (Table->Length, Offset + SubTableOffset,
-                    ACPI_ADD_PTR (ACPI_HMAT_STRUCTURE, HmatStruct, SubTableOffset),
-                    4, AcpiDmTableInfoHmat1b);
-                SubTableOffset += 4;
-            }
-
-            /* Dump latency/bandwidth entris */
-
-            if ((UINT32)(HmatStruct->Length - SubTableOffset) <
-                (UINT32)(HmatLocality->NumberOfInitiatorPDs *
-                         HmatLocality->NumberOfTargetPDs * 2))
-            {
-                AcpiOsPrintf ("Invalid latency/bandwidth entry number\n");
-                return;
-            }
-            for (i = 0; i < HmatLocality->NumberOfInitiatorPDs; i++)
-            {
-                for (j = 0; j < HmatLocality->NumberOfTargetPDs; j++)
-                {
-                    Status = AcpiDmDumpTable (Table->Length, Offset + SubTableOffset,
-                        ACPI_ADD_PTR (ACPI_HMAT_STRUCTURE, HmatStruct, SubTableOffset),
-                        2, AcpiDmTableInfoHmat1c);
-                    SubTableOffset += 2;
-                }
-            }
-            break;
-
-        case ACPI_HMAT_TYPE_CACHE:
-
-            HmatCache = ACPI_CAST_PTR (ACPI_HMAT_CACHE, HmatStruct);
-            SubTableOffset = sizeof (ACPI_HMAT_CACHE);
-
-            /* Dump SMBIOS handles */
-
-            if ((UINT32)(HmatStruct->Length - SubTableOffset) <
-                (UINT32)(HmatCache->NumberOfSMBIOSHandles * 2))
-            {
-                AcpiOsPrintf ("Invalid SMBIOS handle number\n");
-                return;
-            }
-            for (i = 0; i < HmatCache->NumberOfSMBIOSHandles; i++)
-            {
-                Status = AcpiDmDumpTable (Table->Length, Offset + SubTableOffset,
-                    ACPI_ADD_PTR (ACPI_HMAT_STRUCTURE, HmatStruct, SubTableOffset),
-                    2, AcpiDmTableInfoHmat2a);
-                SubTableOffset += 2;
-            }
-            break;
-
-        default:
-
-            break;
-        }
-
-NextSubTable:
-        /* Point to next HMAT structure subtable */
-
-        Offset += (HmatStruct->Length);
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpIort
- *
- * PARAMETERS:  Table               - A IORT table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a IORT
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpIort (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    ACPI_TABLE_IORT         *Iort;
-    ACPI_IORT_NODE          *IortNode;
-    ACPI_IORT_ITS_GROUP     *IortItsGroup = NULL;
-    ACPI_IORT_SMMU          *IortSmmu = NULL;
-    UINT32                  Offset;
-    UINT32                  NodeOffset;
-    UINT32                  Length;
-    ACPI_DMTABLE_INFO       *InfoTable;
-    char                    *String;
-    UINT32                  i;
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Table->Length, 0, Table, 0, AcpiDmTableInfoIort);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    Iort = ACPI_CAST_PTR (ACPI_TABLE_IORT, Table);
-    Offset = sizeof (ACPI_TABLE_IORT);
-
-    /* Dump the OptionalPadding (optional) */
-
-    if (Iort->NodeOffset > Offset)
-    {
-        Status = AcpiDmDumpTable (Table->Length, Offset, Table,
-            Iort->NodeOffset - Offset, AcpiDmTableInfoIortPad);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-    }
-
-    Offset = Iort->NodeOffset;
-    while (Offset < Table->Length)
-    {
-        /* Common subtable header */
-
-        IortNode = ACPI_ADD_PTR (ACPI_IORT_NODE, Table, Offset);
-        AcpiOsPrintf ("\n");
-        Length = ACPI_OFFSET (ACPI_IORT_NODE, NodeData);
-        Status = AcpiDmDumpTable (Table->Length, Offset,
-            IortNode, Length, AcpiDmTableInfoIortHdr);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        NodeOffset = Length;
-
-        switch (IortNode->Type)
-        {
-        case ACPI_IORT_NODE_ITS_GROUP:
-
-            InfoTable = AcpiDmTableInfoIort0;
-            Length = ACPI_OFFSET (ACPI_IORT_ITS_GROUP, Identifiers);
-            IortItsGroup = ACPI_ADD_PTR (ACPI_IORT_ITS_GROUP, IortNode, NodeOffset);
-            break;
-
-        case ACPI_IORT_NODE_NAMED_COMPONENT:
-
-            InfoTable = AcpiDmTableInfoIort1;
-            Length = ACPI_OFFSET (ACPI_IORT_NAMED_COMPONENT, DeviceName);
-            String = ACPI_ADD_PTR (char, IortNode, NodeOffset + Length);
-            Length += strlen (String) + 1;
-            break;
-
-        case ACPI_IORT_NODE_PCI_ROOT_COMPLEX:
-
-            InfoTable = AcpiDmTableInfoIort2;
-            Length = IortNode->Length - NodeOffset;
-            break;
-
-        case ACPI_IORT_NODE_SMMU:
-
-            InfoTable = AcpiDmTableInfoIort3;
-            Length = ACPI_OFFSET (ACPI_IORT_SMMU, Interrupts);
-            IortSmmu = ACPI_ADD_PTR (ACPI_IORT_SMMU, IortNode, NodeOffset);
-            break;
-
-        case ACPI_IORT_NODE_SMMU_V3:
-
-            InfoTable = AcpiDmTableInfoIort4;
-            Length = IortNode->Length - NodeOffset;
-            break;
-
-        default:
-
-            AcpiOsPrintf ("\n**** Unknown IORT node type 0x%X\n",
-                IortNode->Type);
-
-            /* Attempt to continue */
-
-            if (!IortNode->Length)
-            {
-                AcpiOsPrintf ("Invalid zero length IORT node\n");
-                return;
-            }
-            goto NextSubTable;
-        }
-
-        /* Dump the node subtable header */
-
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Table->Length, Offset + NodeOffset,
-            ACPI_ADD_PTR (ACPI_IORT_NODE, IortNode, NodeOffset),
-            Length, InfoTable);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        NodeOffset += Length;
-
-        /* Dump the node specific data */
-
-        switch (IortNode->Type)
-        {
-        case ACPI_IORT_NODE_ITS_GROUP:
-
-            /* Validate IortItsGroup to avoid compiler warnings */
-
-            if (IortItsGroup)
-            {
-                for (i = 0; i < IortItsGroup->ItsCount; i++)
-                {
-                    Status = AcpiDmDumpTable (Table->Length, Offset + NodeOffset,
-                        ACPI_ADD_PTR (ACPI_IORT_NODE, IortNode, NodeOffset),
-                        4, AcpiDmTableInfoIort0a);
-                    NodeOffset += 4;
-                }
-            }
-            break;
-
-        case ACPI_IORT_NODE_NAMED_COMPONENT:
-
-            /* Dump the Padding (optional) */
-
-            if (IortNode->Length > NodeOffset)
-            {
-                Status = AcpiDmDumpTable (Table->Length, Offset + NodeOffset,
-                    Table, IortNode->Length - NodeOffset,
-                    AcpiDmTableInfoIort1a);
-                if (ACPI_FAILURE (Status))
-                {
-                    return;
-                }
-            }
-            break;
-
-        case ACPI_IORT_NODE_SMMU:
-
-            AcpiOsPrintf ("\n");
-
-            /* Validate IortSmmu to avoid compiler warnings */
-
-            if (IortSmmu)
-            {
-                Length = 2 * sizeof (UINT64);
-                NodeOffset = IortSmmu->GlobalInterruptOffset;
-                Status = AcpiDmDumpTable (Table->Length, Offset + NodeOffset,
-                    ACPI_ADD_PTR (ACPI_IORT_NODE, IortNode, NodeOffset),
-                    Length, AcpiDmTableInfoIort3a);
-                if (ACPI_FAILURE (Status))
-                {
-                    return;
-                }
-
-                NodeOffset = IortSmmu->ContextInterruptOffset;
-                for (i = 0; i < IortSmmu->ContextInterruptCount; i++)
-                {
-                    Status = AcpiDmDumpTable (Table->Length, Offset + NodeOffset,
-                        ACPI_ADD_PTR (ACPI_IORT_NODE, IortNode, NodeOffset),
-                        8, AcpiDmTableInfoIort3b);
-                    if (ACPI_FAILURE (Status))
-                    {
-                        return;
-                    }
-
-                    NodeOffset += 8;
-                }
-
-                NodeOffset = IortSmmu->PmuInterruptOffset;
-                for (i = 0; i < IortSmmu->PmuInterruptCount; i++)
-                {
-                    Status = AcpiDmDumpTable (Table->Length, Offset + NodeOffset,
-                        ACPI_ADD_PTR (ACPI_IORT_NODE, IortNode, NodeOffset),
-                        8, AcpiDmTableInfoIort3c);
-                    if (ACPI_FAILURE (Status))
-                    {
-                        return;
-                    }
-
-                    NodeOffset += 8;
-                }
-            }
-            break;
-
-        default:
-
-            break;
-        }
-
-        /* Dump the ID mappings */
-
-        NodeOffset = IortNode->MappingOffset;
-        for (i = 0; i < IortNode->MappingCount; i++)
-        {
-            AcpiOsPrintf ("\n");
-            Length = sizeof (ACPI_IORT_ID_MAPPING);
-            Status = AcpiDmDumpTable (Table->Length, Offset + NodeOffset,
-                ACPI_ADD_PTR (ACPI_IORT_NODE, IortNode, NodeOffset),
-                Length, AcpiDmTableInfoIortMap);
-            if (ACPI_FAILURE (Status))
-            {
-                return;
-            }
-
-            NodeOffset += Length;
-        }
-
-NextSubTable:
-        /* Point to next node subtable */
-
-        Offset += IortNode->Length;
-        IortNode = ACPI_ADD_PTR (ACPI_IORT_NODE, IortNode, IortNode->Length);
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpIvrs
- *
- * PARAMETERS:  Table               - A IVRS table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a IVRS
- *
- ******************************************************************************/
-
-static UINT8 EntrySizes[] = {4,8,16,32};
-
-void
-AcpiDmDumpIvrs (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    UINT32                  Offset = sizeof (ACPI_TABLE_IVRS);
-    UINT32                  EntryOffset;
-    UINT32                  EntryLength;
-    UINT32                  EntryType;
-    ACPI_IVRS_DE_HEADER     *DeviceEntry;
-    ACPI_IVRS_HEADER        *SubTable;
-    ACPI_DMTABLE_INFO       *InfoTable;
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Table->Length, 0, Table, 0, AcpiDmTableInfoIvrs);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    /* Subtables */
-
-    SubTable = ACPI_ADD_PTR (ACPI_IVRS_HEADER, Table, Offset);
-    while (Offset < Table->Length)
-    {
-        /* Common subtable header */
-
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Table->Length, Offset, SubTable,
-            SubTable->Length, AcpiDmTableInfoIvrsHdr);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        switch (SubTable->Type)
-        {
-        case ACPI_IVRS_TYPE_HARDWARE:
-
-            InfoTable = AcpiDmTableInfoIvrs0;
-            break;
-
-        case ACPI_IVRS_TYPE_MEMORY1:
-        case ACPI_IVRS_TYPE_MEMORY2:
-        case ACPI_IVRS_TYPE_MEMORY3:
-
-            InfoTable = AcpiDmTableInfoIvrs1;
-            break;
-
-        default:
-
-            AcpiOsPrintf ("\n**** Unknown IVRS subtable type 0x%X\n",
-                SubTable->Type);
-
-            /* Attempt to continue */
-
-            if (!SubTable->Length)
-            {
-                AcpiOsPrintf ("Invalid zero length subtable\n");
-                return;
-            }
-            goto NextSubTable;
-        }
-
-        /* Dump the subtable */
-
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Table->Length, Offset, SubTable,
-            SubTable->Length, InfoTable);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        /* The hardware subtable can contain multiple device entries */
-
-        if (SubTable->Type == ACPI_IVRS_TYPE_HARDWARE)
-        {
-            EntryOffset = Offset + sizeof (ACPI_IVRS_HARDWARE);
-            DeviceEntry = ACPI_ADD_PTR (ACPI_IVRS_DE_HEADER, SubTable,
-                sizeof (ACPI_IVRS_HARDWARE));
-
-            while (EntryOffset < (Offset + SubTable->Length))
-            {
-                AcpiOsPrintf ("\n");
-                /*
-                 * Upper 2 bits of Type encode the length of the device entry
-                 *
-                 * 00 = 4 byte
-                 * 01 = 8 byte
-                 * 10 = 16 byte - currently no entries defined
-                 * 11 = 32 byte - currently no entries defined
-                 */
-                EntryType = DeviceEntry->Type;
-                EntryLength = EntrySizes [EntryType >> 6];
-
-                switch (EntryType)
-                {
-                /* 4-byte device entries */
-
-                case ACPI_IVRS_TYPE_PAD4:
-                case ACPI_IVRS_TYPE_ALL:
-                case ACPI_IVRS_TYPE_SELECT:
-                case ACPI_IVRS_TYPE_START:
-                case ACPI_IVRS_TYPE_END:
-
-                    InfoTable = AcpiDmTableInfoIvrs4;
-                    break;
-
-                /* 8-byte entries, type A */
-
-                case ACPI_IVRS_TYPE_ALIAS_SELECT:
-                case ACPI_IVRS_TYPE_ALIAS_START:
-
-                    InfoTable = AcpiDmTableInfoIvrs8a;
-                    break;
-
-                /* 8-byte entries, type B */
-
-                case ACPI_IVRS_TYPE_PAD8:
-                case ACPI_IVRS_TYPE_EXT_SELECT:
-                case ACPI_IVRS_TYPE_EXT_START:
-
-                    InfoTable = AcpiDmTableInfoIvrs8b;
-                    break;
-
-                /* 8-byte entries, type C */
-
-                case ACPI_IVRS_TYPE_SPECIAL:
-
-                    InfoTable = AcpiDmTableInfoIvrs8c;
-                    break;
-
-                default:
-                    InfoTable = AcpiDmTableInfoIvrs4;
-                    AcpiOsPrintf (
-                        "\n**** Unknown IVRS device entry type/length: "
-                        "0x%.2X/0x%X at offset 0x%.4X: (header below)\n",
-                        EntryType, EntryLength, EntryOffset);
-                    break;
-                }
-
-                /* Dump the Device Entry */
-
-                Status = AcpiDmDumpTable (Table->Length, EntryOffset,
-                    DeviceEntry, EntryLength, InfoTable);
-                if (ACPI_FAILURE (Status))
-                {
-                    return;
-                }
-
-                EntryOffset += EntryLength;
-                DeviceEntry = ACPI_ADD_PTR (ACPI_IVRS_DE_HEADER, DeviceEntry,
-                    EntryLength);
-            }
-        }
-
-NextSubTable:
-        /* Point to next subtable */
-
-        Offset += SubTable->Length;
-        SubTable = ACPI_ADD_PTR (ACPI_IVRS_HEADER, SubTable, SubTable->Length);
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpLpit
- *
- * PARAMETERS:  Table               - A LPIT table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a LPIT. This table type consists
- *              of an open-ended number of subtables. Note: There are no
- *              entries in the main table. An LPIT consists of the table
- *              header and then subtables only.
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpLpit (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    ACPI_LPIT_HEADER        *SubTable;
-    UINT32                  Length = Table->Length;
-    UINT32                  Offset = sizeof (ACPI_TABLE_LPIT);
-    ACPI_DMTABLE_INFO       *InfoTable;
-    UINT32                  SubTableLength;
-
-
-    /* Subtables */
-
-    SubTable = ACPI_ADD_PTR (ACPI_LPIT_HEADER, Table, Offset);
-    while (Offset < Table->Length)
-    {
-        /* Common subtable header */
-
-        Status = AcpiDmDumpTable (Length, Offset, SubTable,
-            sizeof (ACPI_LPIT_HEADER), AcpiDmTableInfoLpitHdr);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        switch (SubTable->Type)
-        {
-        case ACPI_LPIT_TYPE_NATIVE_CSTATE:
-
-            InfoTable = AcpiDmTableInfoLpit0;
-            SubTableLength = sizeof (ACPI_LPIT_NATIVE);
-            break;
-
-        default:
-
-            /* Cannot continue on unknown type - no length */
-
-            AcpiOsPrintf ("\n**** Unknown LPIT subtable type 0x%X\n",
-                SubTable->Type);
-            return;
-        }
-
-        Status = AcpiDmDumpTable (Length, Offset, SubTable,
-            SubTableLength, InfoTable);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        AcpiOsPrintf ("\n");
-
-        /* Point to next subtable */
-
-        Offset += SubTableLength;
-        SubTable = ACPI_ADD_PTR (ACPI_LPIT_HEADER, SubTable, SubTableLength);
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpMadt
- *
- * PARAMETERS:  Table               - A MADT table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a MADT. This table type consists
- *              of an open-ended number of subtables.
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpMadt (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    ACPI_SUBTABLE_HEADER    *SubTable;
-    UINT32                  Length = Table->Length;
-    UINT32                  Offset = sizeof (ACPI_TABLE_MADT);
-    ACPI_DMTABLE_INFO       *InfoTable;
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Length, 0, Table, 0, AcpiDmTableInfoMadt);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    /* Subtables */
-
-    SubTable = ACPI_ADD_PTR (ACPI_SUBTABLE_HEADER, Table, Offset);
-    while (Offset < Table->Length)
-    {
-        /* Common subtable header */
-
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Length, Offset, SubTable,
-            SubTable->Length, AcpiDmTableInfoMadtHdr);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        switch (SubTable->Type)
-        {
-        case ACPI_MADT_TYPE_LOCAL_APIC:
-
-            InfoTable = AcpiDmTableInfoMadt0;
-            break;
-
-        case ACPI_MADT_TYPE_IO_APIC:
-
-            InfoTable = AcpiDmTableInfoMadt1;
-            break;
-
-        case ACPI_MADT_TYPE_INTERRUPT_OVERRIDE:
-
-            InfoTable = AcpiDmTableInfoMadt2;
-            break;
-
-        case ACPI_MADT_TYPE_NMI_SOURCE:
-
-            InfoTable = AcpiDmTableInfoMadt3;
-            break;
-
-        case ACPI_MADT_TYPE_LOCAL_APIC_NMI:
-
-            InfoTable = AcpiDmTableInfoMadt4;
-            break;
-
-        case ACPI_MADT_TYPE_LOCAL_APIC_OVERRIDE:
-
-            InfoTable = AcpiDmTableInfoMadt5;
-            break;
-
-        case ACPI_MADT_TYPE_IO_SAPIC:
-
-            InfoTable = AcpiDmTableInfoMadt6;
-            break;
-
-        case ACPI_MADT_TYPE_LOCAL_SAPIC:
-
-            InfoTable = AcpiDmTableInfoMadt7;
-            break;
-
-        case ACPI_MADT_TYPE_INTERRUPT_SOURCE:
-
-            InfoTable = AcpiDmTableInfoMadt8;
-            break;
-
-        case ACPI_MADT_TYPE_LOCAL_X2APIC:
-
-            InfoTable = AcpiDmTableInfoMadt9;
-            break;
-
-        case ACPI_MADT_TYPE_LOCAL_X2APIC_NMI:
-
-            InfoTable = AcpiDmTableInfoMadt10;
-            break;
-
-        case ACPI_MADT_TYPE_GENERIC_INTERRUPT:
-
-            InfoTable = AcpiDmTableInfoMadt11;
-            break;
-
-        case ACPI_MADT_TYPE_GENERIC_DISTRIBUTOR:
-
-            InfoTable = AcpiDmTableInfoMadt12;
-            break;
-
-        case ACPI_MADT_TYPE_GENERIC_MSI_FRAME:
-
-            InfoTable = AcpiDmTableInfoMadt13;
-            break;
-
-        case ACPI_MADT_TYPE_GENERIC_REDISTRIBUTOR:
-
-            InfoTable = AcpiDmTableInfoMadt14;
-            break;
-
-        case ACPI_MADT_TYPE_GENERIC_TRANSLATOR:
-
-            InfoTable = AcpiDmTableInfoMadt15;
-            break;
-
-        default:
-
-            AcpiOsPrintf ("\n**** Unknown MADT subtable type 0x%X\n\n",
-                SubTable->Type);
-
-            /* Attempt to continue */
-
-            if (!SubTable->Length)
-            {
-                AcpiOsPrintf ("Invalid zero length subtable\n");
-                return;
-            }
-
-            goto NextSubTable;
-        }
-
-        Status = AcpiDmDumpTable (Length, Offset, SubTable,
-            SubTable->Length, InfoTable);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-NextSubTable:
-        /* Point to next subtable */
-
-        Offset += SubTable->Length;
-        SubTable = ACPI_ADD_PTR (ACPI_SUBTABLE_HEADER, SubTable,
-            SubTable->Length);
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpMcfg
- *
- * PARAMETERS:  Table               - A MCFG Table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a MCFG table
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpMcfg (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    UINT32                  Offset = sizeof (ACPI_TABLE_MCFG);
-    ACPI_MCFG_ALLOCATION    *SubTable;
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Table->Length, 0, Table, 0, AcpiDmTableInfoMcfg);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    /* Subtables */
-
-    SubTable = ACPI_ADD_PTR (ACPI_MCFG_ALLOCATION, Table, Offset);
-    while (Offset < Table->Length)
-    {
-        if (Offset + sizeof (ACPI_MCFG_ALLOCATION) > Table->Length)
-        {
-            AcpiOsPrintf ("Warning: there are %u invalid trailing bytes\n",
-                sizeof (ACPI_MCFG_ALLOCATION) - (Offset - Table->Length));
-            return;
-        }
-
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Table->Length, Offset, SubTable,
-            sizeof (ACPI_MCFG_ALLOCATION), AcpiDmTableInfoMcfg0);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        /* Point to next subtable (each subtable is of fixed length) */
-
-        Offset += sizeof (ACPI_MCFG_ALLOCATION);
-        SubTable = ACPI_ADD_PTR (ACPI_MCFG_ALLOCATION, SubTable,
-            sizeof (ACPI_MCFG_ALLOCATION));
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpMpst
- *
- * PARAMETERS:  Table               - A MPST Table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a MPST table
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpMpst (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    UINT32                  Offset = sizeof (ACPI_TABLE_MPST);
-    ACPI_MPST_POWER_NODE    *SubTable0;
-    ACPI_MPST_POWER_STATE   *SubTable0A;
-    ACPI_MPST_COMPONENT     *SubTable0B;
-    ACPI_MPST_DATA_HDR      *SubTable1;
-    ACPI_MPST_POWER_DATA    *SubTable2;
-    UINT16                  SubtableCount;
-    UINT32                  PowerStateCount;
-    UINT32                  ComponentCount;
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Table->Length, 0, Table, 0, AcpiDmTableInfoMpst);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    /* Subtable: Memory Power Node(s) */
-
-    SubtableCount = (ACPI_CAST_PTR (ACPI_TABLE_MPST, Table))->PowerNodeCount;
-    SubTable0 = ACPI_ADD_PTR (ACPI_MPST_POWER_NODE, Table, Offset);
-
-    while ((Offset < Table->Length) && SubtableCount)
-    {
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Table->Length, Offset, SubTable0,
-            sizeof (ACPI_MPST_POWER_NODE), AcpiDmTableInfoMpst0);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        /* Extract the sub-subtable counts */
-
-        PowerStateCount = SubTable0->NumPowerStates;
-        ComponentCount = SubTable0->NumPhysicalComponents;
-        Offset += sizeof (ACPI_MPST_POWER_NODE);
-
-        /* Sub-subtables - Memory Power State Structure(s) */
-
-        SubTable0A = ACPI_ADD_PTR (ACPI_MPST_POWER_STATE, SubTable0,
-            sizeof (ACPI_MPST_POWER_NODE));
-
-        while (PowerStateCount)
-        {
-            AcpiOsPrintf ("\n");
-            Status = AcpiDmDumpTable (Table->Length, Offset, SubTable0A,
-                sizeof (ACPI_MPST_POWER_STATE), AcpiDmTableInfoMpst0A);
-            if (ACPI_FAILURE (Status))
-            {
-                return;
-            }
-
-            SubTable0A++;
-            PowerStateCount--;
-            Offset += sizeof (ACPI_MPST_POWER_STATE);
-       }
-
-        /* Sub-subtables - Physical Component ID Structure(s) */
-
-        SubTable0B = ACPI_CAST_PTR (ACPI_MPST_COMPONENT, SubTable0A);
-
-        if (ComponentCount)
-        {
-            AcpiOsPrintf ("\n");
-        }
-
-        while (ComponentCount)
-        {
-            Status = AcpiDmDumpTable (Table->Length, Offset, SubTable0B,
-                sizeof (ACPI_MPST_COMPONENT), AcpiDmTableInfoMpst0B);
-            if (ACPI_FAILURE (Status))
-            {
-                return;
-            }
-
-            SubTable0B++;
-            ComponentCount--;
-            Offset += sizeof (ACPI_MPST_COMPONENT);
-        }
-
-        /* Point to next Memory Power Node subtable */
-
-        SubtableCount--;
-        SubTable0 = ACPI_ADD_PTR (ACPI_MPST_POWER_NODE, SubTable0,
-            sizeof (ACPI_MPST_POWER_NODE) +
-            (sizeof (ACPI_MPST_POWER_STATE) * SubTable0->NumPowerStates) +
-            (sizeof (ACPI_MPST_COMPONENT) * SubTable0->NumPhysicalComponents));
-    }
-
-    /* Subtable: Count of Memory Power State Characteristic structures */
-
-    AcpiOsPrintf ("\n");
-    SubTable1 = ACPI_CAST_PTR (ACPI_MPST_DATA_HDR, SubTable0);
-    Status = AcpiDmDumpTable (Table->Length, Offset, SubTable1,
-        sizeof (ACPI_MPST_DATA_HDR), AcpiDmTableInfoMpst1);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    SubtableCount = SubTable1->CharacteristicsCount;
-    Offset += sizeof (ACPI_MPST_DATA_HDR);
-
-    /* Subtable: Memory Power State Characteristics structure(s) */
-
-    SubTable2 = ACPI_ADD_PTR (ACPI_MPST_POWER_DATA, SubTable1,
-        sizeof (ACPI_MPST_DATA_HDR));
-
-    while ((Offset < Table->Length) && SubtableCount)
-    {
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Table->Length, Offset, SubTable2,
-            sizeof (ACPI_MPST_POWER_DATA), AcpiDmTableInfoMpst2);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        SubTable2++;
-        SubtableCount--;
-        Offset += sizeof (ACPI_MPST_POWER_DATA);
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpMsct
- *
- * PARAMETERS:  Table               - A MSCT table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a MSCT
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpMsct (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    UINT32                  Offset = sizeof (ACPI_TABLE_MSCT);
-    ACPI_MSCT_PROXIMITY     *SubTable;
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Table->Length, 0, Table, 0, AcpiDmTableInfoMsct);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    /* Subtables */
-
-    SubTable = ACPI_ADD_PTR (ACPI_MSCT_PROXIMITY, Table, Offset);
-    while (Offset < Table->Length)
-    {
-        /* Common subtable header */
-
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Table->Length, Offset, SubTable,
-            sizeof (ACPI_MSCT_PROXIMITY), AcpiDmTableInfoMsct0);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        /* Point to next subtable */
-
-        Offset += sizeof (ACPI_MSCT_PROXIMITY);
-        SubTable = ACPI_ADD_PTR (ACPI_MSCT_PROXIMITY, SubTable,
-            sizeof (ACPI_MSCT_PROXIMITY));
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpMtmr
- *
- * PARAMETERS:  Table               - A MTMR table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a MTMR
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpMtmr (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    UINT32                  Offset = sizeof (ACPI_TABLE_MTMR);
-    ACPI_MTMR_ENTRY         *SubTable;
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Table->Length, 0, Table, 0, AcpiDmTableInfoMtmr);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    /* Subtables */
-
-    SubTable = ACPI_ADD_PTR (ACPI_MTMR_ENTRY, Table, Offset);
-    while (Offset < Table->Length)
-    {
-        /* Common subtable header */
-
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Table->Length, Offset, SubTable,
-            sizeof (ACPI_MTMR_ENTRY), AcpiDmTableInfoMtmr0);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        /* Point to next subtable */
-
-        Offset += sizeof (ACPI_MTMR_ENTRY);
-        SubTable = ACPI_ADD_PTR (ACPI_MTMR_ENTRY, SubTable,
-            sizeof (ACPI_MTMR_ENTRY));
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpNfit
- *
- * PARAMETERS:  Table               - A NFIT table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of an NFIT.
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpNfit (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    UINT32                  Offset = sizeof (ACPI_TABLE_NFIT);
-    UINT32                  FieldOffset = 0;
-    UINT32                  Length;
-    ACPI_NFIT_HEADER        *SubTable;
-    ACPI_DMTABLE_INFO       *InfoTable;
-    ACPI_NFIT_INTERLEAVE    *Interleave = NULL;
-    ACPI_NFIT_SMBIOS        *SmbiosInfo = NULL;
-    ACPI_NFIT_FLUSH_ADDRESS *Hint = NULL;
-    UINT32                  i;
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Table->Length, 0, Table, 0, AcpiDmTableInfoNfit);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    /* Subtables */
-
-    SubTable = ACPI_ADD_PTR (ACPI_NFIT_HEADER, Table, Offset);
-    while (Offset < Table->Length)
-    {
-        /* NFIT subtable header */
-
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Table->Length, Offset, SubTable,
-            SubTable->Length, AcpiDmTableInfoNfitHdr);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        switch (SubTable->Type)
-        {
-        case ACPI_NFIT_TYPE_SYSTEM_ADDRESS:
-
-            InfoTable = AcpiDmTableInfoNfit0;
-            break;
-
-        case ACPI_NFIT_TYPE_MEMORY_MAP:
-
-            InfoTable = AcpiDmTableInfoNfit1;
-            break;
-
-        case ACPI_NFIT_TYPE_INTERLEAVE:
-
-            /* Has a variable number of 32-bit values at the end */
-
-            InfoTable = AcpiDmTableInfoNfit2;
-            Interleave = ACPI_CAST_PTR (ACPI_NFIT_INTERLEAVE, SubTable);
-            FieldOffset = sizeof (ACPI_NFIT_INTERLEAVE);
-            break;
-
-        case ACPI_NFIT_TYPE_SMBIOS:
-
-            SmbiosInfo = ACPI_CAST_PTR (ACPI_NFIT_SMBIOS, SubTable);
-            InfoTable = AcpiDmTableInfoNfit3;
-            break;
-
-        case ACPI_NFIT_TYPE_CONTROL_REGION:
-
-            InfoTable = AcpiDmTableInfoNfit4;
-            break;
-
-        case ACPI_NFIT_TYPE_DATA_REGION:
-
-            InfoTable = AcpiDmTableInfoNfit5;
-            break;
-
-        case ACPI_NFIT_TYPE_FLUSH_ADDRESS:
-
-            /* Has a variable number of 64-bit addresses at the end */
-
-            InfoTable = AcpiDmTableInfoNfit6;
-            Hint = ACPI_CAST_PTR (ACPI_NFIT_FLUSH_ADDRESS, SubTable);
-            FieldOffset = sizeof (ACPI_NFIT_FLUSH_ADDRESS) - sizeof (UINT64);
-            break;
-
-        default:
-            AcpiOsPrintf ("\n**** Unknown NFIT subtable type 0x%X\n",
-                SubTable->Type);
-
-            /* Attempt to continue */
-
-            if (!SubTable->Length)
-            {
-                AcpiOsPrintf ("Invalid zero length subtable\n");
-                return;
-            }
-            goto NextSubTable;
-        }
-
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Table->Length, Offset, SubTable,
-            SubTable->Length, InfoTable);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        /* Per-subtable variable-length fields */
-
-        switch (SubTable->Type)
-        {
-        case ACPI_NFIT_TYPE_INTERLEAVE:
-
-            for (i = 0; i < Interleave->LineCount; i++)
-            {
-                Status = AcpiDmDumpTable (Table->Length, Offset + FieldOffset,
-                    &Interleave->LineOffset[i],
-                    sizeof (UINT32), AcpiDmTableInfoNfit2a);
-                if (ACPI_FAILURE (Status))
-                {
-                    return;
-                }
-
-                FieldOffset += sizeof (UINT32);
-            }
-            break;
-
-        case ACPI_NFIT_TYPE_SMBIOS:
-
-            Length = SubTable->Length -
-                sizeof (ACPI_NFIT_SMBIOS) + sizeof (UINT8);
-
-            if (Length)
-            {
-                Status = AcpiDmDumpTable (Table->Length,
-                    sizeof (ACPI_NFIT_SMBIOS) - sizeof (UINT8),
-                    SmbiosInfo,
-                    Length, AcpiDmTableInfoNfit3a);
-                if (ACPI_FAILURE (Status))
-                {
-                    return;
-                }
-            }
-
-            break;
-
-        case ACPI_NFIT_TYPE_FLUSH_ADDRESS:
-
-            for (i = 0; i < Hint->HintCount; i++)
-            {
-                Status = AcpiDmDumpTable (Table->Length, Offset + FieldOffset,
-                    &Hint->HintAddress[i],
-                    sizeof (UINT64), AcpiDmTableInfoNfit6a);
-                if (ACPI_FAILURE (Status))
-                {
-                    return;
-                }
-
-                FieldOffset += sizeof (UINT64);
-            }
-            break;
-
-        default:
-            break;
-        }
-
-NextSubTable:
-        /* Point to next subtable */
-
-        Offset += SubTable->Length;
-        SubTable = ACPI_ADD_PTR (ACPI_NFIT_HEADER, SubTable, SubTable->Length);
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpPcct
- *
- * PARAMETERS:  Table               - A PCCT table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a PCCT. This table type consists
- *              of an open-ended number of subtables.
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpPcct (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    ACPI_PCCT_SUBSPACE      *SubTable;
-    ACPI_DMTABLE_INFO       *InfoTable;
-    UINT32                  Length = Table->Length;
-    UINT32                  Offset = sizeof (ACPI_TABLE_PCCT);
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Length, 0, Table, 0, AcpiDmTableInfoPcct);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    /* Subtables */
-
-    SubTable = ACPI_ADD_PTR (ACPI_PCCT_SUBSPACE, Table, Offset);
-    while (Offset < Table->Length)
-    {
-        /* Common subtable header */
-
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Length, Offset, SubTable,
-            SubTable->Header.Length, AcpiDmTableInfoPcctHdr);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        switch (SubTable->Header.Type)
-        {
-        case ACPI_PCCT_TYPE_GENERIC_SUBSPACE:
-
-            InfoTable = AcpiDmTableInfoPcct0;
-            break;
-
-        case ACPI_PCCT_TYPE_HW_REDUCED_SUBSPACE:
-
-            InfoTable = AcpiDmTableInfoPcct1;
-            break;
-
-        case ACPI_PCCT_TYPE_HW_REDUCED_SUBSPACE_TYPE2:
-
-            InfoTable = AcpiDmTableInfoPcct2;
-            break;
-
-        case ACPI_PCCT_TYPE_EXT_PCC_MASTER_SUBSPACE:
-
-            InfoTable = AcpiDmTableInfoPcct3;
-            break;
-
-        case ACPI_PCCT_TYPE_EXT_PCC_SLAVE_SUBSPACE:
-
-            InfoTable = AcpiDmTableInfoPcct4;
-            break;
-
-        default:
-
-            AcpiOsPrintf (
-                "\n**** Unexpected or unknown PCCT subtable type 0x%X\n\n",
-                SubTable->Header.Type);
-            return;
-        }
-
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Length, Offset, SubTable,
-            SubTable->Header.Length, InfoTable);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        /* Point to next subtable */
-
-        Offset += SubTable->Header.Length;
-        SubTable = ACPI_ADD_PTR (ACPI_PCCT_SUBSPACE, SubTable,
-            SubTable->Header.Length);
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpPmtt
- *
- * PARAMETERS:  Table               - A PMTT table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a PMTT. This table type consists
- *              of an open-ended number of subtables.
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpPmtt (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    ACPI_PMTT_HEADER        *SubTable;
-    ACPI_PMTT_HEADER        *MemSubTable;
-    ACPI_PMTT_HEADER        *DimmSubTable;
-    ACPI_PMTT_DOMAIN        *DomainArray;
-    UINT32                  Length = Table->Length;
-    UINT32                  Offset = sizeof (ACPI_TABLE_PMTT);
-    UINT32                  MemOffset;
-    UINT32                  DimmOffset;
-    UINT32                  DomainOffset;
-    UINT32                  DomainCount;
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Length, 0, Table, 0, AcpiDmTableInfoPmtt);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    /* Subtables */
-
-    SubTable = ACPI_ADD_PTR (ACPI_PMTT_HEADER, Table, Offset);
-    while (Offset < Table->Length)
-    {
-        /* Common subtable header */
-
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Length, Offset, SubTable,
-            SubTable->Length, AcpiDmTableInfoPmttHdr);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        /* Only Socket subtables are expected at this level */
-
-        if (SubTable->Type != ACPI_PMTT_TYPE_SOCKET)
-        {
-            AcpiOsPrintf (
-                "\n**** Unexpected or unknown PMTT subtable type 0x%X\n\n",
-                SubTable->Type);
-            return;
-        }
-
-        /* Dump the fixed-length portion of the subtable */
-
-        Status = AcpiDmDumpTable (Length, Offset, SubTable,
-            SubTable->Length, AcpiDmTableInfoPmtt0);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        /* Walk the memory controller subtables */
-
-        MemOffset = sizeof (ACPI_PMTT_SOCKET);
-        MemSubTable = ACPI_ADD_PTR (ACPI_PMTT_HEADER, SubTable,
-            sizeof (ACPI_PMTT_SOCKET));
-
-        while (((Offset + MemOffset) < Table->Length) &&
-            (MemOffset < SubTable->Length))
-        {
-            /* Common subtable header */
-
-            AcpiOsPrintf ("\n");
-            Status = AcpiDmDumpTable (Length,
-                Offset + MemOffset, MemSubTable,
-                MemSubTable->Length, AcpiDmTableInfoPmttHdr);
-            if (ACPI_FAILURE (Status))
-            {
-                return;
-            }
-
-            /* Only memory controller subtables are expected at this level */
-
-            if (MemSubTable->Type != ACPI_PMTT_TYPE_CONTROLLER)
-            {
-                AcpiOsPrintf (
-                    "\n**** Unexpected or unknown PMTT subtable type 0x%X\n\n",
-                    MemSubTable->Type);
-                return;
-            }
-
-            /* Dump the fixed-length portion of the controller subtable */
-
-            Status = AcpiDmDumpTable (Length,
-                Offset + MemOffset, MemSubTable,
-                MemSubTable->Length, AcpiDmTableInfoPmtt1);
-            if (ACPI_FAILURE (Status))
-            {
-                return;
-            }
-
-            /* Walk the variable count of proximity domains */
-
-            DomainCount = ((ACPI_PMTT_CONTROLLER *) MemSubTable)->DomainCount;
-            DomainOffset = sizeof (ACPI_PMTT_CONTROLLER);
-            DomainArray = ACPI_ADD_PTR (ACPI_PMTT_DOMAIN, MemSubTable,
-                sizeof (ACPI_PMTT_CONTROLLER));
-
-            while (((Offset + MemOffset + DomainOffset) < Table->Length) &&
-                ((MemOffset + DomainOffset) < SubTable->Length) &&
-                DomainCount)
-            {
-                Status = AcpiDmDumpTable (Length,
-                    Offset + MemOffset + DomainOffset, DomainArray,
-                    sizeof (ACPI_PMTT_DOMAIN), AcpiDmTableInfoPmtt1a);
-                if (ACPI_FAILURE (Status))
-                {
-                    return;
-                }
-
-                DomainOffset += sizeof (ACPI_PMTT_DOMAIN);
-                DomainArray++;
-                DomainCount--;
-            }
-
-            if (DomainCount)
-            {
-                AcpiOsPrintf (
-                    "\n**** DomainCount exceeds subtable length\n\n");
-            }
-
-            /* Walk the physical component (DIMM) subtables */
-
-            DimmOffset = DomainOffset;
-            DimmSubTable = ACPI_ADD_PTR (ACPI_PMTT_HEADER, MemSubTable,
-                DomainOffset);
-
-            while (((Offset + MemOffset + DimmOffset) < Table->Length) &&
-                (DimmOffset < MemSubTable->Length))
-            {
-                /* Common subtable header */
-
-                AcpiOsPrintf ("\n");
-                Status = AcpiDmDumpTable (Length,
-                    Offset + MemOffset + DimmOffset, DimmSubTable,
-                    DimmSubTable->Length, AcpiDmTableInfoPmttHdr);
-                if (ACPI_FAILURE (Status))
-                {
-                    return;
-                }
-
-                /* Only DIMM subtables are expected at this level */
-
-                if (DimmSubTable->Type != ACPI_PMTT_TYPE_DIMM)
-                {
-                    AcpiOsPrintf (
-                        "\n**** Unexpected or unknown PMTT subtable type 0x%X\n\n",
-                        DimmSubTable->Type);
-                    return;
-                }
-
-                /* Dump the fixed-length DIMM subtable */
-
-                Status = AcpiDmDumpTable (Length,
-                    Offset + MemOffset + DimmOffset, DimmSubTable,
-                    DimmSubTable->Length, AcpiDmTableInfoPmtt2);
-                if (ACPI_FAILURE (Status))
-                {
-                    return;
-                }
-
-                /* Point to next DIMM subtable */
-
-                DimmOffset += DimmSubTable->Length;
-                DimmSubTable = ACPI_ADD_PTR (ACPI_PMTT_HEADER,
-                    DimmSubTable, DimmSubTable->Length);
-            }
-
-            /* Point to next Controller subtable */
-
-            MemOffset += MemSubTable->Length;
-            MemSubTable = ACPI_ADD_PTR (ACPI_PMTT_HEADER,
-                MemSubTable, MemSubTable->Length);
-        }
-
-        /* Point to next Socket subtable */
-
-        Offset += SubTable->Length;
-        SubTable = ACPI_ADD_PTR (ACPI_PMTT_HEADER,
-            SubTable, SubTable->Length);
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpPptt
- *
- * PARAMETERS:  Table               - A PMTT table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a PPTT. This table type consists
- *              of an open-ended number of subtables.
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpPptt (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    ACPI_SUBTABLE_HEADER    *SubTable;
-    ACPI_PPTT_PROCESSOR     *PpttProcessor;
-    UINT8                   Length;
-    UINT8                   SubTableOffset;
-    UINT32                  Offset = sizeof (ACPI_TABLE_FPDT);
-    ACPI_DMTABLE_INFO       *InfoTable;
-    UINT32                  i;
-
-
-    /* There is no main table (other than the standard ACPI header) */
-
-    /* Subtables */
-
-    Offset = sizeof (ACPI_TABLE_HEADER);
-    while (Offset < Table->Length)
-    {
-        AcpiOsPrintf ("\n");
-
-        /* Common subtable header */
-
-        SubTable = ACPI_ADD_PTR (ACPI_SUBTABLE_HEADER, Table, Offset);
-        if (SubTable->Length < sizeof (ACPI_SUBTABLE_HEADER))
-        {
-            AcpiOsPrintf ("Invalid subtable length\n");
-            return;
-        }
-        Status = AcpiDmDumpTable (Table->Length, Offset, SubTable,
-            SubTable->Length, AcpiDmTableInfoPpttHdr);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        switch (SubTable->Type)
-        {
-        case ACPI_PPTT_TYPE_PROCESSOR:
-
-            InfoTable = AcpiDmTableInfoPptt0;
-            Length = sizeof (ACPI_PPTT_PROCESSOR);
-            break;
-
-        case ACPI_PPTT_TYPE_CACHE:
-
-            InfoTable = AcpiDmTableInfoPptt1;
-            Length = sizeof (ACPI_PPTT_CACHE);
-            break;
-
-        case ACPI_PPTT_TYPE_ID:
-
-            InfoTable = AcpiDmTableInfoPptt2;
-            Length = sizeof (ACPI_PPTT_ID);
-            break;
-
-        default:
-
-            AcpiOsPrintf ("\n**** Unknown PPTT subtable type 0x%X\n\n",
-                SubTable->Type);
-
-            /* Attempt to continue */
-
-            goto NextSubTable;
-        }
-
-        if (SubTable->Length < Length)
-        {
-            AcpiOsPrintf ("Invalid subtable length\n");
-            return;
-        }
-        Status = AcpiDmDumpTable (Table->Length, Offset, SubTable,
-            SubTable->Length, InfoTable);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-        SubTableOffset = Length;
-
-        switch (SubTable->Type)
-        {
-        case ACPI_PPTT_TYPE_PROCESSOR:
-
-            PpttProcessor = ACPI_CAST_PTR (ACPI_PPTT_PROCESSOR, SubTable);
-
-            /* Dump SMBIOS handles */
-
-            if ((UINT8)(SubTable->Length - SubTableOffset) <
-                (UINT8)(PpttProcessor->NumberOfPrivResources * 4))
-            {
-                AcpiOsPrintf ("Invalid private resource number\n");
-                return;
-            }
-            for (i = 0; i < PpttProcessor->NumberOfPrivResources; i++)
-            {
-                Status = AcpiDmDumpTable (Table->Length, Offset + SubTableOffset,
-                    ACPI_ADD_PTR (ACPI_SUBTABLE_HEADER, SubTable, SubTableOffset),
-                    4, AcpiDmTableInfoPptt0a);
-                SubTableOffset += 4;
-            }
-            break;
-
-        default:
-
-            break;
-        }
-
-NextSubTable:
-        /* Point to next subtable */
-
-        Offset += SubTable->Length;
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpS3pt
- *
- * PARAMETERS:  Table               - A S3PT table
- *
- * RETURN:      Length of the table
- *
- * DESCRIPTION: Format the contents of a S3PT
- *
- ******************************************************************************/
-
-UINT32
-AcpiDmDumpS3pt (
-    ACPI_TABLE_HEADER       *Tables)
-{
-    ACPI_STATUS             Status;
-    UINT32                  Offset = sizeof (ACPI_TABLE_S3PT);
-    ACPI_FPDT_HEADER        *SubTable;
-    ACPI_DMTABLE_INFO       *InfoTable;
-    ACPI_TABLE_S3PT         *S3ptTable = ACPI_CAST_PTR (ACPI_TABLE_S3PT, Tables);
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Offset, 0, S3ptTable, 0, AcpiDmTableInfoS3pt);
-    if (ACPI_FAILURE (Status))
-    {
-        return 0;
-    }
-
-    SubTable = ACPI_ADD_PTR (ACPI_FPDT_HEADER, S3ptTable, Offset);
-    while (Offset < S3ptTable->Length)
-    {
-        /* Common subtable header */
-
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (S3ptTable->Length, Offset, SubTable,
-            SubTable->Length, AcpiDmTableInfoS3ptHdr);
-        if (ACPI_FAILURE (Status))
-        {
-            return 0;
-        }
-
-        switch (SubTable->Type)
-        {
-        case ACPI_S3PT_TYPE_RESUME:
-
-            InfoTable = AcpiDmTableInfoS3pt0;
-            break;
-
-        case ACPI_S3PT_TYPE_SUSPEND:
-
-            InfoTable = AcpiDmTableInfoS3pt1;
-            break;
-
-        default:
-
-            AcpiOsPrintf ("\n**** Unknown S3PT subtable type 0x%X\n",
-                SubTable->Type);
-
-            /* Attempt to continue */
-
-            if (!SubTable->Length)
-            {
-                AcpiOsPrintf ("Invalid zero length subtable\n");
-                return 0;
-            }
-            goto NextSubTable;
-        }
-
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (S3ptTable->Length, Offset, SubTable,
-            SubTable->Length, InfoTable);
-        if (ACPI_FAILURE (Status))
-        {
-            return 0;
-        }
-
-NextSubTable:
-        /* Point to next subtable */
-
-        Offset += SubTable->Length;
-        SubTable = ACPI_ADD_PTR (ACPI_FPDT_HEADER, SubTable, SubTable->Length);
-    }
-
-    return (S3ptTable->Length);
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpSlic
- *
- * PARAMETERS:  Table               - A SLIC table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a SLIC
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpSlic (
-    ACPI_TABLE_HEADER       *Table)
-{
-
-    (void) AcpiDmDumpTable (Table->Length, sizeof (ACPI_TABLE_HEADER), Table,
-        Table->Length - sizeof (*Table), AcpiDmTableInfoSlic);
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpSlit
- *
- * PARAMETERS:  Table               - An SLIT
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a SLIT
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpSlit (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    UINT32                  Offset;
-    UINT8                   *Row;
-    UINT32                  Localities;
-    UINT32                  i;
-    UINT32                  j;
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Table->Length, 0, Table, 0, AcpiDmTableInfoSlit);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    /* Display the Locality NxN Matrix */
-
-    Localities = (UINT32) ACPI_CAST_PTR (ACPI_TABLE_SLIT, Table)->LocalityCount;
-    Offset = ACPI_OFFSET (ACPI_TABLE_SLIT, Entry[0]);
-    Row = (UINT8 *) ACPI_CAST_PTR (ACPI_TABLE_SLIT, Table)->Entry;
-
-    for (i = 0; i < Localities; i++)
-    {
-        /* Display one row of the matrix */
-
-        AcpiDmLineHeader2 (Offset, Localities, "Locality", i);
-        for  (j = 0; j < Localities; j++)
-        {
-            /* Check for beyond EOT */
-
-            if (Offset >= Table->Length)
-            {
-                AcpiOsPrintf (
-                    "\n**** Not enough room in table for all localities\n");
-                return;
-            }
-
-            AcpiOsPrintf ("%2.2X", Row[j]);
-            Offset++;
-
-            /* Display up to 16 bytes per output row */
-
-            if ((j+1) < Localities)
-            {
-                AcpiOsPrintf (" ");
-
-                if (j && (((j+1) % 16) == 0))
-                {
-                    AcpiOsPrintf ("\\\n"); /* With line continuation char */
-                    AcpiDmLineHeader (Offset, 0, NULL);
-                }
-            }
-        }
-
-        /* Point to next row */
-
-        AcpiOsPrintf ("\n");
-        Row += Localities;
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpSrat
- *
- * PARAMETERS:  Table               - A SRAT table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a SRAT
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpSrat (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    UINT32                  Offset = sizeof (ACPI_TABLE_SRAT);
-    ACPI_SUBTABLE_HEADER    *SubTable;
-    ACPI_DMTABLE_INFO       *InfoTable;
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Table->Length, 0, Table, 0, AcpiDmTableInfoSrat);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    /* Subtables */
-
-    SubTable = ACPI_ADD_PTR (ACPI_SUBTABLE_HEADER, Table, Offset);
-    while (Offset < Table->Length)
-    {
-        /* Common subtable header */
-
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Table->Length, Offset, SubTable,
-            SubTable->Length, AcpiDmTableInfoSratHdr);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        switch (SubTable->Type)
-        {
-        case ACPI_SRAT_TYPE_CPU_AFFINITY:
-
-            InfoTable = AcpiDmTableInfoSrat0;
-            break;
-
-        case ACPI_SRAT_TYPE_MEMORY_AFFINITY:
-
-            InfoTable = AcpiDmTableInfoSrat1;
-            break;
-
-        case ACPI_SRAT_TYPE_X2APIC_CPU_AFFINITY:
-
-            InfoTable = AcpiDmTableInfoSrat2;
-            break;
-
-        case ACPI_SRAT_TYPE_GICC_AFFINITY:
-
-            InfoTable = AcpiDmTableInfoSrat3;
-            break;
-
-        case ACPI_SRAT_TYPE_GIC_ITS_AFFINITY:
-
-            InfoTable = AcpiDmTableInfoSrat4;
-            break;
-
-        default:
-            AcpiOsPrintf ("\n**** Unknown SRAT subtable type 0x%X\n",
-                SubTable->Type);
-
-            /* Attempt to continue */
-
-            if (!SubTable->Length)
-            {
-                AcpiOsPrintf ("Invalid zero length subtable\n");
-                return;
-            }
-            goto NextSubTable;
-        }
-
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Table->Length, Offset, SubTable,
-            SubTable->Length, InfoTable);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-NextSubTable:
-        /* Point to next subtable */
-
-        Offset += SubTable->Length;
-        SubTable = ACPI_ADD_PTR (ACPI_SUBTABLE_HEADER, SubTable,
-            SubTable->Length);
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpStao
- *
- * PARAMETERS:  Table               - A STAO table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a STAO. This is a variable-length
- *              table that contains an open-ended number of ASCII strings
- *              at the end of the table.
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpStao (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    char                    *Namepath;
-    UINT32                  Length = Table->Length;
-    UINT32                  StringLength;
-    UINT32                  Offset = sizeof (ACPI_TABLE_STAO);
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Length, 0, Table, 0, AcpiDmTableInfoStao);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    /* The rest of the table consists of Namepath strings */
-
-    while (Offset < Table->Length)
-    {
-        Namepath = ACPI_ADD_PTR (char, Table, Offset);
-        StringLength = strlen (Namepath) + 1;
-
-        AcpiDmLineHeader (Offset, StringLength, "Namestring");
-        AcpiOsPrintf ("\"%s\"\n", Namepath);
-
-        /* Point to next namepath */
-
-        Offset += StringLength;
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpTcpa
- *
- * PARAMETERS:  Table               - A TCPA table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a TCPA.
- *
- * NOTE:        There are two versions of the table with the same signature:
- *              the client version and the server version. The common
- *              PlatformClass field is used to differentiate the two types of
- *              tables.
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpTcpa (
-    ACPI_TABLE_HEADER       *Table)
-{
-    UINT32                  Offset = sizeof (ACPI_TABLE_TCPA_HDR);
-    ACPI_TABLE_TCPA_HDR     *CommonHeader = ACPI_CAST_PTR (
-                                ACPI_TABLE_TCPA_HDR, Table);
-    ACPI_TABLE_TCPA_HDR     *SubTable = ACPI_ADD_PTR (
-                                ACPI_TABLE_TCPA_HDR, Table, Offset);
-    ACPI_STATUS             Status;
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Table->Length, 0, Table,
-        0, AcpiDmTableInfoTcpaHdr);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    /*
-     * Examine the PlatformClass field to determine the table type.
-     * Either a client or server table. Only one.
-     */
-    switch (CommonHeader->PlatformClass)
-    {
-    case ACPI_TCPA_CLIENT_TABLE:
-
-        Status = AcpiDmDumpTable (Table->Length, Offset, SubTable,
-            Table->Length - Offset, AcpiDmTableInfoTcpaClient);
-        break;
-
-    case ACPI_TCPA_SERVER_TABLE:
-
-        Status = AcpiDmDumpTable (Table->Length, Offset, SubTable,
-            Table->Length - Offset, AcpiDmTableInfoTcpaServer);
-        break;
-
-    default:
-
-        AcpiOsPrintf ("\n**** Unknown TCPA Platform Class 0x%X\n",
-            CommonHeader->PlatformClass);
-        Status = AE_ERROR;
-        break;
-    }
-
-    if (ACPI_FAILURE (Status))
-    {
-        AcpiOsPrintf ("\n**** Cannot disassemble TCPA table\n");
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpVrtc
- *
- * PARAMETERS:  Table               - A VRTC table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a VRTC
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpVrtc (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    UINT32                  Offset = sizeof (ACPI_TABLE_VRTC);
-    ACPI_VRTC_ENTRY         *SubTable;
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Table->Length, 0, Table, 0, AcpiDmTableInfoVrtc);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    /* Subtables */
-
-    SubTable = ACPI_ADD_PTR (ACPI_VRTC_ENTRY, Table, Offset);
-    while (Offset < Table->Length)
-    {
-        /* Common subtable header */
-
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Table->Length, Offset, SubTable,
-            sizeof (ACPI_VRTC_ENTRY), AcpiDmTableInfoVrtc0);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        /* Point to next subtable */
-
-        Offset += sizeof (ACPI_VRTC_ENTRY);
-        SubTable = ACPI_ADD_PTR (ACPI_VRTC_ENTRY, SubTable,
-            sizeof (ACPI_VRTC_ENTRY));
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpWdat
- *
- * PARAMETERS:  Table               - A WDAT table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a WDAT
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpWdat (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    UINT32                  Offset = sizeof (ACPI_TABLE_WDAT);
-    ACPI_WDAT_ENTRY         *SubTable;
-
-
-    /* Main table */
-
-    Status = AcpiDmDumpTable (Table->Length, 0, Table, 0, AcpiDmTableInfoWdat);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    /* Subtables */
-
-    SubTable = ACPI_ADD_PTR (ACPI_WDAT_ENTRY, Table, Offset);
-    while (Offset < Table->Length)
-    {
-        /* Common subtable header */
-
-        AcpiOsPrintf ("\n");
-        Status = AcpiDmDumpTable (Table->Length, Offset, SubTable,
-            sizeof (ACPI_WDAT_ENTRY), AcpiDmTableInfoWdat0);
-        if (ACPI_FAILURE (Status))
-        {
-            return;
-        }
-
-        /* Point to next subtable */
-
-        Offset += sizeof (ACPI_WDAT_ENTRY);
-        SubTable = ACPI_ADD_PTR (ACPI_WDAT_ENTRY, SubTable,
-            sizeof (ACPI_WDAT_ENTRY));
-    }
-}
-
-
-/*******************************************************************************
- *
- * FUNCTION:    AcpiDmDumpWpbt
- *
- * PARAMETERS:  Table               - A WPBT table
- *
- * RETURN:      None
- *
- * DESCRIPTION: Format the contents of a WPBT. This table type consists
- *              of an open-ended arguments buffer at the end of the table.
- *
- ******************************************************************************/
-
-void
-AcpiDmDumpWpbt (
-    ACPI_TABLE_HEADER       *Table)
-{
-    ACPI_STATUS             Status;
-    ACPI_TABLE_WPBT         *SubTable;
-    UINT32                  Length = Table->Length;
-    UINT16                  ArgumentsLength;
-
-
-    /* Dump the main table */
-
-    Status = AcpiDmDumpTable (Length, 0, Table, 0, AcpiDmTableInfoWpbt);
-    if (ACPI_FAILURE (Status))
-    {
-        return;
-    }
-
-    /* Extract the arguments buffer length from the main table */
-
-    SubTable = ACPI_CAST_PTR (ACPI_TABLE_WPBT, Table);
-    ArgumentsLength = SubTable->ArgumentsLength;
-
-    /* Dump the arguments buffer */
-
-    (void) AcpiDmDumpTable (Table->Length, 0, Table, ArgumentsLength,
-        AcpiDmTableInfoWpbt0);
-}
diff --git a/sys/contrib/dev/acpica/source/common/dmtbdump1.c b/sys/contrib/dev/acpica/source/common/dmtbdump1.c
new file mode 100644 (file)
index 0000000..4495ba4
--- /dev/null
@@ -0,0 +1,1542 @@
+/******************************************************************************
+ *
+ * Module Name: dmtbdump1 - Dump ACPI data tables that contain no AML code
+ *
+ *****************************************************************************/
+
+/******************************************************************************
+ *
+ * 1. Copyright Notice
+ *
+ * Some or all of this work - Copyright (c) 1999 - 2018, Intel Corp.
+ * All rights reserved.
+ *
+ * 2. License
+ *
+ * 2.1. This is your license from Intel Corp. under its intellectual property
+ * rights. You may have additional license terms from the party that provided
+ * you this software, covering your right to use that party's intellectual
+ * property rights.
+ *
+ * 2.2. Intel grants, free of charge, to any person ("Licensee") obtaining a
+ * copy of the source code appearing in this file ("Covered Code") an
+ * irrevocable, perpetual, worldwide license under Intel's copyrights in the
+ * base code distributed originally by Intel ("Original Intel Code") to copy,
+ * make derivatives, distribute, use and display any portion of the Covered
+ * Code in any form, with the right to sublicense such rights; and
+ *
+ * 2.3. Intel grants Licensee a non-exclusive and non-transferable patent
+ * license (with the right to sublicense), under only those claims of Intel
+ * patents that are infringed by the Original Intel Code, to make, use, sell,
+ * offer to sell, and import the Covered Code and derivative works thereof
+ * solely to the minimum extent necessary to exercise the above copyright
+ * license, and in no event shall the patent license extend to any additions
+ * to or modifications of the Original Intel Code. No other license or right
+ * is granted directly or by implication, estoppel or otherwise;
+ *
+ * The above copyright and patent license is granted only if the following
+ * conditions are met:
+ *
+ * 3. Conditions
+ *
+ * 3.1. Redistribution of Source with Rights to Further Distribute Source.
+ * Redistribution of source code of any substantial portion of the Covered
+ * Code or modification with rights to further distribute source must include
+ * the above Copyright Notice, the above License, this list of Conditions,
+ * and the following Disclaimer and Export Compliance provision. In addition,
+ * Licensee must cause all Covered Code to which Licensee contributes to
+ * contain a file documenting the changes Licensee made to create that Covered
+ * Code and the date of any change. Licensee must include in that file the
+ * documentation of any changes made by any predecessor Licensee. Licensee
+ * must include a prominent statement that the modification is derived,
+ * directly or indirectly, from Original Intel Code.
+ *
+ * 3.2. Redistribution of Source with no Rights to Further Distribute Source.
+ * Redistribution of source code of any substantial portion of the Covered
+ * Code or modification without rights to further distribute source must
+ * include the following Disclaimer and Export Compliance provision in the
+ * documentation and/or other materials provided with distribution. In
+ * addition, Licensee may not authorize further sublicense of source of any
+ * portion of the Covered Code, and must include terms to the effect that the
+ * license from Licensee to its licensee is limited to the intellectual
+ * property embodied in the software Licensee provides to its licensee, and
+ * not to intellectual property embodied in modifications its licensee may
+ * make.
+ *
+ * 3.3. Redistribution of Executable. Redistribution in executable form of any
+ * substantial portion of the Covered Code or modification must reproduce the
+ * above Copyright Notice, and the following Disclaimer and Export Compliance
+ * provision in the documentation and/or other materials provided with the
+ * distribution.
+ *
+ * 3.4. Intel retains all right, title, and interest in and to the Original
+ * Intel Code.
+ *
+ * 3.5. Neither the name Intel nor any other trademark owned or controlled by
+ * Intel shall be used in advertising or otherwise to promote the sale, use or
+ * other dealings in products derived from or relating to the Covered Code
+ * without prior written authorization from Intel.
+ *
+ * 4. Disclaimer and Export Compliance
+ *
+ * 4.1. INTEL MAKES NO WARRANTY OF ANY KIND REGARDING ANY SOFTWARE PROVIDED
+ * HERE. ANY SOFTWARE ORIGINATING FROM INTEL OR DERIVED FROM INTEL SOFTWARE
+ * IS PROVIDED "AS IS," AND INTEL WILL NOT PROVIDE ANY SUPPORT, ASSISTANCE,
+ * INSTALLATION, TRAINING OR OTHER SERVICES. INTEL WILL NOT PROVIDE ANY
+ * UPDATES, ENHANCEMENTS OR EXTENSIONS. INTEL SPECIFICALLY DISCLAIMS ANY
+ * IMPLIED WARRANTIES OF MERCHANTABILITY, NONINFRINGEMENT AND FITNESS FOR A
+ * PARTICULAR PURPOSE.
+ *
+ * 4.2. IN NO EVENT SHALL INTEL HAVE ANY LIABILITY TO LICENSEE, ITS LICENSEES
+ * OR ANY OTHER THIRD PARTY, FOR ANY LOST PROFITS, LOST DATA, LOSS OF USE OR
+ * COSTS OF PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES, OR FOR ANY INDIRECT,
+ * SPECIAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THIS AGREEMENT, UNDER ANY
+ * CAUSE OF ACTION OR THEORY OF LIABILITY, AND IRRESPECTIVE OF WHETHER INTEL
+ * HAS ADVANCE NOTICE OF THE POSSIBILITY OF SUCH DAMAGES. THESE LIMITATIONS
+ * SHALL APPLY NOTWITHSTANDING THE FAILURE OF THE ESSENTIAL PURPOSE OF ANY
+ * LIMITED REMEDY.
+ *
+ * 4.3. Licensee shall not export, either directly or indirectly, any of this
+ * software or system incorporating such software without first obtaining any
+ * required license or other approval from the U. S. Department of Commerce or
+ * any other agency or department of the United States Government. In the
+ * event Licensee exports any such software from the United States or
+ * re-exports any such software from a foreign destination, Licensee shall
+ * ensure that the distribution and export/re-export of the software is in
+ * compliance with all laws, regulations, orders, or other restrictions of the
+ * U.S. Export Administration Regulations. Licensee agrees that neither it nor
+ * any of its subsidiaries will export/re-export any technical data, process,
+ * software, or service, directly or indirectly, to any country for which the
+ * United States government or any agency thereof requires an export license,
+ * other governmental approval, or letter of assurance, without first obtaining
+ * such license, approval or letter.
+ *
+ *****************************************************************************
+ *
+ * Alternatively, you may choose to be licensed under the terms of the
+ * following license:
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions, and the following disclaimer,
+ *    without modification.
+ * 2. Redistributions in binary form must reproduce at minimum a disclaimer
+ *    substantially similar to the "NO WARRANTY" disclaimer below
+ *    ("Disclaimer") and any redistribution must be conditioned upon
+ *    including a substantially similar Disclaimer requirement for further
+ *    binary redistribution.
+ * 3. Neither the names of the above-listed copyright holders nor the names
+ *    of any contributors may be used to endorse or promote products derived
+ *    from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ *
+ * Alternatively, you may choose to be licensed under the terms of the
+ * GNU General Public License ("GPL") version 2 as published by the Free
+ * Software Foundation.
+ *
+ *****************************************************************************/
+
+#include "acpi.h"
+#include "accommon.h"
+#include "acdisasm.h"
+#include "actables.h"
+
+/* This module used for application-level code only */
+
+#define _COMPONENT          ACPI_CA_DISASSEMBLER
+        ACPI_MODULE_NAME    ("dmtbdump1")
+
+
+/*******************************************************************************
+ *
+ * FUNCTION:    AcpiDmDumpAsf
+ *
+ * PARAMETERS:  Table               - A ASF table
+ *
+ * RETURN:      None
+ *
+ * DESCRIPTION: Format the contents of a ASF table
+ *
+ ******************************************************************************/
+
+void
+AcpiDmDumpAsf (
+    ACPI_TABLE_HEADER       *Table)
+{
+    ACPI_STATUS             Status;
+    UINT32                  Offset = sizeof (ACPI_TABLE_HEADER);
+    ACPI_ASF_INFO           *Subtable;
+    ACPI_DMTABLE_INFO       *InfoTable;
+    ACPI_DMTABLE_INFO       *DataInfoTable = NULL;
+    UINT8                   *DataTable = NULL;
+    UINT32                  DataCount = 0;
+    UINT32                  DataLength = 0;
+    UINT32                  DataOffset = 0;
+    UINT32                  i;
+    UINT8                   Type;
+
+
+    /* No main table, only subtables */
+
+    Subtable = ACPI_ADD_PTR (ACPI_ASF_INFO, Table, Offset);
+    while (Offset < Table->Length)
+    {
+        /* Common subtable header */
+
+        Status = AcpiDmDumpTable (Table->Length, Offset, Subtable,
+            Subtable->Header.Length, AcpiDmTableInfoAsfHdr);
+        if (ACPI_FAILURE (Status))
+        {
+            return;
+        }
+
+        /* The actual type is the lower 7 bits of Type */
+
+        Type = (UINT8) (Subtable->Header.Type & 0x7F);
+
+        switch (Type)
+        {
+        case ACPI_ASF_TYPE_INFO:
+
+            InfoTable = AcpiDmTableInfoAsf0;
+            break;
+
+        case ACPI_ASF_TYPE_ALERT:
+
+            InfoTable = AcpiDmTableInfoAsf1;
+            DataInfoTable = AcpiDmTableInfoAsf1a;
+            DataTable = ACPI_ADD_PTR (UINT8, Subtable, sizeof (ACPI_ASF_ALERT));
+            DataCount = ACPI_CAST_PTR (ACPI_ASF_ALERT, Subtable)->Alerts;
+            DataLength = ACPI_CAST_PTR (ACPI_ASF_ALERT, Subtable)->DataLength;
+            DataOffset = Offset + sizeof (ACPI_ASF_ALERT);
+            break;
+
+        case ACPI_ASF_TYPE_CONTROL:
+
+            InfoTable = AcpiDmTableInfoAsf2;
+            DataInfoTable = AcpiDmTableInfoAsf2a;
+            DataTable = ACPI_ADD_PTR (UINT8, Subtable, sizeof (ACPI_ASF_REMOTE));
+            DataCount = ACPI_CAST_PTR (ACPI_ASF_REMOTE, Subtable)->Controls;
+            DataLength = ACPI_CAST_PTR (ACPI_ASF_REMOTE, Subtable)->DataLength;
+            DataOffset = Offset + sizeof (ACPI_ASF_REMOTE);
+            break;
+
+        case ACPI_ASF_TYPE_BOOT:
+
+            InfoTable = AcpiDmTableInfoAsf3;
+            break;
+
+        case ACPI_ASF_TYPE_ADDRESS:
+
+            InfoTable = AcpiDmTableInfoAsf4;
+            DataTable = ACPI_ADD_PTR (UINT8, Subtable, sizeof (ACPI_ASF_ADDRESS));
+            DataLength = ACPI_CAST_PTR (ACPI_ASF_ADDRESS, Subtable)->Devices;
+            DataOffset = Offset + sizeof (ACPI_ASF_ADDRESS);
+            break;
+
+        default:
+
+            AcpiOsPrintf ("\n**** Unknown ASF subtable type 0x%X\n",
+                Subtable->Header.Type);
+            return;
+        }
+
+        Status = AcpiDmDumpTable (Table->Length, Offset, Subtable,
+            Subtable->Header.Length, InfoTable);
+        if (ACPI_FAILURE (Status))
+        {
+            return;
+        }
+
+        /* Dump variable-length extra data */
+
+        switch (Type)
+        {
+        case ACPI_ASF_TYPE_ALERT:
+        case ACPI_ASF_TYPE_CONTROL:
+
+            for (i = 0; i < DataCount; i++)
+            {
+                AcpiOsPrintf ("\n");
+                Status = AcpiDmDumpTable (Table->Length, DataOffset,
+                    DataTable, DataLength, DataInfoTable);
+                if (ACPI_FAILURE (Status))
+                {
+                    return;
+                }
+
+                DataTable = ACPI_ADD_PTR (UINT8, DataTable, DataLength);
+                DataOffset += DataLength;
+            }
+            break;
+
+        case ACPI_ASF_TYPE_ADDRESS:
+
+            for (i = 0; i < DataLength; i++)
+            {
+                if (!(i % 16))
+                {
+                    AcpiDmLineHeader (DataOffset, 1, "Addresses");
+                }
+
+                AcpiOsPrintf ("%2.2X ", *DataTable);
+                DataTable++;
+                DataOffset++;
+
+                if (DataOffset > Table->Length)
+                {
+                    AcpiOsPrintf (
+                        "**** ACPI table terminates in the middle of a "
+                        "data structure! (ASF! table)\n");
+                    return;
+                }
+            }
+
+            AcpiOsPrintf ("\n");
+            break;
+
+        default:
+
+            break;
+        }
+
+        AcpiOsPrintf ("\n");
+
+        /* Point to next subtable */
+
+        if (!Subtable->Header.Length)
+        {
+            AcpiOsPrintf ("Invalid zero subtable header length\n");
+            return;
+        }
+
+        Offset += Subtable->Header.Length;
+        Subtable = ACPI_ADD_PTR (ACPI_ASF_INFO, Subtable,
+            Subtable->Header.Length);
+    }
+}
+
+
+/*******************************************************************************
+ *
+ * FUNCTION:    AcpiDmDumpCpep
+ *
+ * PARAMETERS:  Table               - A CPEP table
+ *
+ * RETURN:      None
+ *
+ * DESCRIPTION: Format the contents of a CPEP. This table type consists
+ *              of an open-ended number of subtables.
+ *
+ ******************************************************************************/
+
+void
+AcpiDmDumpCpep (
+    ACPI_TABLE_HEADER       *Table)
+{
+    ACPI_STATUS             Status;
+    ACPI_CPEP_POLLING       *Subtable;
+    UINT32                  Length = Table->Length;
+    UINT32                  Offset = sizeof (ACPI_TABLE_CPEP);
+
+
+    /* Main table */
+
+    Status = AcpiDmDumpTable (Length, 0, Table, 0, AcpiDmTableInfoCpep);
+    if (ACPI_FAILURE (Status))
+    {
+        return;
+    }
+
+    /* Subtables */
+
+    Subtable = ACPI_ADD_PTR (ACPI_CPEP_POLLING, Table, Offset);
+    while (Offset < Table->Length)
+    {
+        AcpiOsPrintf ("\n");
+        Status = AcpiDmDumpTable (Length, Offset, Subtable,
+            Subtable->Header.Length, AcpiDmTableInfoCpep0);
+        if (ACPI_FAILURE (Status))
+        {
+            return;
+        }
+
+        /* Point to next subtable */
+
+        Offset += Subtable->Header.Length;
+        Subtable = ACPI_ADD_PTR (ACPI_CPEP_POLLING, Subtable,
+            Subtable->Header.Length);
+    }
+}
+
+
+/*******************************************************************************
+ *
+ * FUNCTION:    AcpiDmDumpCsrt
+ *
+ * PARAMETERS:  Table               - A CSRT table
+ *
+ * RETURN:      None
+ *
+ * DESCRIPTION: Format the contents of a CSRT. This table type consists
+ *              of an open-ended number of subtables.
+ *
+ ******************************************************************************/
+
+void
+AcpiDmDumpCsrt (
+    ACPI_TABLE_HEADER       *Table)
+{
+    ACPI_STATUS             Status;
+    ACPI_CSRT_GROUP         *Subtable;
+    ACPI_CSRT_SHARED_INFO   *SharedInfoTable;
+    ACPI_CSRT_DESCRIPTOR    *SubSubtable;
+    UINT32                  Length = Table->Length;
+    UINT32                  Offset = sizeof (ACPI_TABLE_CSRT);
+    UINT32                  SubOffset;
+    UINT32                  SubSubOffset;
+    UINT32                  InfoLength;
+
+
+    /* The main table only contains the ACPI header, thus already handled */
+
+    /* Subtables (Resource Groups) */
+
+    Subtable = ACPI_ADD_PTR (ACPI_CSRT_GROUP, Table, Offset);
+    while (Offset < Table->Length)
+    {
+        /* Resource group subtable */
+
+        AcpiOsPrintf ("\n");
+        Status = AcpiDmDumpTable (Length, Offset, Subtable,
+            Subtable->Length, AcpiDmTableInfoCsrt0);
+        if (ACPI_FAILURE (Status))
+        {
+            return;
+        }
+
+        /* Shared info subtable (One per resource group) */
+
+        SubOffset = sizeof (ACPI_CSRT_GROUP);
+        SharedInfoTable = ACPI_ADD_PTR (ACPI_CSRT_SHARED_INFO, Table,
+            Offset + SubOffset);
+
+        AcpiOsPrintf ("\n");
+        Status = AcpiDmDumpTable (Length, Offset + SubOffset, SharedInfoTable,
+            sizeof (ACPI_CSRT_SHARED_INFO), AcpiDmTableInfoCsrt1);
+        if (ACPI_FAILURE (Status))
+        {
+            return;
+        }
+
+        SubOffset += Subtable->SharedInfoLength;
+
+        /* Sub-Subtables (Resource Descriptors) */
+
+        SubSubtable = ACPI_ADD_PTR (ACPI_CSRT_DESCRIPTOR, Table,
+            Offset + SubOffset);
+
+        while ((SubOffset < Subtable->Length) &&
+              ((Offset + SubOffset) < Table->Length))
+        {
+            AcpiOsPrintf ("\n");
+            Status = AcpiDmDumpTable (Length, Offset + SubOffset, SubSubtable,
+                SubSubtable->Length, AcpiDmTableInfoCsrt2);
+            if (ACPI_FAILURE (Status))
+            {
+                return;
+            }
+
+            SubSubOffset = sizeof (ACPI_CSRT_DESCRIPTOR);
+
+            /* Resource-specific info buffer */
+
+            InfoLength = SubSubtable->Length - SubSubOffset;
+            if (InfoLength)
+            {
+                Status = AcpiDmDumpTable (Length,
+                    Offset + SubOffset + SubSubOffset, Table,
+                    InfoLength, AcpiDmTableInfoCsrt2a);
+                if (ACPI_FAILURE (Status))
+                {
+                    return;
+                }
+                SubSubOffset += InfoLength;
+            }
+
+            /* Point to next sub-subtable */
+
+            SubOffset += SubSubtable->Length;
+            SubSubtable = ACPI_ADD_PTR (ACPI_CSRT_DESCRIPTOR, SubSubtable,
+                SubSubtable->Length);
+        }
+
+        /* Point to next subtable */
+
+        Offset += Subtable->Length;
+        Subtable = ACPI_ADD_PTR (ACPI_CSRT_GROUP, Subtable,
+            Subtable->Length);
+    }
+}
+
+
+/*******************************************************************************
+ *
+ * FUNCTION:    AcpiDmDumpDbg2
+ *
+ * PARAMETERS:  Table               - A DBG2 table
+ *
+ * RETURN:      None
+ *
+ * DESCRIPTION: Format the contents of a DBG2. This table type consists
+ *              of an open-ended number of subtables.
+ *
+ ******************************************************************************/
+
+void
+AcpiDmDumpDbg2 (
+    ACPI_TABLE_HEADER       *Table)
+{
+    ACPI_STATUS             Status;
+    ACPI_DBG2_DEVICE        *Subtable;
+    UINT32                  Length = Table->Length;
+    UINT32                  Offset = sizeof (ACPI_TABLE_DBG2);
+    UINT32                  i;
+    UINT32                  ArrayOffset;
+    UINT32                  AbsoluteOffset;
+    UINT8                   *Array;
+
+
+    /* Main table */
+
+    Status = AcpiDmDumpTable (Length, 0, Table, 0, AcpiDmTableInfoDbg2);
+    if (ACPI_FAILURE (Status))
+    {
+        return;
+    }
+
+    /* Subtables */
+
+    Subtable = ACPI_ADD_PTR (ACPI_DBG2_DEVICE, Table, Offset);
+    while (Offset < Table->Length)
+    {
+        AcpiOsPrintf ("\n");
+        Status = AcpiDmDumpTable (Length, Offset, Subtable,
+            Subtable->Length, AcpiDmTableInfoDbg2Device);
+        if (ACPI_FAILURE (Status))
+        {
+            return;
+        }
+
+        /* Dump the BaseAddress array */
+
+        for (i = 0; i < Subtable->RegisterCount; i++)
+        {
+            ArrayOffset = Subtable->BaseAddressOffset +
+                (sizeof (ACPI_GENERIC_ADDRESS) * i);
+            AbsoluteOffset = Offset + ArrayOffset;
+            Array = (UINT8 *) Subtable + ArrayOffset;
+
+            Status = AcpiDmDumpTable (Length, AbsoluteOffset, Array,
+                Subtable->Length, AcpiDmTableInfoDbg2Addr);
+            if (ACPI_FAILURE (Status))
+            {
+                return;
+            }
+        }
+
+        /* Dump the AddressSize array */
+
+        for (i = 0; i < Subtable->RegisterCount; i++)
+        {
+            ArrayOffset = Subtable->AddressSizeOffset +
+                (sizeof (UINT32) * i);
+            AbsoluteOffset = Offset + ArrayOffset;
+            Array = (UINT8 *) Subtable + ArrayOffset;
+
+            Status = AcpiDmDumpTable (Length, AbsoluteOffset, Array,
+                Subtable->Length, AcpiDmTableInfoDbg2Size);
+            if (ACPI_FAILURE (Status))
+            {
+                return;
+            }
+        }
+
+        /* Dump the Namestring (required) */
+
+        AcpiOsPrintf ("\n");
+        ArrayOffset = Subtable->NamepathOffset;
+        AbsoluteOffset = Offset + ArrayOffset;
+        Array = (UINT8 *) Subtable + ArrayOffset;
+
+        Status = AcpiDmDumpTable (Length, AbsoluteOffset, Array,
+            Subtable->Length, AcpiDmTableInfoDbg2Name);
+        if (ACPI_FAILURE (Status))
+        {
+            return;
+        }
+
+        /* Dump the OemData (optional) */
+
+        if (Subtable->OemDataOffset)
+        {
+            Status = AcpiDmDumpTable (Length, Offset + Subtable->OemDataOffset,
+                Table, Subtable->OemDataLength,
+                AcpiDmTableInfoDbg2OemData);
+            if (ACPI_FAILURE (Status))
+            {
+                return;
+            }
+        }
+
+        /* Point to next subtable */
+
+        Offset += Subtable->Length;
+        Subtable = ACPI_ADD_PTR (ACPI_DBG2_DEVICE, Subtable,
+            Subtable->Length);
+    }
+}
+
+
+/*******************************************************************************
+ *
+ * FUNCTION:    AcpiDmDumpDmar
+ *
+ * PARAMETERS:  Table               - A DMAR table
+ *
+ * RETURN:      None
+ *
+ * DESCRIPTION: Format the contents of a DMAR. This table type consists
+ *              of an open-ended number of subtables.
+ *
+ ******************************************************************************/
+
+void
+AcpiDmDumpDmar (
+    ACPI_TABLE_HEADER       *Table)
+{
+    ACPI_STATUS             Status;
+    ACPI_DMAR_HEADER        *Subtable;
+    UINT32                  Length = Table->Length;
+    UINT32                  Offset = sizeof (ACPI_TABLE_DMAR);
+    ACPI_DMTABLE_INFO       *InfoTable;
+    ACPI_DMAR_DEVICE_SCOPE  *ScopeTable;
+    UINT32                  ScopeOffset;
+    UINT8                   *PciPath;
+    UINT32                  PathOffset;
+
+
+    /* Main table */
+
+    Status = AcpiDmDumpTable (Length, 0, Table, 0, AcpiDmTableInfoDmar);
+    if (ACPI_FAILURE (Status))
+    {
+        return;
+    }
+
+    /* Subtables */
+
+    Subtable = ACPI_ADD_PTR (ACPI_DMAR_HEADER, Table, Offset);
+    while (Offset < Table->Length)
+    {
+        /* Common subtable header */
+
+        AcpiOsPrintf ("\n");
+        Status = AcpiDmDumpTable (Length, Offset, Subtable,
+            Subtable->Length, AcpiDmTableInfoDmarHdr);
+        if (ACPI_FAILURE (Status))
+        {
+            return;
+        }
+
+        AcpiOsPrintf ("\n");
+
+        switch (Subtable->Type)
+        {
+        case ACPI_DMAR_TYPE_HARDWARE_UNIT:
+
+            InfoTable = AcpiDmTableInfoDmar0;
+            ScopeOffset = sizeof (ACPI_DMAR_HARDWARE_UNIT);
+            break;
+
+        case ACPI_DMAR_TYPE_RESERVED_MEMORY:
+
+            InfoTable = AcpiDmTableInfoDmar1;
+            ScopeOffset = sizeof (ACPI_DMAR_RESERVED_MEMORY);
+            break;
+
+        case ACPI_DMAR_TYPE_ROOT_ATS:
+
+            InfoTable = AcpiDmTableInfoDmar2;
+            ScopeOffset = sizeof (ACPI_DMAR_ATSR);
+            break;
+
+        case ACPI_DMAR_TYPE_HARDWARE_AFFINITY:
+
+            InfoTable = AcpiDmTableInfoDmar3;
+            ScopeOffset = sizeof (ACPI_DMAR_RHSA);
+            break;
+
+        case ACPI_DMAR_TYPE_NAMESPACE:
+
+            InfoTable = AcpiDmTableInfoDmar4;
+            ScopeOffset = sizeof (ACPI_DMAR_ANDD);
+            break;
+
+        default:
+
+            AcpiOsPrintf ("\n**** Unknown DMAR subtable type 0x%X\n\n",
+                Subtable->Type);
+            return;
+        }
+
+        Status = AcpiDmDumpTable (Length, Offset, Subtable,
+            Subtable->Length, InfoTable);
+        if (ACPI_FAILURE (Status))
+        {
+            return;
+        }
+
+        /*
+         * Dump the optional device scope entries
+         */
+        if ((Subtable->Type == ACPI_DMAR_TYPE_HARDWARE_AFFINITY) ||
+            (Subtable->Type == ACPI_DMAR_TYPE_NAMESPACE))
+        {
+            /* These types do not support device scopes */
+
+            goto NextSubtable;
+        }
+
+        ScopeTable = ACPI_ADD_PTR (ACPI_DMAR_DEVICE_SCOPE, Subtable, ScopeOffset);
+        while (ScopeOffset < Subtable->Length)
+        {
+            AcpiOsPrintf ("\n");
+            Status = AcpiDmDumpTable (Length, Offset + ScopeOffset, ScopeTable,
+                ScopeTable->Length, AcpiDmTableInfoDmarScope);
+            if (ACPI_FAILURE (Status))
+            {
+                return;
+            }
+            AcpiOsPrintf ("\n");
+
+            /* Dump the PCI Path entries for this device scope */
+
+            PathOffset = sizeof (ACPI_DMAR_DEVICE_SCOPE); /* Path entries start at this offset */
+
+            PciPath = ACPI_ADD_PTR (UINT8, ScopeTable,
+                sizeof (ACPI_DMAR_DEVICE_SCOPE));
+
+            while (PathOffset < ScopeTable->Length)
+            {
+                AcpiDmLineHeader ((PathOffset + ScopeOffset + Offset), 2,
+                    "PCI Path");
+                AcpiOsPrintf ("%2.2X,%2.2X\n", PciPath[0], PciPath[1]);
+
+                /* Point to next PCI Path entry */
+
+                PathOffset += 2;
+                PciPath += 2;
+                AcpiOsPrintf ("\n");
+            }
+
+            /* Point to next device scope entry */
+
+            ScopeOffset += ScopeTable->Length;
+            ScopeTable = ACPI_ADD_PTR (ACPI_DMAR_DEVICE_SCOPE,
+                ScopeTable, ScopeTable->Length);
+        }
+
+NextSubtable:
+        /* Point to next subtable */
+
+        Offset += Subtable->Length;
+        Subtable = ACPI_ADD_PTR (ACPI_DMAR_HEADER, Subtable,
+            Subtable->Length);
+    }
+}
+
+
+/*******************************************************************************
+ *
+ * FUNCTION:    AcpiDmDumpDrtm
+ *
+ * PARAMETERS:  Table               - A DRTM table
+ *
+ * RETURN:      None
+ *
+ * DESCRIPTION: Format the contents of a DRTM.
+ *
+ ******************************************************************************/
+
+void
+AcpiDmDumpDrtm (
+    ACPI_TABLE_HEADER       *Table)
+{
+    ACPI_STATUS             Status;
+    UINT32                  Offset;
+    ACPI_DRTM_VTABLE_LIST   *DrtmVtl;
+    ACPI_DRTM_RESOURCE_LIST *DrtmRl;
+    ACPI_DRTM_DPS_ID        *DrtmDps;
+    UINT32                  Count;
+
+
+    /* Main table */
+
+    Status = AcpiDmDumpTable (Table->Length, 0, Table, 0,
+        AcpiDmTableInfoDrtm);
+    if (ACPI_FAILURE (Status))
+    {
+        return;
+    }
+
+    Offset = sizeof (ACPI_TABLE_DRTM);
+
+    /* Sub-tables */
+
+    /* Dump ValidatedTable length */
+
+    DrtmVtl = ACPI_ADD_PTR (ACPI_DRTM_VTABLE_LIST, Table, Offset);
+    AcpiOsPrintf ("\n");
+    Status = AcpiDmDumpTable (Table->Length, Offset,
+        DrtmVtl, ACPI_OFFSET (ACPI_DRTM_VTABLE_LIST, ValidatedTables),
+        AcpiDmTableInfoDrtm0);
+    if (ACPI_FAILURE (Status))
+    {
+            return;
+    }
+
+    Offset += ACPI_OFFSET (ACPI_DRTM_VTABLE_LIST, ValidatedTables);
+
+    /* Dump Validated table addresses */
+
+    Count = 0;
+    while ((Offset < Table->Length) &&
+            (DrtmVtl->ValidatedTableCount > Count))
+    {
+        Status = AcpiDmDumpTable (Table->Length, Offset,
+            ACPI_ADD_PTR (void, Table, Offset), sizeof (UINT64),
+            AcpiDmTableInfoDrtm0a);
+        if (ACPI_FAILURE (Status))
+        {
+            return;
+        }
+
+        Offset += sizeof (UINT64);
+        Count++;
+    }
+
+    /* Dump ResourceList length */
+
+    DrtmRl = ACPI_ADD_PTR (ACPI_DRTM_RESOURCE_LIST, Table, Offset);
+    AcpiOsPrintf ("\n");
+    Status = AcpiDmDumpTable (Table->Length, Offset,
+        DrtmRl, ACPI_OFFSET (ACPI_DRTM_RESOURCE_LIST, Resources),
+        AcpiDmTableInfoDrtm1);
+    if (ACPI_FAILURE (Status))
+    {
+        return;
+    }
+
+    Offset += ACPI_OFFSET (ACPI_DRTM_RESOURCE_LIST, Resources);
+
+    /* Dump the Resource List */
+
+    Count = 0;
+    while ((Offset < Table->Length) &&
+           (DrtmRl->ResourceCount > Count))
+    {
+        Status = AcpiDmDumpTable (Table->Length, Offset,
+            ACPI_ADD_PTR (void, Table, Offset),
+            sizeof (ACPI_DRTM_RESOURCE), AcpiDmTableInfoDrtm1a);
+        if (ACPI_FAILURE (Status))
+        {
+            return;
+        }
+
+        Offset += sizeof (ACPI_DRTM_RESOURCE);
+        Count++;
+    }
+
+    /* Dump DPS */
+
+    DrtmDps = ACPI_ADD_PTR (ACPI_DRTM_DPS_ID, Table, Offset);
+    AcpiOsPrintf ("\n");
+    (void) AcpiDmDumpTable (Table->Length, Offset,
+        DrtmDps, sizeof (ACPI_DRTM_DPS_ID), AcpiDmTableInfoDrtm2);
+}
+
+
+/*******************************************************************************
+ *
+ * FUNCTION:    AcpiDmDumpEinj
+ *
+ * PARAMETERS:  Table               - A EINJ table
+ *
+ * RETURN:      None
+ *
+ * DESCRIPTION: Format the contents of a EINJ. This table type consists
+ *              of an open-ended number of subtables.
+ *
+ ******************************************************************************/
+
+void
+AcpiDmDumpEinj (
+    ACPI_TABLE_HEADER       *Table)
+{
+    ACPI_STATUS             Status;
+    ACPI_WHEA_HEADER        *Subtable;
+    UINT32                  Length = Table->Length;
+    UINT32                  Offset = sizeof (ACPI_TABLE_EINJ);
+
+
+    /* Main table */
+
+    Status = AcpiDmDumpTable (Length, 0, Table, 0, AcpiDmTableInfoEinj);
+    if (ACPI_FAILURE (Status))
+    {
+        return;
+    }
+
+    /* Subtables */
+
+    Subtable = ACPI_ADD_PTR (ACPI_WHEA_HEADER, Table, Offset);
+    while (Offset < Table->Length)
+    {
+        AcpiOsPrintf ("\n");
+        Status = AcpiDmDumpTable (Length, Offset, Subtable,
+            sizeof (ACPI_WHEA_HEADER), AcpiDmTableInfoEinj0);
+        if (ACPI_FAILURE (Status))
+        {
+            return;
+        }
+
+        /* Point to next subtable (each subtable is of fixed length) */
+
+        Offset += sizeof (ACPI_WHEA_HEADER);
+        Subtable = ACPI_ADD_PTR (ACPI_WHEA_HEADER, Subtable,
+            sizeof (ACPI_WHEA_HEADER));
+    }
+}
+
+
+/*******************************************************************************
+ *
+ * FUNCTION:    AcpiDmDumpErst
+ *
+ * PARAMETERS:  Table               - A ERST table
+ *
+ * RETURN:      None
+ *
+ * DESCRIPTION: Format the contents of a ERST. This table type consists
+ *              of an open-ended number of subtables.
+ *
+ ******************************************************************************/
+
+void
+AcpiDmDumpErst (
+    ACPI_TABLE_HEADER       *Table)
+{
+    ACPI_STATUS             Status;
+    ACPI_WHEA_HEADER        *Subtable;
+    UINT32                  Length = Table->Length;
+    UINT32                  Offset = sizeof (ACPI_TABLE_ERST);
+
+
+    /* Main table */
+
+    Status = AcpiDmDumpTable (Length, 0, Table, 0, AcpiDmTableInfoErst);
+    if (ACPI_FAILURE (Status))
+    {
+        return;
+    }
+
+    /* Subtables */
+
+    Subtable = ACPI_ADD_PTR (ACPI_WHEA_HEADER, Table, Offset);
+    while (Offset < Table->Length)
+    {
+        AcpiOsPrintf ("\n");
+        Status = AcpiDmDumpTable (Length, Offset, Subtable,
+            sizeof (ACPI_WHEA_HEADER), AcpiDmTableInfoErst0);
+        if (ACPI_FAILURE (Status))
+        {
+            return;
+        }
+
+        /* Point to next subtable (each subtable is of fixed length) */
+
+        Offset += sizeof (ACPI_WHEA_HEADER);
+        Subtable = ACPI_ADD_PTR (ACPI_WHEA_HEADER, Subtable,
+            sizeof (ACPI_WHEA_HEADER));
+    }
+}
+
+
+/*******************************************************************************
+ *
+ * FUNCTION:    AcpiDmDumpFpdt
+ *
+ * PARAMETERS:  Table               - A FPDT table
+ *
+ * RETURN:      None
+ *
+ * DESCRIPTION: Format the contents of a FPDT. This table type consists
+ *              of an open-ended number of subtables.
+ *
+ ******************************************************************************/
+
+void
+AcpiDmDumpFpdt (
+    ACPI_TABLE_HEADER       *Table)
+{
+    ACPI_STATUS             Status;
+    ACPI_FPDT_HEADER        *Subtable;
+    UINT32                  Length = Table->Length;
+    UINT32                  Offset = sizeof (ACPI_TABLE_FPDT);
+    ACPI_DMTABLE_INFO       *InfoTable;
+
+
+    /* There is no main table (other than the standard ACPI header) */
+
+    /* Subtables */
+
+    Subtable = ACPI_ADD_PTR (ACPI_FPDT_HEADER, Table, Offset);
+    while (Offset < Table->Length)
+    {
+        /* Common subtable header */
+
+        AcpiOsPrintf ("\n");
+        Status = AcpiDmDumpTable (Length, Offset, Subtable,
+            Subtable->Length, AcpiDmTableInfoFpdtHdr);
+        if (ACPI_FAILURE (Status))
+        {
+            return;
+        }
+
+        switch (Subtable->Type)
+        {
+        case ACPI_FPDT_TYPE_BOOT:
+
+            InfoTable = AcpiDmTableInfoFpdt0;
+            break;
+
+        case ACPI_FPDT_TYPE_S3PERF:
+
+            InfoTable = AcpiDmTableInfoFpdt1;
+            break;
+
+        default:
+
+            AcpiOsPrintf ("\n**** Unknown FPDT subtable type 0x%X\n\n",
+                Subtable->Type);
+
+            /* Attempt to continue */
+
+            if (!Subtable->Length)
+            {
+                AcpiOsPrintf ("Invalid zero length subtable\n");
+                return;
+            }
+            goto NextSubtable;
+        }
+
+        Status = AcpiDmDumpTable (Length, Offset, Subtable,
+            Subtable->Length, InfoTable);
+        if (ACPI_FAILURE (Status))
+        {
+            return;
+        }
+
+NextSubtable:
+        /* Point to next subtable */
+
+        Offset += Subtable->Length;
+        Subtable = ACPI_ADD_PTR (ACPI_FPDT_HEADER, Subtable,
+            Subtable->Length);
+    }
+}
+
+
+/*******************************************************************************
+ *
+ * FUNCTION:    AcpiDmDumpGtdt
+ *
+ * PARAMETERS:  Table               - A GTDT table
+ *
+ * RETURN:      None
+ *
+ * DESCRIPTION: Format the contents of a GTDT. This table type consists
+ *              of an open-ended number of subtables.
+ *
+ ******************************************************************************/
+
+void
+AcpiDmDumpGtdt (
+    ACPI_TABLE_HEADER       *Table)
+{
+    ACPI_STATUS             Status;
+    ACPI_GTDT_HEADER        *Subtable;
+    UINT32                  Length = Table->Length;
+    UINT32                  Offset = sizeof (ACPI_TABLE_GTDT);
+    ACPI_DMTABLE_INFO       *InfoTable;
+    UINT32                  SubtableLength;
+    UINT32                  GtCount;
+    ACPI_GTDT_TIMER_ENTRY   *GtxTable;
+
+
+    /* Main table */
+
+    Status = AcpiDmDumpTable (Length, 0, Table, 0, AcpiDmTableInfoGtdt);
+    if (ACPI_FAILURE (Status))
+    {
+        return;
+    }
+
+    /* Subtables */
+
+    Subtable = ACPI_ADD_PTR (ACPI_GTDT_HEADER, Table, Offset);
+    while (Offset < Table->Length)
+    {
+        /* Common subtable header */
+
+        AcpiOsPrintf ("\n");
+        Status = AcpiDmDumpTable (Length, Offset, Subtable,
+            Subtable->Length, AcpiDmTableInfoGtdtHdr);
+        if (ACPI_FAILURE (Status))
+        {
+            return;
+        }
+
+        GtCount = 0;
+        switch (Subtable->Type)
+        {
+        case ACPI_GTDT_TYPE_TIMER_BLOCK:
+
+            SubtableLength = sizeof (ACPI_GTDT_TIMER_BLOCK);
+            GtCount = (ACPI_CAST_PTR (ACPI_GTDT_TIMER_BLOCK,
+                Subtable))->TimerCount;
+
+            InfoTable = AcpiDmTableInfoGtdt0;
+            break;
+
+        case ACPI_GTDT_TYPE_WATCHDOG:
+
+            SubtableLength = sizeof (ACPI_GTDT_WATCHDOG);
+
+            InfoTable = AcpiDmTableInfoGtdt1;
+            break;
+
+        default:
+
+            /* Cannot continue on unknown type - no length */
+
+            AcpiOsPrintf ("\n**** Unknown GTDT subtable type 0x%X\n",
+                Subtable->Type);
+            return;
+        }
+
+        Status = AcpiDmDumpTable (Length, Offset, Subtable,
+            Subtable->Length, InfoTable);
+        if (ACPI_FAILURE (Status))
+        {
+            return;
+        }
+
+        /* Point to end of current subtable (each subtable above is of fixed length) */
+
+        Offset += SubtableLength;
+
+        /* If there are any Gt Timer Blocks from above, dump them now */
+
+        if (GtCount)
+        {
+            GtxTable = ACPI_ADD_PTR (
+                ACPI_GTDT_TIMER_ENTRY, Subtable, SubtableLength);
+            SubtableLength += GtCount * sizeof (ACPI_GTDT_TIMER_ENTRY);
+
+            while (GtCount)
+            {
+                AcpiOsPrintf ("\n");
+                Status = AcpiDmDumpTable (Length, Offset, GtxTable,
+                    sizeof (ACPI_GTDT_TIMER_ENTRY), AcpiDmTableInfoGtdt0a);
+                if (ACPI_FAILURE (Status))
+                {
+                    return;
+                }
+                Offset += sizeof (ACPI_GTDT_TIMER_ENTRY);
+                GtxTable++;
+                GtCount--;
+            }
+        }
+
+        /* Point to next subtable */
+
+        Subtable = ACPI_ADD_PTR (ACPI_GTDT_HEADER, Subtable, SubtableLength);
+    }
+}
+
+
+/*******************************************************************************
+ *
+ * FUNCTION:    AcpiDmDumpHest
+ *
+ * PARAMETERS:  Table               - A HEST table
+ *
+ * RETURN:      None
+ *
+ * DESCRIPTION: Format the contents of a HEST. This table type consists
+ *              of an open-ended number of subtables.
+ *
+ ******************************************************************************/
+
+void
+AcpiDmDumpHest (
+    ACPI_TABLE_HEADER       *Table)
+{
+    ACPI_STATUS             Status;
+    ACPI_HEST_HEADER        *Subtable;
+    UINT32                  Length = Table->Length;
+    UINT32                  Offset = sizeof (ACPI_TABLE_HEST);
+    ACPI_DMTABLE_INFO       *InfoTable;
+    UINT32                  SubtableLength;
+    UINT32                  BankCount;
+    ACPI_HEST_IA_ERROR_BANK *BankTable;
+
+
+    /* Main table */
+
+    Status = AcpiDmDumpTable (Length, 0, Table, 0, AcpiDmTableInfoHest);
+    if (ACPI_FAILURE (Status))
+    {
+        return;
+    }
+
+    /* Subtables */
+
+    Subtable = ACPI_ADD_PTR (ACPI_HEST_HEADER, Table, Offset);
+    while (Offset < Table->Length)
+    {
+        BankCount = 0;
+        switch (Subtable->Type)
+        {
+        case ACPI_HEST_TYPE_IA32_CHECK:
+
+            InfoTable = AcpiDmTableInfoHest0;
+            SubtableLength = sizeof (ACPI_HEST_IA_MACHINE_CHECK);
+            BankCount = (ACPI_CAST_PTR (ACPI_HEST_IA_MACHINE_CHECK,
+                Subtable))->NumHardwareBanks;
+            break;
+
+        case ACPI_HEST_TYPE_IA32_CORRECTED_CHECK:
+
+            InfoTable = AcpiDmTableInfoHest1;
+            SubtableLength = sizeof (ACPI_HEST_IA_CORRECTED);
+            BankCount = (ACPI_CAST_PTR (ACPI_HEST_IA_CORRECTED,
+                Subtable))->NumHardwareBanks;
+            break;
+
+        case ACPI_HEST_TYPE_IA32_NMI:
+
+            InfoTable = AcpiDmTableInfoHest2;
+            SubtableLength = sizeof (ACPI_HEST_IA_NMI);
+            break;
+
+        case ACPI_HEST_TYPE_AER_ROOT_PORT:
+
+            InfoTable = AcpiDmTableInfoHest6;
+            SubtableLength = sizeof (ACPI_HEST_AER_ROOT);
+            break;
+
+        case ACPI_HEST_TYPE_AER_ENDPOINT:
+
+            InfoTable = AcpiDmTableInfoHest7;
+            SubtableLength = sizeof (ACPI_HEST_AER);
+            break;
+
+        case ACPI_HEST_TYPE_AER_BRIDGE:
+
+            InfoTable = AcpiDmTableInfoHest8;
+            SubtableLength = sizeof (ACPI_HEST_AER_BRIDGE);
+            break;
+
+        case ACPI_HEST_TYPE_GENERIC_ERROR:
+
+            InfoTable = AcpiDmTableInfoHest9;
+            SubtableLength = sizeof (ACPI_HEST_GENERIC);
+            break;
+
+        case ACPI_HEST_TYPE_GENERIC_ERROR_V2:
+
+            InfoTable = AcpiDmTableInfoHest10;
+            SubtableLength = sizeof (ACPI_HEST_GENERIC_V2);
+            break;
+
+        case ACPI_HEST_TYPE_IA32_DEFERRED_CHECK:
+
+            InfoTable = AcpiDmTableInfoHest11;
+            SubtableLength = sizeof (ACPI_HEST_IA_DEFERRED_CHECK);
+            BankCount = (ACPI_CAST_PTR (ACPI_HEST_IA_DEFERRED_CHECK,
+                Subtable))->NumHardwareBanks;
+            break;
+
+        default:
+
+            /* Cannot continue on unknown type - no length */
+
+            AcpiOsPrintf ("\n**** Unknown HEST subtable type 0x%X\n",
+                Subtable->Type);
+            return;
+        }
+
+        AcpiOsPrintf ("\n");
+        Status = AcpiDmDumpTable (Length, Offset, Subtable,
+            SubtableLength, InfoTable);
+        if (ACPI_FAILURE (Status))
+        {
+            return;
+        }
+
+        /* Point to end of current subtable (each subtable above is of fixed length) */
+
+        Offset += SubtableLength;
+
+        /* If there are any (fixed-length) Error Banks from above, dump them now */
+
+        if (BankCount)
+        {
+            BankTable = ACPI_ADD_PTR (ACPI_HEST_IA_ERROR_BANK, Subtable,
+                SubtableLength);
+            SubtableLength += BankCount * sizeof (ACPI_HEST_IA_ERROR_BANK);
+
+            while (BankCount)
+            {
+                AcpiOsPrintf ("\n");
+                Status = AcpiDmDumpTable (Length, Offset, BankTable,
+                    sizeof (ACPI_HEST_IA_ERROR_BANK), AcpiDmTableInfoHestBank);
+                if (ACPI_FAILURE (Status))
+                {
+                    return;
+                }
+
+                Offset += sizeof (ACPI_HEST_IA_ERROR_BANK);
+                BankTable++;
+                BankCount--;
+            }
+        }
+
+        /* Point to next subtable */
+
+        Subtable = ACPI_ADD_PTR (ACPI_HEST_HEADER, Subtable, SubtableLength);
+    }
+}
+
+
+/*******************************************************************************
+ *
+ * FUNCTION:    AcpiDmDumpHmat
+ *
+ * PARAMETERS:  Table               - A HMAT table
+ *
+ * RETURN:      None
+ *
+ * DESCRIPTION: Format the contents of a HMAT.
+ *
+ ******************************************************************************/
+
+void
+AcpiDmDumpHmat (
+    ACPI_TABLE_HEADER       *Table)
+{
+    ACPI_STATUS             Status;
+    ACPI_HMAT_STRUCTURE     *HmatStruct;
+    ACPI_HMAT_LOCALITY      *HmatLocality;
+    ACPI_HMAT_CACHE         *HmatCache;
+    UINT32                  Offset;
+    UINT32                  SubtableOffset;
+    UINT32                  Length;
+    ACPI_DMTABLE_INFO       *InfoTable;
+    UINT32                  i, j;
+
+
+    /* Main table */
+
+    Status = AcpiDmDumpTable (Table->Length, 0, Table, 0, AcpiDmTableInfoHmat);
+    if (ACPI_FAILURE (Status))
+    {
+        return;
+    }
+    Offset = sizeof (ACPI_TABLE_HMAT);
+
+    while (Offset < Table->Length)
+    {
+        AcpiOsPrintf ("\n");
+        SubtableOffset = 0;
+
+        /* Dump HMAT structure header */
+
+        HmatStruct = ACPI_ADD_PTR (ACPI_HMAT_STRUCTURE, Table, Offset);
+        if (HmatStruct->Length < sizeof (ACPI_HMAT_STRUCTURE))
+        {
+            AcpiOsPrintf ("Invalid HMAT structure length\n");
+            return;
+        }
+        Status = AcpiDmDumpTable (Table->Length, Offset, HmatStruct,
+            HmatStruct->Length, AcpiDmTableInfoHmatHdr);
+        if (ACPI_FAILURE (Status))
+        {
+            return;
+        }
+
+        switch (HmatStruct->Type)
+        {
+        case ACPI_HMAT_TYPE_ADDRESS_RANGE:
+
+            InfoTable = AcpiDmTableInfoHmat0;
+            Length = sizeof (ACPI_HMAT_ADDRESS_RANGE);
+            break;
+
+        case ACPI_HMAT_TYPE_LOCALITY:
+
+            InfoTable = AcpiDmTableInfoHmat1;
+            Length = sizeof (ACPI_HMAT_LOCALITY);
+            break;
+
+        case ACPI_HMAT_TYPE_CACHE:
+
+            InfoTable = AcpiDmTableInfoHmat2;
+            Length = sizeof (ACPI_HMAT_CACHE);
+            break;
+
+        default:
+
+            AcpiOsPrintf ("\n**** Unknown HMAT structure type 0x%X\n",
+                HmatStruct->Type);
+
+            /* Attempt to continue */
+
+            goto NextSubtable;
+        }
+
+        /* Dump HMAT structure body */
+
+        if (HmatStruct->Length < Length)
+        {
+            AcpiOsPrintf ("Invalid HMAT structure length\n");
+            return;
+        }
+        Status = AcpiDmDumpTable (Table->Length, Offset, HmatStruct,
+            HmatStruct->Length, InfoTable);
+        if (ACPI_FAILURE (Status))
+        {
+            return;
+        }
+
+        /* Dump HMAT structure additionals */
+
+        switch (HmatStruct->Type)
+        {
+        case ACPI_HMAT_TYPE_LOCALITY:
+
+            HmatLocality = ACPI_CAST_PTR (ACPI_HMAT_LOCALITY, HmatStruct);
+            SubtableOffset = sizeof (ACPI_HMAT_LOCALITY);
+
+            /* Dump initiator proximity domains */
+
+            if ((UINT32)(HmatStruct->Length - SubtableOffset) <
+                (UINT32)(HmatLocality->NumberOfInitiatorPDs * 4))
+            {
+                AcpiOsPrintf ("Invalid initiator proximity domain number\n");
+                return;
+            }
+            for (i = 0; i < HmatLocality->NumberOfInitiatorPDs; i++)
+            {
+                Status = AcpiDmDumpTable (Table->Length, Offset + SubtableOffset,
+                    ACPI_ADD_PTR (ACPI_HMAT_STRUCTURE, HmatStruct, SubtableOffset),
+                    4, AcpiDmTableInfoHmat1a);
+                SubtableOffset += 4;
+            }
+
+            /* Dump target proximity domains */
+
+            if ((UINT32)(HmatStruct->Length - SubtableOffset) <
+                (UINT32)(HmatLocality->NumberOfTargetPDs * 4))
+            {
+                AcpiOsPrintf ("Invalid target proximity domain number\n");
+                return;
+            }
+            for (i = 0; i < HmatLocality->NumberOfTargetPDs; i++)
+            {
+                Status = AcpiDmDumpTable (Table->Length, Offset + SubtableOffset,
+                    ACPI_ADD_PTR (ACPI_HMAT_STRUCTURE, HmatStruct, SubtableOffset),
+                    4, AcpiDmTableInfoHmat1b);
+                SubtableOffset += 4;
+            }
+
+            /* Dump latency/bandwidth entris */
+
+            if ((UINT32)(HmatStruct->Length - SubtableOffset) <
+                (UINT32)(HmatLocality->NumberOfInitiatorPDs *
+                         HmatLocality->NumberOfTargetPDs * 2))
+            {
+                AcpiOsPrintf ("Invalid latency/bandwidth entry number\n");
+                return;
+            }
+            for (i = 0; i < HmatLocality->NumberOfInitiatorPDs; i++)
+            {
+                for (j = 0; j < HmatLocality->NumberOfTargetPDs; j++)
+                {
+                    Status = AcpiDmDumpTable (Table->Length, Offset + SubtableOffset,
+                        ACPI_ADD_PTR (ACPI_HMAT_STRUCTURE, HmatStruct, SubtableOffset),
+                        2, AcpiDmTableInfoHmat1c);
+                    SubtableOffset += 2;
+                }
+            }
+            break;
+
+        case ACPI_HMAT_TYPE_CACHE:
+
+            HmatCache = ACPI_CAST_PTR (ACPI_HMAT_CACHE, HmatStruct);
+            SubtableOffset = sizeof (ACPI_HMAT_CACHE);
+
+            /* Dump SMBIOS handles */
+
+            if ((UINT32)(HmatStruct->Length - SubtableOffset) <
+                (UINT32)(HmatCache->NumberOfSMBIOSHandles * 2))
+            {
+                AcpiOsPrintf ("Invalid SMBIOS handle number\n");
+                return;
+            }
+            for (i = 0; i < HmatCache->NumberOfSMBIOSHandles; i++)
+            {
+                Status = AcpiDmDumpTable (Table->Length, Offset + SubtableOffset,
+                    ACPI_ADD_PTR (ACPI_HMAT_STRUCTURE, HmatStruct, SubtableOffset),
+                    2, AcpiDmTableInfoHmat2a);
+                SubtableOffset += 2;
+            }
+            break;
+
+        default:
+
+            break;
+        }
+
+NextSubtable:
+        /* Point to next HMAT structure subtable */
+
+        Offset += (HmatStruct->Length);
+    }
+}
diff --git a/sys/contrib/dev/acpica/source/common/dmtbdump2.c b/sys/contrib/dev/acpica/source/common/dmtbdump2.c
new file mode 100644 (file)
index 0000000..d2c584b
--- /dev/null
@@ -0,0 +1,2074 @@
+/******************************************************************************
+ *
+ * Module Name: dmtbdump2 - Dump ACPI data tables that contain no AML code
+ *
+ *****************************************************************************/
+
+/******************************************************************************
+ *
+ * 1. Copyright Notice
+ *
+ * Some or all of this work - Copyright (c) 1999 - 2018, Intel Corp.
+ * All rights reserved.
+ *
+ * 2. License
+ *
+ * 2.1. This is your license from Intel Corp. under its intellectual property
+ * rights. You may have additional license terms from the party that provided
+ * you this software, covering your right to use that party's intellectual
+ * property rights.
+ *
+ * 2.2. Intel grants, free of charge, to any person ("Licensee") obtaining a
+ * copy of the source code appearing in this file ("Covered Code") an
+ * irrevocable, perpetual, worldwide license under Intel's copyrights in the
+ * base code distributed originally by Intel ("Original Intel Code") to copy,
+ * make derivatives, distribute, use and display any portion of the Covered
+ * Code in any form, with the right to sublicense such rights; and
+ *
+ * 2.3. Intel grants Licensee a non-exclusive and non-transferable patent
+ * license (with the right to sublicense), under only those claims of Intel
+ * patents that are infringed by the Original Intel Code, to make, use, sell,
+ * offer to sell, and import the Covered Code and derivative works thereof
+ * solely to the minimum extent necessary to exercise the above copyright
+ * license, and in no event shall the patent license extend to any additions
+ * to or modifications of the Original Intel Code. No other license or right
+ * is granted directly or by implication, estoppel or otherwise;
+ *
+ * The above copyright and patent license is granted only if the following
+ * conditions are met:
+ *
+ * 3. Conditions
+ *
+ * 3.1. Redistribution of Source with Rights to Further Distribute Source.
+ * Redistribution of source code of any substantial portion of the Covered
+ * Code or modification with rights to further distribute source must include
+ * the above Copyright Notice, the above License, this list of Conditions,
+ * and the following Disclaimer and Export Compliance provision. In addition,
+ * Licensee must cause all Covered Code to which Licensee contributes to
+ * contain a file documenting the changes Licensee made to create that Covered
+ * Code and the date of any change. Licensee must include in that file the
+ * documentation of any changes made by any predecessor Licensee. Licensee
+ * must include a prominent statement that the modification is derived,
+ * directly or indirectly, from Original Intel Code.
+ *
+ * 3.2. Redistribution of Source with no Rights to Further Distribute Source.
+ * Redistribution of source code of any substantial portion of the Covered
+ * Code or modification without rights to further distribute source must
+ * include the following Disclaimer and Export Compliance provision in the
+ * documentation and/or other materials provided with distribution. In
+ * addition, Licensee may not authorize further sublicense of source of any
+ * portion of the Covered Code, and must include terms to the effect that the
+ * license from Licensee to its licensee is limited to the intellectual
+ * property embodied in the software Licensee provides to its licensee, and
+ * not to intellectual property embodied in modifications its licensee may
+ * make.
+ *
+ * 3.3. Redistribution of Executable. Redistribution in executable form of any
+ * substantial portion of the Covered Code or modification must reproduce the
+ * above Copyright Notice, and the following Disclaimer and Export Compliance
+ * provision in the documentation and/or other materials provided with the
+ * distribution.
+ *
+ * 3.4. Intel retains all right, title, and interest in and to the Original
+ * Intel Code.
+ *
+ * 3.5. Neither the name Intel nor any other trademark owned or controlled by
+ * Intel shall be used in advertising or otherwise to promote the sale, use or
+ * other dealings in products derived from or relating to the Covered Code
+ * without prior written authorization from Intel.
+ *
+ * 4. Disclaimer and Export Compliance
+ *
+ * 4.1. INTEL MAKES NO WARRANTY OF ANY KIND REGARDING ANY SOFTWARE PROVIDED
+ * HERE. ANY SOFTWARE ORIGINATING FROM INTEL OR DERIVED FROM INTEL SOFTWARE
+ * IS PROVIDED "AS IS," AND INTEL WILL NOT PROVIDE ANY SUPPORT, ASSISTANCE,
+ * INSTALLATION, TRAINING OR OTHER SERVICES. INTEL WILL NOT PROVIDE ANY
+ * UPDATES, ENHANCEMENTS OR EXTENSIONS. INTEL SPECIFICALLY DISCLAIMS ANY
+ * IMPLIED WARRANTIES OF MERCHANTABILITY, NONINFRINGEMENT AND FITNESS FOR A
+ * PARTICULAR PURPOSE.
+ *
+ * 4.2. IN NO EVENT SHALL INTEL HAVE ANY LIABILITY TO LICENSEE, ITS LICENSEES
+ * OR ANY OTHER THIRD PARTY, FOR ANY LOST PROFITS, LOST DATA, LOSS OF USE OR
+ * COSTS OF PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES, OR FOR ANY INDIRECT,
+ * SPECIAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THIS AGREEMENT, UNDER ANY
+ * CAUSE OF ACTION OR THEORY OF LIABILITY, AND IRRESPECTIVE OF WHETHER INTEL
+ * HAS ADVANCE NOTICE OF THE POSSIBILITY OF SUCH DAMAGES. THESE LIMITATIONS
+ * SHALL APPLY NOTWITHSTANDING THE FAILURE OF THE ESSENTIAL PURPOSE OF ANY
+ * LIMITED REMEDY.
+ *
+ * 4.3. Licensee shall not export, either directly or indirectly, any of this
+ * software or system incorporating such software without first obtaining any
+ * required license or other approval from the U. S. Department of Commerce or
+ * any other agency or department of the United States Government. In the
+ * event Licensee exports any such software from the United States or
+ * re-exports any such software from a foreign destination, Licensee shall
+ * ensure that the distribution and export/re-export of the software is in
+ * compliance with all laws, regulations, orders, or other restrictions of the
+ * U.S. Export Administration Regulations. Licensee agrees that neither it nor
+ * any of its subsidiaries will export/re-export any technical data, process,
+ * software, or service, directly or indirectly, to any country for which the
+ * United States government or any agency thereof requires an export license,
+ * other governmental approval, or letter of assurance, without first obtaining
+ * such license, approval or letter.
+ *
+ *****************************************************************************
+ *
+ * Alternatively, you may choose to be licensed under the terms of the
+ * following license:
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions, and the following disclaimer,
+ *    without modification.
+ * 2. Redistributions in binary form must reproduce at minimum a disclaimer
+ *    substantially similar to the "NO WARRANTY" disclaimer below
+ *    ("Disclaimer") and any redistribution must be conditioned upon
+ *    including a substantially similar Disclaimer requirement for further
+ *    binary redistribution.
+ * 3. Neither the names of the above-listed copyright holders nor the names
+ *    of any contributors may be used to endorse or promote products derived
+ *    from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ *
+ * Alternatively, you may choose to be licensed under the terms of the
+ * GNU General Public License ("GPL") version 2 as published by the Free
+ * Software Foundation.
+ *
+ *****************************************************************************/
+
+#include "acpi.h"
+#include "accommon.h"
+#include "acdisasm.h"
+#include "actables.h"
+
+/* This module used for application-level code only */
+
+#define _COMPONENT          ACPI_CA_DISASSEMBLER
+        ACPI_MODULE_NAME    ("dmtbdump2")
+
+
+/*******************************************************************************
+ *
+ * FUNCTION:    AcpiDmDumpIort
+ *
+ * PARAMETERS:  Table               - A IORT table
+ *
+ * RETURN:      None
+ *
+ * DESCRIPTION: Format the contents of a IORT
+ *
+ ******************************************************************************/
+
+void
+AcpiDmDumpIort (
+    ACPI_TABLE_HEADER       *Table)
+{
+    ACPI_STATUS             Status;
+    ACPI_TABLE_IORT         *Iort;
+    ACPI_IORT_NODE          *IortNode;
+    ACPI_IORT_ITS_GROUP     *IortItsGroup = NULL;
+    ACPI_IORT_SMMU          *IortSmmu = NULL;
+    UINT32                  Offset;
+    UINT32                  NodeOffset;
+    UINT32                  Length;
+    ACPI_DMTABLE_INFO       *InfoTable;
+    char                    *String;
+    UINT32                  i;
+
+
+    /* Main table */
+
+    Status = AcpiDmDumpTable (Table->Length, 0, Table, 0, AcpiDmTableInfoIort);
+    if (ACPI_FAILURE (Status))
+    {
+        return;
+    }
+
+    Iort = ACPI_CAST_PTR (ACPI_TABLE_IORT, Table);
+    Offset = sizeof (ACPI_TABLE_IORT);
+
+    /* Dump the OptionalPadding (optional) */
+
+    if (Iort->NodeOffset > Offset)
+    {
+        Status = AcpiDmDumpTable (Table->Length, Offset, Table,
+            Iort->NodeOffset - Offset, AcpiDmTableInfoIortPad);
+        if (ACPI_FAILURE (Status))
+        {
+            return;
+        }
+    }
+
+    Offset = Iort->NodeOffset;
+    while (Offset < Table->Length)
+    {
+        /* Common subtable header */
+
+        IortNode = ACPI_ADD_PTR (ACPI_IORT_NODE, Table, Offset);
+        AcpiOsPrintf ("\n");
+        Length = ACPI_OFFSET (ACPI_IORT_NODE, NodeData);
+        Status = AcpiDmDumpTable (Table->Length, Offset,
+            IortNode, Length, AcpiDmTableInfoIortHdr);
+        if (ACPI_FAILURE (Status))
+        {
+            return;
+        }
+
+        NodeOffset = Length;
+
+        switch (IortNode->Type)
+        {
+        case ACPI_IORT_NODE_ITS_GROUP:
+
+            InfoTable = AcpiDmTableInfoIort0;
+            Length = ACPI_OFFSET (ACPI_IORT_ITS_GROUP, Identifiers);
+            IortItsGroup = ACPI_ADD_PTR (ACPI_IORT_ITS_GROUP, IortNode, NodeOffset);
+            break;
+
+        case ACPI_IORT_NODE_NAMED_COMPONENT:
+
+            InfoTable = AcpiDmTableInfoIort1;
+            Length = ACPI_OFFSET (ACPI_IORT_NAMED_COMPONENT, DeviceName);
+            String = ACPI_ADD_PTR (char, IortNode, NodeOffset + Length);
+            Length += strlen (String) + 1;
+            break;
+
+        case ACPI_IORT_NODE_PCI_ROOT_COMPLEX:
+
+            InfoTable = AcpiDmTableInfoIort2;
+            Length = IortNode->Length - NodeOffset;
+            break;
+
+        case ACPI_IORT_NODE_SMMU:
+
+            InfoTable = AcpiDmTableInfoIort3;
+            Length = ACPI_OFFSET (ACPI_IORT_SMMU, Interrupts);
+            IortSmmu = ACPI_ADD_PTR (ACPI_IORT_SMMU, IortNode, NodeOffset);
+            break;
+
+        case ACPI_IORT_NODE_SMMU_V3:
+
+            InfoTable = AcpiDmTableInfoIort4;
+            Length = IortNode->Length - NodeOffset;
+            break;
+
+        default:
+
+            AcpiOsPrintf ("\n**** Unknown IORT node type 0x%X\n",
+                IortNode->Type);
+
+            /* Attempt to continue */
+
+            if (!IortNode->Length)
+            {
+                AcpiOsPrintf ("Invalid zero length IORT node\n");
+                return;
+            }
+            goto NextSubtable;
+        }
+
+        /* Dump the node subtable header */
+
+        AcpiOsPrintf ("\n");
+        Status = AcpiDmDumpTable (Table->Length, Offset + NodeOffset,
+            ACPI_ADD_PTR (ACPI_IORT_NODE, IortNode, NodeOffset),
+            Length, InfoTable);
+        if (ACPI_FAILURE (Status))
+        {
+            return;
+        }
+
+        NodeOffset += Length;
+
+        /* Dump the node specific data */
+
+        switch (IortNode->Type)
+        {
+        case ACPI_IORT_NODE_ITS_GROUP:
+
+            /* Validate IortItsGroup to avoid compiler warnings */
+
+            if (IortItsGroup)
+            {
+                for (i = 0; i < IortItsGroup->ItsCount; i++)
+                {
+                    Status = AcpiDmDumpTable (Table->Length, Offset + NodeOffset,
+                        ACPI_ADD_PTR (ACPI_IORT_NODE, IortNode, NodeOffset),
+                        4, AcpiDmTableInfoIort0a);
+                    NodeOffset += 4;
+                }
+            }
+            break;
+
+        case ACPI_IORT_NODE_NAMED_COMPONENT:
+
+            /* Dump the Padding (optional) */
+
+            if (IortNode->Length > NodeOffset)
+            {
+                Status = AcpiDmDumpTable (Table->Length, Offset + NodeOffset,
+                    Table, IortNode->Length - NodeOffset,
+                    AcpiDmTableInfoIort1a);
+                if (ACPI_FAILURE (Status))
+                {
+               &nb