1 /*******************************************************************************
3 * Module Name: rsdump - Functions to display the resource structures.
6 ******************************************************************************/
8 /******************************************************************************
12 * Some or all of this work - Copyright (c) 1999 - 2004, Intel Corp.
13 * All rights reserved.
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
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
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;
38 * The above copyright and patent license is granted only if the following
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.
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
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
73 * 3.4. Intel retains all right, title, and interest in and to the Original
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.
81 * 4. Disclaimer and Export Compliance
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
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
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.
115 *****************************************************************************/
123 #define _COMPONENT ACPI_RESOURCES
124 ACPI_MODULE_NAME ("rsdump")
127 #if defined(ACPI_DEBUG_OUTPUT) || defined(ACPI_DEBUGGER)
129 /*******************************************************************************
131 * FUNCTION: AcpiRsDumpIrq
133 * PARAMETERS: Data - pointer to the resource structure to dump.
137 * DESCRIPTION: Prints out the various members of the Data structure type.
139 ******************************************************************************/
143 ACPI_RESOURCE_DATA *Data)
145 ACPI_RESOURCE_IRQ *IrqData = (ACPI_RESOURCE_IRQ *) Data;
149 ACPI_FUNCTION_ENTRY ();
152 AcpiOsPrintf ("IRQ Resource\n");
154 AcpiOsPrintf (" %s Triggered\n",
155 ACPI_LEVEL_SENSITIVE == IrqData->EdgeLevel ? "Level" : "Edge");
157 AcpiOsPrintf (" Active %s\n",
158 ACPI_ACTIVE_LOW == IrqData->ActiveHighLow ? "Low" : "High");
160 AcpiOsPrintf (" %s\n",
161 ACPI_SHARED == IrqData->SharedExclusive ? "Shared" : "Exclusive");
163 AcpiOsPrintf (" %X Interrupts ( ", IrqData->NumberOfInterrupts);
165 for (Index = 0; Index < IrqData->NumberOfInterrupts; Index++)
167 AcpiOsPrintf ("%X ", IrqData->Interrupts[Index]);
170 AcpiOsPrintf (")\n");
175 /*******************************************************************************
177 * FUNCTION: AcpiRsDumpDma
179 * PARAMETERS: Data - pointer to the resource structure to dump.
183 * DESCRIPTION: Prints out the various members of the Data structure type.
185 ******************************************************************************/
189 ACPI_RESOURCE_DATA *Data)
191 ACPI_RESOURCE_DMA *DmaData = (ACPI_RESOURCE_DMA *) Data;
195 ACPI_FUNCTION_ENTRY ();
198 AcpiOsPrintf ("DMA Resource\n");
200 switch (DmaData->Type)
202 case ACPI_COMPATIBILITY:
203 AcpiOsPrintf (" Compatibility mode\n");
207 AcpiOsPrintf (" Type A\n");
211 AcpiOsPrintf (" Type B\n");
215 AcpiOsPrintf (" Type F\n");
219 AcpiOsPrintf (" Invalid DMA type\n");
223 AcpiOsPrintf (" %sBus Master\n",
224 ACPI_BUS_MASTER == DmaData->BusMaster ? "" : "Not a ");
227 switch (DmaData->Transfer)
229 case ACPI_TRANSFER_8:
230 AcpiOsPrintf (" 8-bit only transfer\n");
233 case ACPI_TRANSFER_8_16:
234 AcpiOsPrintf (" 8 and 16-bit transfer\n");
237 case ACPI_TRANSFER_16:
238 AcpiOsPrintf (" 16 bit only transfer\n");
242 AcpiOsPrintf (" Invalid transfer preference\n");
246 AcpiOsPrintf (" Number of Channels: %X ( ", DmaData->NumberOfChannels);
248 for (Index = 0; Index < DmaData->NumberOfChannels; Index++)
250 AcpiOsPrintf ("%X ", DmaData->Channels[Index]);
253 AcpiOsPrintf (")\n");
258 /*******************************************************************************
260 * FUNCTION: AcpiRsDumpStartDependFns
262 * PARAMETERS: Data - pointer to the resource structure to dump.
266 * DESCRIPTION: Prints out the various members of the Data structure type.
268 ******************************************************************************/
271 AcpiRsDumpStartDependFns (
272 ACPI_RESOURCE_DATA *Data)
274 ACPI_RESOURCE_START_DPF *SdfData = (ACPI_RESOURCE_START_DPF *) Data;
277 ACPI_FUNCTION_ENTRY ();
280 AcpiOsPrintf ("Start Dependent Functions Resource\n");
282 switch (SdfData->CompatibilityPriority)
284 case ACPI_GOOD_CONFIGURATION:
285 AcpiOsPrintf (" Good configuration\n");
288 case ACPI_ACCEPTABLE_CONFIGURATION:
289 AcpiOsPrintf (" Acceptable configuration\n");
292 case ACPI_SUB_OPTIMAL_CONFIGURATION:
293 AcpiOsPrintf (" Sub-optimal configuration\n");
297 AcpiOsPrintf (" Invalid compatibility priority\n");
301 switch(SdfData->PerformanceRobustness)
303 case ACPI_GOOD_CONFIGURATION:
304 AcpiOsPrintf (" Good configuration\n");
307 case ACPI_ACCEPTABLE_CONFIGURATION:
308 AcpiOsPrintf (" Acceptable configuration\n");
311 case ACPI_SUB_OPTIMAL_CONFIGURATION:
312 AcpiOsPrintf (" Sub-optimal configuration\n");
316 AcpiOsPrintf (" Invalid performance "
317 "robustness preference\n");
325 /*******************************************************************************
327 * FUNCTION: AcpiRsDumpIo
329 * PARAMETERS: Data - pointer to the resource structure to dump.
333 * DESCRIPTION: Prints out the various members of the Data structure type.
335 ******************************************************************************/
339 ACPI_RESOURCE_DATA *Data)
341 ACPI_RESOURCE_IO *IoData = (ACPI_RESOURCE_IO *) Data;
344 ACPI_FUNCTION_ENTRY ();
347 AcpiOsPrintf ("Io Resource\n");
349 AcpiOsPrintf (" %d bit decode\n",
350 ACPI_DECODE_16 == IoData->IoDecode ? 16 : 10);
352 AcpiOsPrintf (" Range minimum base: %08X\n",
353 IoData->MinBaseAddress);
355 AcpiOsPrintf (" Range maximum base: %08X\n",
356 IoData->MaxBaseAddress);
358 AcpiOsPrintf (" Alignment: %08X\n",
361 AcpiOsPrintf (" Range Length: %08X\n",
362 IoData->RangeLength);
368 /*******************************************************************************
370 * FUNCTION: AcpiRsDumpFixedIo
372 * PARAMETERS: Data - pointer to the resource structure to dump.
376 * DESCRIPTION: Prints out the various members of the Data structure type.
378 ******************************************************************************/
382 ACPI_RESOURCE_DATA *Data)
384 ACPI_RESOURCE_FIXED_IO *FixedIoData = (ACPI_RESOURCE_FIXED_IO *) Data;
387 ACPI_FUNCTION_ENTRY ();
390 AcpiOsPrintf ("Fixed Io Resource\n");
391 AcpiOsPrintf (" Range base address: %08X",
392 FixedIoData->BaseAddress);
394 AcpiOsPrintf (" Range length: %08X",
395 FixedIoData->RangeLength);
401 /*******************************************************************************
403 * FUNCTION: AcpiRsDumpVendorSpecific
405 * PARAMETERS: Data - pointer to the resource structure to dump.
409 * DESCRIPTION: Prints out the various members of the Data structure type.
411 ******************************************************************************/
414 AcpiRsDumpVendorSpecific (
415 ACPI_RESOURCE_DATA *Data)
417 ACPI_RESOURCE_VENDOR *VendorData = (ACPI_RESOURCE_VENDOR *) Data;
421 ACPI_FUNCTION_ENTRY ();
424 AcpiOsPrintf ("Vendor Specific Resource\n");
426 AcpiOsPrintf (" Length: %08X\n", VendorData->Length);
428 for (Index = 0; Index < VendorData->Length; Index++)
430 AcpiOsPrintf (" Byte %X: %08X\n",
431 Index, VendorData->Reserved[Index]);
438 /*******************************************************************************
440 * FUNCTION: AcpiRsDumpMemory24
442 * PARAMETERS: Data - pointer to the resource structure to dump.
446 * DESCRIPTION: Prints out the various members of the Data structure type.
448 ******************************************************************************/
452 ACPI_RESOURCE_DATA *Data)
454 ACPI_RESOURCE_MEM24 *Memory24Data = (ACPI_RESOURCE_MEM24 *) Data;
457 ACPI_FUNCTION_ENTRY ();
460 AcpiOsPrintf ("24-Bit Memory Range Resource\n");
462 AcpiOsPrintf (" Read%s\n",
463 ACPI_READ_WRITE_MEMORY ==
464 Memory24Data->ReadWriteAttribute ?
467 AcpiOsPrintf (" Range minimum base: %08X\n",
468 Memory24Data->MinBaseAddress);
470 AcpiOsPrintf (" Range maximum base: %08X\n",
471 Memory24Data->MaxBaseAddress);
473 AcpiOsPrintf (" Alignment: %08X\n",
474 Memory24Data->Alignment);
476 AcpiOsPrintf (" Range length: %08X\n",
477 Memory24Data->RangeLength);
483 /*******************************************************************************
485 * FUNCTION: AcpiRsDumpMemory32
487 * PARAMETERS: Data - pointer to the resource structure to dump.
491 * DESCRIPTION: Prints out the various members of the Data structure type.
493 ******************************************************************************/
497 ACPI_RESOURCE_DATA *Data)
499 ACPI_RESOURCE_MEM32 *Memory32Data = (ACPI_RESOURCE_MEM32 *) Data;
502 ACPI_FUNCTION_ENTRY ();
505 AcpiOsPrintf ("32-Bit Memory Range Resource\n");
507 AcpiOsPrintf (" Read%s\n",
508 ACPI_READ_WRITE_MEMORY ==
509 Memory32Data->ReadWriteAttribute ?
512 AcpiOsPrintf (" Range minimum base: %08X\n",
513 Memory32Data->MinBaseAddress);
515 AcpiOsPrintf (" Range maximum base: %08X\n",
516 Memory32Data->MaxBaseAddress);
518 AcpiOsPrintf (" Alignment: %08X\n",
519 Memory32Data->Alignment);
521 AcpiOsPrintf (" Range length: %08X\n",
522 Memory32Data->RangeLength);
528 /*******************************************************************************
530 * FUNCTION: AcpiRsDumpFixedMemory32
532 * PARAMETERS: Data - pointer to the resource structure to dump.
536 * DESCRIPTION: Prints out the various members of the Data structure type.
538 ******************************************************************************/
541 AcpiRsDumpFixedMemory32 (
542 ACPI_RESOURCE_DATA *Data)
544 ACPI_RESOURCE_FIXED_MEM32 *FixedMemory32Data = (ACPI_RESOURCE_FIXED_MEM32 *) Data;
547 ACPI_FUNCTION_ENTRY ();
550 AcpiOsPrintf ("32-Bit Fixed Location Memory Range Resource\n");
552 AcpiOsPrintf (" Read%s\n",
553 ACPI_READ_WRITE_MEMORY ==
554 FixedMemory32Data->ReadWriteAttribute ?
557 AcpiOsPrintf (" Range base address: %08X\n",
558 FixedMemory32Data->RangeBaseAddress);
560 AcpiOsPrintf (" Range length: %08X\n",
561 FixedMemory32Data->RangeLength);
567 /*******************************************************************************
569 * FUNCTION: AcpiRsDumpAddress16
571 * PARAMETERS: Data - pointer to the resource structure to dump.
575 * DESCRIPTION: Prints out the various members of the Data structure type.
577 ******************************************************************************/
580 AcpiRsDumpAddress16 (
581 ACPI_RESOURCE_DATA *Data)
583 ACPI_RESOURCE_ADDRESS16 *Address16Data = (ACPI_RESOURCE_ADDRESS16 *) Data;
586 ACPI_FUNCTION_ENTRY ();
589 AcpiOsPrintf ("16-Bit Address Space Resource\n");
590 AcpiOsPrintf (" Resource Type: ");
592 switch (Address16Data->ResourceType)
594 case ACPI_MEMORY_RANGE:
596 AcpiOsPrintf ("Memory Range\n");
598 switch (Address16Data->Attribute.Memory.CacheAttribute)
600 case ACPI_NON_CACHEABLE_MEMORY:
601 AcpiOsPrintf (" Type Specific: "
602 "Noncacheable memory\n");
605 case ACPI_CACHABLE_MEMORY:
606 AcpiOsPrintf (" Type Specific: "
607 "Cacheable memory\n");
610 case ACPI_WRITE_COMBINING_MEMORY:
611 AcpiOsPrintf (" Type Specific: "
612 "Write-combining memory\n");
615 case ACPI_PREFETCHABLE_MEMORY:
616 AcpiOsPrintf (" Type Specific: "
617 "Prefetchable memory\n");
621 AcpiOsPrintf (" Type Specific: "
622 "Invalid cache attribute\n");
626 AcpiOsPrintf (" Type Specific: Read%s\n",
627 ACPI_READ_WRITE_MEMORY ==
628 Address16Data->Attribute.Memory.ReadWriteAttribute ?
634 AcpiOsPrintf ("I/O Range\n");
636 switch (Address16Data->Attribute.Io.RangeAttribute)
638 case ACPI_NON_ISA_ONLY_RANGES:
639 AcpiOsPrintf (" Type Specific: "
640 "Non-ISA Io Addresses\n");
643 case ACPI_ISA_ONLY_RANGES:
644 AcpiOsPrintf (" Type Specific: "
645 "ISA Io Addresses\n");
648 case ACPI_ENTIRE_RANGE:
649 AcpiOsPrintf (" Type Specific: "
650 "ISA and non-ISA Io Addresses\n");
654 AcpiOsPrintf (" Type Specific: "
655 "Invalid range attribute\n");
659 AcpiOsPrintf (" Type Specific: %s Translation\n",
660 ACPI_SPARSE_TRANSLATION ==
661 Address16Data->Attribute.Io.TranslationAttribute ?
665 case ACPI_BUS_NUMBER_RANGE:
667 AcpiOsPrintf ("Bus Number Range\n");
672 AcpiOsPrintf ("Invalid resource type. Exiting.\n");
676 AcpiOsPrintf (" Resource %s\n",
677 ACPI_CONSUMER == Address16Data->ProducerConsumer ?
678 "Consumer" : "Producer");
680 AcpiOsPrintf (" %s decode\n",
681 ACPI_SUB_DECODE == Address16Data->Decode ?
682 "Subtractive" : "Positive");
684 AcpiOsPrintf (" Min address is %s fixed\n",
685 ACPI_ADDRESS_FIXED == Address16Data->MinAddressFixed ?
688 AcpiOsPrintf (" Max address is %s fixed\n",
689 ACPI_ADDRESS_FIXED == Address16Data->MaxAddressFixed ?
692 AcpiOsPrintf (" Granularity: %08X\n",
693 Address16Data->Granularity);
695 AcpiOsPrintf (" Address range min: %08X\n",
696 Address16Data->MinAddressRange);
698 AcpiOsPrintf (" Address range max: %08X\n",
699 Address16Data->MaxAddressRange);
701 AcpiOsPrintf (" Address translation offset: %08X\n",
702 Address16Data->AddressTranslationOffset);
704 AcpiOsPrintf (" Address Length: %08X\n",
705 Address16Data->AddressLength);
707 if (0xFF != Address16Data->ResourceSource.Index)
709 AcpiOsPrintf (" Resource Source Index: %X\n",
710 Address16Data->ResourceSource.Index);
711 AcpiOsPrintf (" Resource Source: %s\n",
712 Address16Data->ResourceSource.StringPtr);
719 /*******************************************************************************
721 * FUNCTION: AcpiRsDumpAddress32
723 * PARAMETERS: Data - pointer to the resource structure to dump.
727 * DESCRIPTION: Prints out the various members of the Data structure type.
729 ******************************************************************************/
732 AcpiRsDumpAddress32 (
733 ACPI_RESOURCE_DATA *Data)
735 ACPI_RESOURCE_ADDRESS32 *Address32Data = (ACPI_RESOURCE_ADDRESS32 *) Data;
738 ACPI_FUNCTION_ENTRY ();
741 AcpiOsPrintf ("32-Bit Address Space Resource\n");
743 switch (Address32Data->ResourceType)
745 case ACPI_MEMORY_RANGE:
747 AcpiOsPrintf (" Resource Type: Memory Range\n");
749 switch (Address32Data->Attribute.Memory.CacheAttribute)
751 case ACPI_NON_CACHEABLE_MEMORY:
752 AcpiOsPrintf (" Type Specific: "
753 "Noncacheable memory\n");
756 case ACPI_CACHABLE_MEMORY:
757 AcpiOsPrintf (" Type Specific: "
758 "Cacheable memory\n");
761 case ACPI_WRITE_COMBINING_MEMORY:
762 AcpiOsPrintf (" Type Specific: "
763 "Write-combining memory\n");
766 case ACPI_PREFETCHABLE_MEMORY:
767 AcpiOsPrintf (" Type Specific: "
768 "Prefetchable memory\n");
772 AcpiOsPrintf (" Type Specific: "
773 "Invalid cache attribute\n");
777 AcpiOsPrintf (" Type Specific: Read%s\n",
778 ACPI_READ_WRITE_MEMORY ==
779 Address32Data->Attribute.Memory.ReadWriteAttribute ?
785 AcpiOsPrintf (" Resource Type: Io Range\n");
787 switch (Address32Data->Attribute.Io.RangeAttribute)
789 case ACPI_NON_ISA_ONLY_RANGES:
790 AcpiOsPrintf (" Type Specific: "
791 "Non-ISA Io Addresses\n");
794 case ACPI_ISA_ONLY_RANGES:
795 AcpiOsPrintf (" Type Specific: "
796 "ISA Io Addresses\n");
799 case ACPI_ENTIRE_RANGE:
800 AcpiOsPrintf (" Type Specific: "
801 "ISA and non-ISA Io Addresses\n");
805 AcpiOsPrintf (" Type Specific: "
806 "Invalid Range attribute");
810 AcpiOsPrintf (" Type Specific: %s Translation\n",
811 ACPI_SPARSE_TRANSLATION ==
812 Address32Data->Attribute.Io.TranslationAttribute ?
816 case ACPI_BUS_NUMBER_RANGE:
818 AcpiOsPrintf (" Resource Type: Bus Number Range\n");
823 AcpiOsPrintf (" Invalid Resource Type..exiting.\n");
827 AcpiOsPrintf (" Resource %s\n",
828 ACPI_CONSUMER == Address32Data->ProducerConsumer ?
829 "Consumer" : "Producer");
831 AcpiOsPrintf (" %s decode\n",
832 ACPI_SUB_DECODE == Address32Data->Decode ?
833 "Subtractive" : "Positive");
835 AcpiOsPrintf (" Min address is %s fixed\n",
836 ACPI_ADDRESS_FIXED == Address32Data->MinAddressFixed ?
839 AcpiOsPrintf (" Max address is %s fixed\n",
840 ACPI_ADDRESS_FIXED == Address32Data->MaxAddressFixed ?
843 AcpiOsPrintf (" Granularity: %08X\n",
844 Address32Data->Granularity);
846 AcpiOsPrintf (" Address range min: %08X\n",
847 Address32Data->MinAddressRange);
849 AcpiOsPrintf (" Address range max: %08X\n",
850 Address32Data->MaxAddressRange);
852 AcpiOsPrintf (" Address translation offset: %08X\n",
853 Address32Data->AddressTranslationOffset);
855 AcpiOsPrintf (" Address Length: %08X\n",
856 Address32Data->AddressLength);
858 if(0xFF != Address32Data->ResourceSource.Index)
860 AcpiOsPrintf (" Resource Source Index: %X\n",
861 Address32Data->ResourceSource.Index);
862 AcpiOsPrintf (" Resource Source: %s\n",
863 Address32Data->ResourceSource.StringPtr);
870 /*******************************************************************************
872 * FUNCTION: AcpiRsDumpAddress64
874 * PARAMETERS: Data - pointer to the resource structure to dump.
878 * DESCRIPTION: Prints out the various members of the Data structure type.
880 ******************************************************************************/
883 AcpiRsDumpAddress64 (
884 ACPI_RESOURCE_DATA *Data)
886 ACPI_RESOURCE_ADDRESS64 *Address64Data = (ACPI_RESOURCE_ADDRESS64 *) Data;
889 ACPI_FUNCTION_ENTRY ();
892 AcpiOsPrintf ("64-Bit Address Space Resource\n");
894 switch (Address64Data->ResourceType)
896 case ACPI_MEMORY_RANGE:
898 AcpiOsPrintf (" Resource Type: Memory Range\n");
900 switch (Address64Data->Attribute.Memory.CacheAttribute)
902 case ACPI_NON_CACHEABLE_MEMORY:
903 AcpiOsPrintf (" Type Specific: "
904 "Noncacheable memory\n");
907 case ACPI_CACHABLE_MEMORY:
908 AcpiOsPrintf (" Type Specific: "
909 "Cacheable memory\n");
912 case ACPI_WRITE_COMBINING_MEMORY:
913 AcpiOsPrintf (" Type Specific: "
914 "Write-combining memory\n");
917 case ACPI_PREFETCHABLE_MEMORY:
918 AcpiOsPrintf (" Type Specific: "
919 "Prefetchable memory\n");
923 AcpiOsPrintf (" Type Specific: "
924 "Invalid cache attribute\n");
928 AcpiOsPrintf (" Type Specific: Read%s\n",
929 ACPI_READ_WRITE_MEMORY ==
930 Address64Data->Attribute.Memory.ReadWriteAttribute ?
936 AcpiOsPrintf (" Resource Type: Io Range\n");
938 switch (Address64Data->Attribute.Io.RangeAttribute)
940 case ACPI_NON_ISA_ONLY_RANGES:
941 AcpiOsPrintf (" Type Specific: "
942 "Non-ISA Io Addresses\n");
945 case ACPI_ISA_ONLY_RANGES:
946 AcpiOsPrintf (" Type Specific: "
947 "ISA Io Addresses\n");
950 case ACPI_ENTIRE_RANGE:
951 AcpiOsPrintf (" Type Specific: "
952 "ISA and non-ISA Io Addresses\n");
956 AcpiOsPrintf (" Type Specific: "
957 "Invalid Range attribute");
961 AcpiOsPrintf (" Type Specific: %s Translation\n",
962 ACPI_SPARSE_TRANSLATION ==
963 Address64Data->Attribute.Io.TranslationAttribute ?
967 case ACPI_BUS_NUMBER_RANGE:
969 AcpiOsPrintf (" Resource Type: Bus Number Range\n");
974 AcpiOsPrintf (" Invalid Resource Type..exiting.\n");
978 AcpiOsPrintf (" Resource %s\n",
979 ACPI_CONSUMER == Address64Data->ProducerConsumer ?
980 "Consumer" : "Producer");
982 AcpiOsPrintf (" %s decode\n",
983 ACPI_SUB_DECODE == Address64Data->Decode ?
984 "Subtractive" : "Positive");
986 AcpiOsPrintf (" Min address is %s fixed\n",
987 ACPI_ADDRESS_FIXED == Address64Data->MinAddressFixed ?
990 AcpiOsPrintf (" Max address is %s fixed\n",
991 ACPI_ADDRESS_FIXED == Address64Data->MaxAddressFixed ?
994 AcpiOsPrintf (" Granularity: %8.8X%8.8X\n",
995 ACPI_FORMAT_UINT64 (Address64Data->Granularity));
997 AcpiOsPrintf (" Address range min: %8.8X%8.8X\n",
998 ACPI_FORMAT_UINT64 (Address64Data->MinAddressRange));
1000 AcpiOsPrintf (" Address range max: %8.8X%8.8X\n",
1001 ACPI_FORMAT_UINT64 (Address64Data->MaxAddressRange));
1003 AcpiOsPrintf (" Address translation offset: %8.8X%8.8X\n",
1004 ACPI_FORMAT_UINT64 (Address64Data->AddressTranslationOffset));
1006 AcpiOsPrintf (" Address Length: %8.8X%8.8X\n",
1007 ACPI_FORMAT_UINT64 (Address64Data->AddressLength));
1009 if(0xFF != Address64Data->ResourceSource.Index)
1011 AcpiOsPrintf (" Resource Source Index: %X\n",
1012 Address64Data->ResourceSource.Index);
1013 AcpiOsPrintf (" Resource Source: %s\n",
1014 Address64Data->ResourceSource.StringPtr);
1021 /*******************************************************************************
1023 * FUNCTION: AcpiRsDumpExtendedIrq
1025 * PARAMETERS: Data - pointer to the resource structure to dump.
1029 * DESCRIPTION: Prints out the various members of the Data structure type.
1031 ******************************************************************************/
1034 AcpiRsDumpExtendedIrq (
1035 ACPI_RESOURCE_DATA *Data)
1037 ACPI_RESOURCE_EXT_IRQ *ExtIrqData = (ACPI_RESOURCE_EXT_IRQ *) Data;
1041 ACPI_FUNCTION_ENTRY ();
1044 AcpiOsPrintf ("Extended IRQ Resource\n");
1046 AcpiOsPrintf (" Resource %s\n",
1047 ACPI_CONSUMER == ExtIrqData->ProducerConsumer ?
1048 "Consumer" : "Producer");
1050 AcpiOsPrintf (" %s\n",
1051 ACPI_LEVEL_SENSITIVE == ExtIrqData->EdgeLevel ?
1054 AcpiOsPrintf (" Active %s\n",
1055 ACPI_ACTIVE_LOW == ExtIrqData->ActiveHighLow ?
1058 AcpiOsPrintf (" %s\n",
1059 ACPI_SHARED == ExtIrqData->SharedExclusive ?
1060 "Shared" : "Exclusive");
1062 AcpiOsPrintf (" Interrupts : %X ( ",
1063 ExtIrqData->NumberOfInterrupts);
1065 for (Index = 0; Index < ExtIrqData->NumberOfInterrupts; Index++)
1067 AcpiOsPrintf ("%X ", ExtIrqData->Interrupts[Index]);
1070 AcpiOsPrintf (")\n");
1072 if(0xFF != ExtIrqData->ResourceSource.Index)
1074 AcpiOsPrintf (" Resource Source Index: %X",
1075 ExtIrqData->ResourceSource.Index);
1076 AcpiOsPrintf (" Resource Source: %s",
1077 ExtIrqData->ResourceSource.StringPtr);
1084 /*******************************************************************************
1086 * FUNCTION: AcpiRsDumpResourceList
1088 * PARAMETERS: Data - pointer to the resource structure to dump.
1092 * DESCRIPTION: Dispatches the structure to the correct dump routine.
1094 ******************************************************************************/
1097 AcpiRsDumpResourceList (
1098 ACPI_RESOURCE *Resource)
1101 BOOLEAN Done = FALSE;
1104 ACPI_FUNCTION_ENTRY ();
1107 if (AcpiDbgLevel & ACPI_LV_RESOURCES && _COMPONENT & AcpiDbgLayer)
1111 AcpiOsPrintf ("Resource structure %X.\n", Count++);
1113 switch (Resource->Id)
1115 case ACPI_RSTYPE_IRQ:
1116 AcpiRsDumpIrq (&Resource->Data);
1119 case ACPI_RSTYPE_DMA:
1120 AcpiRsDumpDma (&Resource->Data);
1123 case ACPI_RSTYPE_START_DPF:
1124 AcpiRsDumpStartDependFns (&Resource->Data);
1127 case ACPI_RSTYPE_END_DPF:
1128 AcpiOsPrintf ("EndDependentFunctions Resource\n");
1129 /* AcpiRsDumpEndDependentFunctions (Resource->Data);*/
1132 case ACPI_RSTYPE_IO:
1133 AcpiRsDumpIo (&Resource->Data);
1136 case ACPI_RSTYPE_FIXED_IO:
1137 AcpiRsDumpFixedIo (&Resource->Data);
1140 case ACPI_RSTYPE_VENDOR:
1141 AcpiRsDumpVendorSpecific (&Resource->Data);
1144 case ACPI_RSTYPE_END_TAG:
1145 /*RsDumpEndTag (Resource->Data);*/
1146 AcpiOsPrintf ("EndTag Resource\n");
1150 case ACPI_RSTYPE_MEM24:
1151 AcpiRsDumpMemory24 (&Resource->Data);
1154 case ACPI_RSTYPE_MEM32:
1155 AcpiRsDumpMemory32 (&Resource->Data);
1158 case ACPI_RSTYPE_FIXED_MEM32:
1159 AcpiRsDumpFixedMemory32 (&Resource->Data);
1162 case ACPI_RSTYPE_ADDRESS16:
1163 AcpiRsDumpAddress16 (&Resource->Data);
1166 case ACPI_RSTYPE_ADDRESS32:
1167 AcpiRsDumpAddress32 (&Resource->Data);
1170 case ACPI_RSTYPE_ADDRESS64:
1171 AcpiRsDumpAddress64 (&Resource->Data);
1174 case ACPI_RSTYPE_EXT_IRQ:
1175 AcpiRsDumpExtendedIrq (&Resource->Data);
1179 AcpiOsPrintf ("Invalid resource type\n");
1184 Resource = ACPI_PTR_ADD (ACPI_RESOURCE, Resource, Resource->Length);
1191 /*******************************************************************************
1193 * FUNCTION: AcpiRsDumpIrqList
1195 * PARAMETERS: Data - pointer to the routing table to dump.
1199 * DESCRIPTION: Dispatches the structures to the correct dump routine.
1201 ******************************************************************************/
1207 UINT8 *Buffer = RouteTable;
1209 BOOLEAN Done = FALSE;
1210 ACPI_PCI_ROUTING_TABLE *PrtElement;
1213 ACPI_FUNCTION_ENTRY ();
1216 if (AcpiDbgLevel & ACPI_LV_RESOURCES && _COMPONENT & AcpiDbgLayer)
1218 PrtElement = ACPI_CAST_PTR (ACPI_PCI_ROUTING_TABLE, Buffer);
1222 AcpiOsPrintf ("PCI IRQ Routing Table structure %X.\n", Count++);
1224 AcpiOsPrintf (" Address: %8.8X%8.8X\n",
1225 ACPI_FORMAT_UINT64 (PrtElement->Address));
1227 AcpiOsPrintf (" Pin: %X\n", PrtElement->Pin);
1229 AcpiOsPrintf (" Source: %s\n", PrtElement->Source);
1231 AcpiOsPrintf (" SourceIndex: %X\n",
1232 PrtElement->SourceIndex);
1234 Buffer += PrtElement->Length;
1236 PrtElement = ACPI_CAST_PTR (ACPI_PCI_ROUTING_TABLE, Buffer);
1238 if(0 == PrtElement->Length)