dbdisply.c revision 123315
1/******************************************************************************* 2 * 3 * Module Name: dbdisply - debug display commands 4 * $Revision: 98 $ 5 * 6 ******************************************************************************/ 7 8/****************************************************************************** 9 * 10 * 1. Copyright Notice 11 * 12 * Some or all of this work - Copyright (c) 1999 - 2003, Intel Corp. 13 * All rights reserved. 14 * 15 * 2. License 16 * 17 * 2.1. This is your license from Intel Corp. under its intellectual property 18 * rights. You may have additional license terms from the party that provided 19 * you this software, covering your right to use that party's intellectual 20 * property rights. 21 * 22 * 2.2. Intel grants, free of charge, to any person ("Licensee") obtaining a 23 * copy of the source code appearing in this file ("Covered Code") an 24 * irrevocable, perpetual, worldwide license under Intel's copyrights in the 25 * base code distributed originally by Intel ("Original Intel Code") to copy, 26 * make derivatives, distribute, use and display any portion of the Covered 27 * Code in any form, with the right to sublicense such rights; and 28 * 29 * 2.3. Intel grants Licensee a non-exclusive and non-transferable patent 30 * license (with the right to sublicense), under only those claims of Intel 31 * patents that are infringed by the Original Intel Code, to make, use, sell, 32 * offer to sell, and import the Covered Code and derivative works thereof 33 * solely to the minimum extent necessary to exercise the above copyright 34 * license, and in no event shall the patent license extend to any additions 35 * to or modifications of the Original Intel Code. No other license or right 36 * is granted directly or by implication, estoppel or otherwise; 37 * 38 * The above copyright and patent license is granted only if the following 39 * conditions are met: 40 * 41 * 3. Conditions 42 * 43 * 3.1. Redistribution of Source with Rights to Further Distribute Source. 44 * Redistribution of source code of any substantial portion of the Covered 45 * Code or modification with rights to further distribute source must include 46 * the above Copyright Notice, the above License, this list of Conditions, 47 * and the following Disclaimer and Export Compliance provision. In addition, 48 * Licensee must cause all Covered Code to which Licensee contributes to 49 * contain a file documenting the changes Licensee made to create that Covered 50 * Code and the date of any change. Licensee must include in that file the 51 * documentation of any changes made by any predecessor Licensee. Licensee 52 * must include a prominent statement that the modification is derived, 53 * directly or indirectly, from Original Intel Code. 54 * 55 * 3.2. Redistribution of Source with no Rights to Further Distribute Source. 56 * Redistribution of source code of any substantial portion of the Covered 57 * Code or modification without rights to further distribute source must 58 * include the following Disclaimer and Export Compliance provision in the 59 * documentation and/or other materials provided with distribution. In 60 * addition, Licensee may not authorize further sublicense of source of any 61 * portion of the Covered Code, and must include terms to the effect that the 62 * license from Licensee to its licensee is limited to the intellectual 63 * property embodied in the software Licensee provides to its licensee, and 64 * not to intellectual property embodied in modifications its licensee may 65 * make. 66 * 67 * 3.3. Redistribution of Executable. Redistribution in executable form of any 68 * substantial portion of the Covered Code or modification must reproduce the 69 * above Copyright Notice, and the following Disclaimer and Export Compliance 70 * provision in the documentation and/or other materials provided with the 71 * distribution. 72 * 73 * 3.4. Intel retains all right, title, and interest in and to the Original 74 * Intel Code. 75 * 76 * 3.5. Neither the name Intel nor any other trademark owned or controlled by 77 * Intel shall be used in advertising or otherwise to promote the sale, use or 78 * other dealings in products derived from or relating to the Covered Code 79 * without prior written authorization from Intel. 80 * 81 * 4. Disclaimer and Export Compliance 82 * 83 * 4.1. INTEL MAKES NO WARRANTY OF ANY KIND REGARDING ANY SOFTWARE PROVIDED 84 * HERE. ANY SOFTWARE ORIGINATING FROM INTEL OR DERIVED FROM INTEL SOFTWARE 85 * IS PROVIDED "AS IS," AND INTEL WILL NOT PROVIDE ANY SUPPORT, ASSISTANCE, 86 * INSTALLATION, TRAINING OR OTHER SERVICES. INTEL WILL NOT PROVIDE ANY 87 * UPDATES, ENHANCEMENTS OR EXTENSIONS. INTEL SPECIFICALLY DISCLAIMS ANY 88 * IMPLIED WARRANTIES OF MERCHANTABILITY, NONINFRINGEMENT AND FITNESS FOR A 89 * PARTICULAR PURPOSE. 90 * 91 * 4.2. IN NO EVENT SHALL INTEL HAVE ANY LIABILITY TO LICENSEE, ITS LICENSEES 92 * OR ANY OTHER THIRD PARTY, FOR ANY LOST PROFITS, LOST DATA, LOSS OF USE OR 93 * COSTS OF PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES, OR FOR ANY INDIRECT, 94 * SPECIAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THIS AGREEMENT, UNDER ANY 95 * CAUSE OF ACTION OR THEORY OF LIABILITY, AND IRRESPECTIVE OF WHETHER INTEL 96 * HAS ADVANCE NOTICE OF THE POSSIBILITY OF SUCH DAMAGES. THESE LIMITATIONS 97 * SHALL APPLY NOTWITHSTANDING THE FAILURE OF THE ESSENTIAL PURPOSE OF ANY 98 * LIMITED REMEDY. 99 * 100 * 4.3. Licensee shall not export, either directly or indirectly, any of this 101 * software or system incorporating such software without first obtaining any 102 * required license or other approval from the U. S. Department of Commerce or 103 * any other agency or department of the United States Government. In the 104 * event Licensee exports any such software from the United States or 105 * re-exports any such software from a foreign destination, Licensee shall 106 * ensure that the distribution and export/re-export of the software is in 107 * compliance with all laws, regulations, orders, or other restrictions of the 108 * U.S. Export Administration Regulations. Licensee agrees that neither it nor 109 * any of its subsidiaries will export/re-export any technical data, process, 110 * software, or service, directly or indirectly, to any country for which the 111 * United States government or any agency thereof requires an export license, 112 * other governmental approval, or letter of assurance, without first obtaining 113 * such license, approval or letter. 114 * 115 *****************************************************************************/ 116 117 118#include "acpi.h" 119#include "amlcode.h" 120#include "acdispat.h" 121#include "acnamesp.h" 122#include "acparser.h" 123#include "acinterp.h" 124#include "acdebug.h" 125#include "acdisasm.h" 126 127 128#ifdef ACPI_DEBUGGER 129 130 131#define _COMPONENT ACPI_CA_DEBUGGER 132 ACPI_MODULE_NAME ("dbdisply") 133 134 135/****************************************************************************** 136 * 137 * FUNCTION: AcpiDbGetPointer 138 * 139 * PARAMETERS: Target - Pointer to string to be converted 140 * 141 * RETURN: Converted pointer 142 * 143 * DESCRIPTION: Convert an ascii pointer value to a real value 144 * 145 *****************************************************************************/ 146 147void * 148AcpiDbGetPointer ( 149 void *Target) 150{ 151 void *ObjPtr; 152 153 154#if ACPI_MACHINE_WIDTH == 16 155#include <stdio.h> 156 157 /* Have to handle 16-bit pointers of the form segment:offset */ 158 159 if (!sscanf (Target, "%p", &ObjPtr)) 160 { 161 AcpiOsPrintf ("Invalid pointer: %s\n", Target); 162 return (NULL); 163 } 164 165#else 166 167 /* Simple flat pointer */ 168 169 ObjPtr = ACPI_TO_POINTER (ACPI_STRTOUL (Target, NULL, 16)); 170#endif 171 172 return (ObjPtr); 173} 174 175 176/******************************************************************************* 177 * 178 * FUNCTION: AcpiDbDumpParserDescriptor 179 * 180 * PARAMETERS: Op - A parser Op descriptor 181 * 182 * RETURN: None 183 * 184 * DESCRIPTION: Display a formatted parser object 185 * 186 ******************************************************************************/ 187 188void 189AcpiDbDumpParserDescriptor ( 190 ACPI_PARSE_OBJECT *Op) 191{ 192 const ACPI_OPCODE_INFO *Info; 193 194 195 Info = AcpiPsGetOpcodeInfo (Op->Common.AmlOpcode); 196 197 AcpiOsPrintf ("Parser Op Descriptor:\n"); 198 AcpiOsPrintf ("%20.20s : %4.4X\n", "Opcode", Op->Common.AmlOpcode); 199 200 ACPI_DEBUG_ONLY_MEMBERS (AcpiOsPrintf ("%20.20s : %s\n", "Opcode Name", Info->Name)); 201 202 AcpiOsPrintf ("%20.20s : %p\n", "Value/ArgList", Op->Common.Value.Arg); 203 AcpiOsPrintf ("%20.20s : %p\n", "Parent", Op->Common.Parent); 204 AcpiOsPrintf ("%20.20s : %p\n", "NextOp", Op->Common.Next); 205} 206 207 208/******************************************************************************* 209 * 210 * FUNCTION: AcpiDbDecodeAndDisplayObject 211 * 212 * PARAMETERS: Target - String with object to be displayed. Names 213 * and hex pointers are supported. 214 * OutputType - Byte, Word, Dword, or Qword (B|W|D|Q) 215 * 216 * RETURN: None 217 * 218 * DESCRIPTION: Display a formatted ACPI object 219 * 220 ******************************************************************************/ 221 222void 223AcpiDbDecodeAndDisplayObject ( 224 char *Target, 225 char *OutputType) 226{ 227 void *ObjPtr; 228 ACPI_NAMESPACE_NODE *Node; 229 ACPI_OPERAND_OBJECT *ObjDesc; 230 UINT32 Display = DB_BYTE_DISPLAY; 231 char Buffer[80]; 232 ACPI_BUFFER RetBuf; 233 ACPI_STATUS Status; 234 UINT32 Size; 235 236 237 if (!Target) 238 { 239 return; 240 } 241 242 /* Decode the output type */ 243 244 if (OutputType) 245 { 246 ACPI_STRUPR (OutputType); 247 if (OutputType[0] == 'W') 248 { 249 Display = DB_WORD_DISPLAY; 250 } 251 else if (OutputType[0] == 'D') 252 { 253 Display = DB_DWORD_DISPLAY; 254 } 255 else if (OutputType[0] == 'Q') 256 { 257 Display = DB_QWORD_DISPLAY; 258 } 259 } 260 261 RetBuf.Length = sizeof (Buffer); 262 RetBuf.Pointer = Buffer; 263 264 /* Differentiate between a number and a name */ 265 266 if ((Target[0] >= 0x30) && (Target[0] <= 0x39)) 267 { 268 ObjPtr = AcpiDbGetPointer (Target); 269 if (!AcpiOsReadable (ObjPtr, 16)) 270 { 271 AcpiOsPrintf ("Address %p is invalid in this address space\n", ObjPtr); 272 return; 273 } 274 275 /* Decode the object type */ 276 277 switch (ACPI_GET_DESCRIPTOR_TYPE (ObjPtr)) 278 { 279 case ACPI_DESC_TYPE_NAMED: 280 281 /* This is a namespace Node */ 282 283 if (!AcpiOsReadable (ObjPtr, sizeof (ACPI_NAMESPACE_NODE))) 284 { 285 AcpiOsPrintf ("Cannot read entire Named object at address %p\n", ObjPtr); 286 return; 287 } 288 289 Node = ObjPtr; 290 goto DumpNte; 291 292 293 case ACPI_DESC_TYPE_OPERAND: 294 295 /* This is a ACPI OPERAND OBJECT */ 296 297 if (!AcpiOsReadable (ObjPtr, sizeof (ACPI_OPERAND_OBJECT))) 298 { 299 AcpiOsPrintf ("Cannot read entire ACPI object at address %p\n", ObjPtr); 300 return; 301 } 302 303 AcpiUtDumpBuffer (ObjPtr, sizeof (ACPI_OPERAND_OBJECT), Display, ACPI_UINT32_MAX); 304 AcpiExDumpObjectDescriptor (ObjPtr, 1); 305 break; 306 307 308 case ACPI_DESC_TYPE_PARSER: 309 310 /* This is a Parser Op object */ 311 312 if (!AcpiOsReadable (ObjPtr, sizeof (ACPI_PARSE_OBJECT))) 313 { 314 AcpiOsPrintf ("Cannot read entire Parser object at address %p\n", ObjPtr); 315 return; 316 } 317 318 AcpiUtDumpBuffer (ObjPtr, sizeof (ACPI_PARSE_OBJECT), Display, ACPI_UINT32_MAX); 319 AcpiDbDumpParserDescriptor ((ACPI_PARSE_OBJECT *) ObjPtr); 320 break; 321 322 323 default: 324 325 /* Is not a recognizeable object */ 326 327 Size = 16; 328 if (AcpiOsReadable (ObjPtr, 64)) 329 { 330 Size = 64; 331 } 332 333 /* Just dump some memory */ 334 335 AcpiUtDumpBuffer (ObjPtr, Size, Display, ACPI_UINT32_MAX); 336 break; 337 } 338 339 return; 340 } 341 342 /* The parameter is a name string that must be resolved to a Named obj */ 343 344 Node = AcpiDbLocalNsLookup (Target); 345 if (!Node) 346 { 347 return; 348 } 349 350 351DumpNte: 352 /* Now dump the Named obj */ 353 354 Status = AcpiGetName (Node, ACPI_FULL_PATHNAME, &RetBuf); 355 if (ACPI_FAILURE (Status)) 356 { 357 AcpiOsPrintf ("Could not convert name to pathname\n"); 358 } 359 360 else 361 { 362 AcpiOsPrintf ("Object (%p) Pathname: %s\n", Node, (char *) RetBuf.Pointer); 363 } 364 365 if (!AcpiOsReadable (Node, sizeof (ACPI_NAMESPACE_NODE))) 366 { 367 AcpiOsPrintf ("Invalid Named object at address %p\n", Node); 368 return; 369 } 370 371 AcpiUtDumpBuffer ((void *) Node, sizeof (ACPI_NAMESPACE_NODE), Display, ACPI_UINT32_MAX); 372 AcpiExDumpNode (Node, 1); 373 374 ObjDesc = AcpiNsGetAttachedObject (Node); 375 if (ObjDesc) 376 { 377 AcpiOsPrintf ("\nAttached Object (%p):\n", ObjDesc); 378 if (!AcpiOsReadable (ObjDesc, sizeof (ACPI_OPERAND_OBJECT))) 379 { 380 AcpiOsPrintf ("Invalid internal ACPI Object at address %p\n", ObjDesc); 381 return; 382 } 383 384 AcpiUtDumpBuffer ((void *) ObjDesc, sizeof (ACPI_OPERAND_OBJECT), Display, ACPI_UINT32_MAX); 385 AcpiExDumpObjectDescriptor (ObjDesc, 1); 386 } 387} 388 389 390/******************************************************************************* 391 * 392 * FUNCTION: AcpiDbDisplayMethodInfo 393 * 394 * PARAMETERS: StartOp - Root of the control method parse tree 395 * 396 * RETURN: None 397 * 398 * DESCRIPTION: Display information about the current method 399 * 400 ******************************************************************************/ 401 402void 403AcpiDbDisplayMethodInfo ( 404 ACPI_PARSE_OBJECT *StartOp) 405{ 406 ACPI_WALK_STATE *WalkState; 407 ACPI_OPERAND_OBJECT *ObjDesc; 408 ACPI_NAMESPACE_NODE *Node; 409 ACPI_PARSE_OBJECT *RootOp; 410 ACPI_PARSE_OBJECT *Op; 411 const ACPI_OPCODE_INFO *OpInfo; 412 UINT32 NumOps = 0; 413 UINT32 NumOperands = 0; 414 UINT32 NumOperators = 0; 415 UINT32 NumRemainingOps = 0; 416 UINT32 NumRemainingOperands = 0; 417 UINT32 NumRemainingOperators = 0; 418 UINT32 NumArgs; 419 UINT32 Concurrency; 420 BOOLEAN CountRemaining = FALSE; 421 422 423 WalkState = AcpiDsGetCurrentWalkState (AcpiGbl_CurrentWalkList); 424 if (!WalkState) 425 { 426 AcpiOsPrintf ("There is no method currently executing\n"); 427 return; 428 } 429 430 ObjDesc = WalkState->MethodDesc; 431 Node = WalkState->MethodNode; 432 433 NumArgs = ObjDesc->Method.ParamCount; 434 Concurrency = ObjDesc->Method.Concurrency; 435 436 AcpiOsPrintf ("Currently executing control method is [%4.4s]\n", 437 AcpiUtGetNodeName (Node)); 438 AcpiOsPrintf ("%X arguments, max concurrency = %X\n", 439 NumArgs, Concurrency); 440 441 442 RootOp = StartOp; 443 while (RootOp->Common.Parent) 444 { 445 RootOp = RootOp->Common.Parent; 446 } 447 448 Op = RootOp; 449 450 while (Op) 451 { 452 if (Op == StartOp) 453 { 454 CountRemaining = TRUE; 455 } 456 457 NumOps++; 458 if (CountRemaining) 459 { 460 NumRemainingOps++; 461 } 462 463 /* Decode the opcode */ 464 465 OpInfo = AcpiPsGetOpcodeInfo (Op->Common.AmlOpcode); 466 switch (OpInfo->Class) 467 { 468 case AML_CLASS_ARGUMENT: 469 if (CountRemaining) 470 { 471 NumRemainingOperands++; 472 } 473 474 NumOperands++; 475 break; 476 477 case AML_CLASS_UNKNOWN: 478 /* Bad opcode or ASCII character */ 479 480 continue; 481 482 default: 483 if (CountRemaining) 484 { 485 NumRemainingOperators++; 486 } 487 488 NumOperators++; 489 break; 490 } 491 492 Op = AcpiPsGetDepthNext (StartOp, Op); 493 } 494 495 AcpiOsPrintf ("Method contains: %X AML Opcodes - %X Operators, %X Operands\n", 496 NumOps, NumOperators, NumOperands); 497 498 AcpiOsPrintf ("Remaining to execute: %X AML Opcodes - %X Operators, %X Operands\n", 499 NumRemainingOps, NumRemainingOperators, NumRemainingOperands); 500} 501 502 503/******************************************************************************* 504 * 505 * FUNCTION: AcpiDbDisplayLocals 506 * 507 * PARAMETERS: None 508 * 509 * RETURN: None 510 * 511 * DESCRIPTION: Display all locals for the currently running control method 512 * 513 ******************************************************************************/ 514 515void 516AcpiDbDisplayLocals (void) 517{ 518 ACPI_WALK_STATE *WalkState; 519 520 521 WalkState = AcpiDsGetCurrentWalkState (AcpiGbl_CurrentWalkList); 522 if (!WalkState) 523 { 524 AcpiOsPrintf ("There is no method currently executing\n"); 525 return; 526 } 527 528 AcpiDmDisplayLocals (WalkState); 529} 530 531 532/******************************************************************************* 533 * 534 * FUNCTION: AcpiDbDisplayArguments 535 * 536 * PARAMETERS: None 537 * 538 * RETURN: None 539 * 540 * DESCRIPTION: Display all arguments for the currently running control method 541 * 542 ******************************************************************************/ 543 544void 545AcpiDbDisplayArguments (void) 546{ 547 ACPI_WALK_STATE *WalkState; 548 549 550 WalkState = AcpiDsGetCurrentWalkState (AcpiGbl_CurrentWalkList); 551 if (!WalkState) 552 { 553 AcpiOsPrintf ("There is no method currently executing\n"); 554 return; 555 } 556 557 AcpiDmDisplayArguments (WalkState); 558} 559 560 561/******************************************************************************* 562 * 563 * FUNCTION: AcpiDbDisplayResults 564 * 565 * PARAMETERS: None 566 * 567 * RETURN: None 568 * 569 * DESCRIPTION: Display current contents of a method result stack 570 * 571 ******************************************************************************/ 572 573void 574AcpiDbDisplayResults (void) 575{ 576 UINT32 i; 577 ACPI_WALK_STATE *WalkState; 578 ACPI_OPERAND_OBJECT *ObjDesc; 579 UINT32 NumResults = 0; 580 ACPI_NAMESPACE_NODE *Node; 581 582 583 WalkState = AcpiDsGetCurrentWalkState (AcpiGbl_CurrentWalkList); 584 if (!WalkState) 585 { 586 AcpiOsPrintf ("There is no method currently executing\n"); 587 return; 588 } 589 590 ObjDesc = WalkState->MethodDesc; 591 Node = WalkState->MethodNode; 592 593 if (WalkState->Results) 594 { 595 NumResults = WalkState->Results->Results.NumResults; 596 } 597 598 AcpiOsPrintf ("Method [%4.4s] has %X stacked result objects\n", 599 AcpiUtGetNodeName (Node), NumResults); 600 601 for (i = 0; i < NumResults; i++) 602 { 603 ObjDesc = WalkState->Results->Results.ObjDesc[i]; 604 AcpiOsPrintf ("Result%d: ", i); 605 AcpiDmDisplayInternalObject (ObjDesc, WalkState); 606 } 607} 608 609 610/******************************************************************************* 611 * 612 * FUNCTION: AcpiDbDisplayCallingTree 613 * 614 * PARAMETERS: None 615 * 616 * RETURN: None 617 * 618 * DESCRIPTION: Display current calling tree of nested control methods 619 * 620 ******************************************************************************/ 621 622void 623AcpiDbDisplayCallingTree (void) 624{ 625 ACPI_WALK_STATE *WalkState; 626 ACPI_NAMESPACE_NODE *Node; 627 628 629 WalkState = AcpiDsGetCurrentWalkState (AcpiGbl_CurrentWalkList); 630 if (!WalkState) 631 { 632 AcpiOsPrintf ("There is no method currently executing\n"); 633 return; 634 } 635 636 Node = WalkState->MethodNode; 637 AcpiOsPrintf ("Current Control Method Call Tree\n"); 638 639 while (WalkState) 640 { 641 Node = WalkState->MethodNode; 642 643 AcpiOsPrintf (" [%4.4s]\n", AcpiUtGetNodeName (Node)); 644 645 WalkState = WalkState->Next; 646 } 647} 648 649 650/******************************************************************************* 651 * 652 * FUNCTION: AcpiDbDisplayObjectType 653 * 654 * PARAMETERS: ObjectArg - User entered NS node handle 655 * 656 * RETURN: None 657 * 658 * DESCRIPTION: Display type of an arbitrary NS node 659 * 660 ******************************************************************************/ 661 662void 663AcpiDbDisplayObjectType ( 664 char *ObjectArg) 665{ 666 ACPI_HANDLE Handle; 667 ACPI_BUFFER Buffer; 668 ACPI_DEVICE_INFO *Info; 669 ACPI_STATUS Status; 670 ACPI_NATIVE_UINT i; 671 672 673 Handle = ACPI_TO_POINTER (ACPI_STRTOUL (ObjectArg, NULL, 16)); 674 Buffer.Length = ACPI_ALLOCATE_LOCAL_BUFFER; 675 676 Status = AcpiGetObjectInfo (Handle, &Buffer); 677 if (ACPI_SUCCESS (Status)) 678 { 679 Info = Buffer.Pointer; 680 AcpiOsPrintf ("HID: %s, ADR: %8.8X%8.8X, Status %8.8X\n", 681 &Info->HardwareId, 682 ACPI_FORMAT_UINT64 (Info->Address), 683 Info->CurrentStatus); 684 685 if (Info->Valid & ACPI_VALID_CID) 686 { 687 for (i = 0; i < Info->CompatibilityId.Count; i++) 688 { 689 AcpiOsPrintf ("CID #%d: %s\n", i, &Info->CompatibilityId.Id[i]); 690 } 691 } 692 693 ACPI_MEM_FREE (Info); 694 } 695 else 696 { 697 AcpiOsPrintf ("%s\n", AcpiFormatException (Status)); 698 } 699} 700 701 702/******************************************************************************* 703 * 704 * FUNCTION: AcpiDbDisplayResultObject 705 * 706 * PARAMETERS: ObjDesc - Object to be displayed 707 * WalkState - Current walk state 708 * 709 * RETURN: None 710 * 711 * DESCRIPTION: Display the result of an AML opcode 712 * 713 * Note: Curently only displays the result object if we are single stepping. 714 * However, this output may be useful in other contexts and could be enabled 715 * to do so if needed. 716 * 717 ******************************************************************************/ 718 719void 720AcpiDbDisplayResultObject ( 721 ACPI_OPERAND_OBJECT *ObjDesc, 722 ACPI_WALK_STATE *WalkState) 723{ 724 725 /* Only display if single stepping */ 726 727 if (!AcpiGbl_CmSingleStep) 728 { 729 return; 730 } 731 732 AcpiOsPrintf ("ResultObj: "); 733 AcpiDmDisplayInternalObject (ObjDesc, WalkState); 734 AcpiOsPrintf ("\n"); 735} 736 737 738/******************************************************************************* 739 * 740 * FUNCTION: AcpiDbDisplayArgumentObject 741 * 742 * PARAMETERS: ObjDesc - Object to be displayed 743 * WalkState - Current walk state 744 * 745 * RETURN: None 746 * 747 * DESCRIPTION: Display the result of an AML opcode 748 * 749 ******************************************************************************/ 750 751void 752AcpiDbDisplayArgumentObject ( 753 ACPI_OPERAND_OBJECT *ObjDesc, 754 ACPI_WALK_STATE *WalkState) 755{ 756 757 if (!AcpiGbl_CmSingleStep) 758 { 759 return; 760 } 761 762 AcpiOsPrintf ("ArgObj: "); 763 AcpiDmDisplayInternalObject (ObjDesc, WalkState); 764} 765 766 767/******************************************************************************* 768 * 769 * FUNCTION: AcpiDbDisplayGpes 770 * 771 * PARAMETERS: None 772 * 773 * RETURN: None 774 * 775 * DESCRIPTION: Display the current GPE structures 776 * 777 ******************************************************************************/ 778 779void 780AcpiDbDisplayGpes (void) 781{ 782 ACPI_GPE_BLOCK_INFO *GpeBlock; 783 ACPI_GPE_XRUPT_INFO *GpeXruptInfo; 784 UINT32 i = 0; 785 786 787 GpeXruptInfo = AcpiGbl_GpeXruptListHead; 788 while (GpeXruptInfo) 789 { 790 GpeBlock = GpeXruptInfo->GpeBlockListHead; 791 while (GpeBlock) 792 { 793 AcpiOsPrintf ("Block %d - %p\n", i, GpeBlock); 794 AcpiOsPrintf (" Registers: %d\n", GpeBlock->RegisterCount); 795 AcpiOsPrintf (" GPE range: %d to %d\n", GpeBlock->BlockBaseNumber, 796 GpeBlock->BlockBaseNumber + (GpeBlock->RegisterCount * 8) -1); 797 AcpiOsPrintf (" RegisterInfo: %p\n", GpeBlock->RegisterInfo); 798 AcpiOsPrintf (" EventInfo: %p\n", GpeBlock->EventInfo); 799 i++; 800 801 GpeBlock = GpeBlock->Next; 802 } 803 804 GpeXruptInfo = GpeXruptInfo->Next; 805 } 806} 807 808 809#endif /* ACPI_DEBUGGER */ 810 811