1 /*******************************************************************************
3 * Module Name: rsdump - Functions to display the resource structures.
5 ******************************************************************************/
8 * Copyright (C) 2000 - 2005, R. Byron Moore
11 * Redistribution and use in source and binary forms, with or without
12 * modification, are permitted provided that the following conditions
14 * 1. Redistributions of source code must retain the above copyright
15 * notice, this list of conditions, and the following disclaimer,
16 * without modification.
17 * 2. Redistributions in binary form must reproduce at minimum a disclaimer
18 * substantially similar to the "NO WARRANTY" disclaimer below
19 * ("Disclaimer") and any redistribution must be conditioned upon
20 * including a substantially similar Disclaimer requirement for further
21 * binary redistribution.
22 * 3. Neither the names of the above-listed copyright holders nor the names
23 * of any contributors may be used to endorse or promote products derived
24 * from this software without specific prior written permission.
26 * Alternatively, this software may be distributed under the terms of the
27 * GNU General Public License ("GPL") version 2 as published by the Free
28 * Software Foundation.
31 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
32 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
33 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR
34 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
35 * HOLDERS OR CONTRIBUTORS BE LIABLE FOR SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
36 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
37 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
38 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
39 * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
40 * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
41 * POSSIBILITY OF SUCH DAMAGES.
45 #include <acpi/acpi.h>
46 #include <acpi/acresrc.h>
48 #define _COMPONENT ACPI_RESOURCES
49 ACPI_MODULE_NAME ("rsdump")
52 #if defined(ACPI_DEBUG_OUTPUT) || defined(ACPI_DEBUGGER)
54 /* Local prototypes */
58 union acpi_resource_data
*data
);
61 acpi_rs_dump_address16 (
62 union acpi_resource_data
*data
);
65 acpi_rs_dump_address32 (
66 union acpi_resource_data
*data
);
69 acpi_rs_dump_address64 (
70 union acpi_resource_data
*data
);
74 union acpi_resource_data
*data
);
78 union acpi_resource_data
*data
);
81 acpi_rs_dump_extended_irq (
82 union acpi_resource_data
*data
);
85 acpi_rs_dump_fixed_io (
86 union acpi_resource_data
*data
);
89 acpi_rs_dump_fixed_memory32 (
90 union acpi_resource_data
*data
);
93 acpi_rs_dump_memory24 (
94 union acpi_resource_data
*data
);
97 acpi_rs_dump_memory32 (
98 union acpi_resource_data
*data
);
101 acpi_rs_dump_start_depend_fns (
102 union acpi_resource_data
*data
);
105 acpi_rs_dump_vendor_specific (
106 union acpi_resource_data
*data
);
109 /*******************************************************************************
111 * FUNCTION: acpi_rs_dump_irq
113 * PARAMETERS: Data - pointer to the resource structure to dump.
117 * DESCRIPTION: Prints out the various members of the Data structure type.
119 ******************************************************************************/
123 union acpi_resource_data
*data
)
125 struct acpi_resource_irq
*irq_data
= (struct acpi_resource_irq
*) data
;
129 ACPI_FUNCTION_ENTRY ();
132 acpi_os_printf ("IRQ Resource\n");
134 acpi_os_printf (" %s Triggered\n",
135 ACPI_LEVEL_SENSITIVE
== irq_data
->edge_level
? "Level" : "Edge");
137 acpi_os_printf (" Active %s\n",
138 ACPI_ACTIVE_LOW
== irq_data
->active_high_low
? "Low" : "High");
140 acpi_os_printf (" %s\n",
141 ACPI_SHARED
== irq_data
->shared_exclusive
? "Shared" : "Exclusive");
143 acpi_os_printf (" %X Interrupts ( ", irq_data
->number_of_interrupts
);
145 for (index
= 0; index
< irq_data
->number_of_interrupts
; index
++) {
146 acpi_os_printf ("%X ", irq_data
->interrupts
[index
]);
149 acpi_os_printf (")\n");
154 /*******************************************************************************
156 * FUNCTION: acpi_rs_dump_dma
158 * PARAMETERS: Data - pointer to the resource structure to dump.
162 * DESCRIPTION: Prints out the various members of the Data structure type.
164 ******************************************************************************/
168 union acpi_resource_data
*data
)
170 struct acpi_resource_dma
*dma_data
= (struct acpi_resource_dma
*) data
;
174 ACPI_FUNCTION_ENTRY ();
177 acpi_os_printf ("DMA Resource\n");
179 switch (dma_data
->type
) {
180 case ACPI_COMPATIBILITY
:
181 acpi_os_printf (" Compatibility mode\n");
185 acpi_os_printf (" Type A\n");
189 acpi_os_printf (" Type B\n");
193 acpi_os_printf (" Type F\n");
197 acpi_os_printf (" Invalid DMA type\n");
201 acpi_os_printf (" %sBus Master\n",
202 ACPI_BUS_MASTER
== dma_data
->bus_master
? "" : "Not a ");
205 switch (dma_data
->transfer
) {
206 case ACPI_TRANSFER_8
:
207 acpi_os_printf (" 8-bit only transfer\n");
210 case ACPI_TRANSFER_8_16
:
211 acpi_os_printf (" 8 and 16-bit transfer\n");
214 case ACPI_TRANSFER_16
:
215 acpi_os_printf (" 16 bit only transfer\n");
219 acpi_os_printf (" Invalid transfer preference\n");
223 acpi_os_printf (" Number of Channels: %X ( ",
224 dma_data
->number_of_channels
);
226 for (index
= 0; index
< dma_data
->number_of_channels
; index
++) {
227 acpi_os_printf ("%X ", dma_data
->channels
[index
]);
230 acpi_os_printf (")\n");
235 /*******************************************************************************
237 * FUNCTION: acpi_rs_dump_start_depend_fns
239 * PARAMETERS: Data - pointer to the resource structure to dump.
243 * DESCRIPTION: Prints out the various members of the Data structure type.
245 ******************************************************************************/
248 acpi_rs_dump_start_depend_fns (
249 union acpi_resource_data
*data
)
251 struct acpi_resource_start_dpf
*sdf_data
= (struct acpi_resource_start_dpf
*) data
;
254 ACPI_FUNCTION_ENTRY ();
257 acpi_os_printf ("Start Dependent Functions Resource\n");
259 switch (sdf_data
->compatibility_priority
) {
260 case ACPI_GOOD_CONFIGURATION
:
261 acpi_os_printf (" Good configuration\n");
264 case ACPI_ACCEPTABLE_CONFIGURATION
:
265 acpi_os_printf (" Acceptable configuration\n");
268 case ACPI_SUB_OPTIMAL_CONFIGURATION
:
269 acpi_os_printf (" Sub-optimal configuration\n");
273 acpi_os_printf (" Invalid compatibility priority\n");
277 switch(sdf_data
->performance_robustness
) {
278 case ACPI_GOOD_CONFIGURATION
:
279 acpi_os_printf (" Good configuration\n");
282 case ACPI_ACCEPTABLE_CONFIGURATION
:
283 acpi_os_printf (" Acceptable configuration\n");
286 case ACPI_SUB_OPTIMAL_CONFIGURATION
:
287 acpi_os_printf (" Sub-optimal configuration\n");
291 acpi_os_printf (" Invalid performance robustness preference\n");
299 /*******************************************************************************
301 * FUNCTION: acpi_rs_dump_io
303 * PARAMETERS: Data - pointer to the resource structure to dump.
307 * DESCRIPTION: Prints out the various members of the Data structure type.
309 ******************************************************************************/
313 union acpi_resource_data
*data
)
315 struct acpi_resource_io
*io_data
= (struct acpi_resource_io
*) data
;
318 ACPI_FUNCTION_ENTRY ();
321 acpi_os_printf ("Io Resource\n");
323 acpi_os_printf (" %d bit decode\n",
324 ACPI_DECODE_16
== io_data
->io_decode
? 16 : 10);
326 acpi_os_printf (" Range minimum base: %08X\n", io_data
->min_base_address
);
328 acpi_os_printf (" Range maximum base: %08X\n", io_data
->max_base_address
);
330 acpi_os_printf (" Alignment: %08X\n", io_data
->alignment
);
332 acpi_os_printf (" Range Length: %08X\n", io_data
->range_length
);
338 /*******************************************************************************
340 * FUNCTION: acpi_rs_dump_fixed_io
342 * PARAMETERS: Data - pointer to the resource structure to dump.
346 * DESCRIPTION: Prints out the various members of the Data structure type.
348 ******************************************************************************/
351 acpi_rs_dump_fixed_io (
352 union acpi_resource_data
*data
)
354 struct acpi_resource_fixed_io
*fixed_io_data
= (struct acpi_resource_fixed_io
*) data
;
357 ACPI_FUNCTION_ENTRY ();
360 acpi_os_printf ("Fixed Io Resource\n");
361 acpi_os_printf (" Range base address: %08X", fixed_io_data
->base_address
);
363 acpi_os_printf (" Range length: %08X", fixed_io_data
->range_length
);
369 /*******************************************************************************
371 * FUNCTION: acpi_rs_dump_vendor_specific
373 * PARAMETERS: Data - pointer to the resource structure to dump.
377 * DESCRIPTION: Prints out the various members of the Data structure type.
379 ******************************************************************************/
382 acpi_rs_dump_vendor_specific (
383 union acpi_resource_data
*data
)
385 struct acpi_resource_vendor
*vendor_data
= (struct acpi_resource_vendor
*) data
;
389 ACPI_FUNCTION_ENTRY ();
392 acpi_os_printf ("Vendor Specific Resource\n");
394 acpi_os_printf (" Length: %08X\n", vendor_data
->length
);
396 for (index
= 0; index
< vendor_data
->length
; index
++) {
397 acpi_os_printf (" Byte %X: %08X\n",
398 index
, vendor_data
->reserved
[index
]);
405 /*******************************************************************************
407 * FUNCTION: acpi_rs_dump_memory24
409 * PARAMETERS: Data - pointer to the resource structure to dump.
413 * DESCRIPTION: Prints out the various members of the Data structure type.
415 ******************************************************************************/
418 acpi_rs_dump_memory24 (
419 union acpi_resource_data
*data
)
421 struct acpi_resource_mem24
*memory24_data
= (struct acpi_resource_mem24
*) data
;
424 ACPI_FUNCTION_ENTRY ();
427 acpi_os_printf ("24-Bit Memory Range Resource\n");
429 acpi_os_printf (" Read%s\n",
430 ACPI_READ_WRITE_MEMORY
==
431 memory24_data
->read_write_attribute
?
434 acpi_os_printf (" Range minimum base: %08X\n",
435 memory24_data
->min_base_address
);
437 acpi_os_printf (" Range maximum base: %08X\n",
438 memory24_data
->max_base_address
);
440 acpi_os_printf (" Alignment: %08X\n", memory24_data
->alignment
);
442 acpi_os_printf (" Range length: %08X\n", memory24_data
->range_length
);
448 /*******************************************************************************
450 * FUNCTION: acpi_rs_dump_memory32
452 * PARAMETERS: Data - pointer to the resource structure to dump.
456 * DESCRIPTION: Prints out the various members of the Data structure type.
458 ******************************************************************************/
461 acpi_rs_dump_memory32 (
462 union acpi_resource_data
*data
)
464 struct acpi_resource_mem32
*memory32_data
= (struct acpi_resource_mem32
*) data
;
467 ACPI_FUNCTION_ENTRY ();
470 acpi_os_printf ("32-Bit Memory Range Resource\n");
472 acpi_os_printf (" Read%s\n",
473 ACPI_READ_WRITE_MEMORY
==
474 memory32_data
->read_write_attribute
?
477 acpi_os_printf (" Range minimum base: %08X\n",
478 memory32_data
->min_base_address
);
480 acpi_os_printf (" Range maximum base: %08X\n",
481 memory32_data
->max_base_address
);
483 acpi_os_printf (" Alignment: %08X\n", memory32_data
->alignment
);
485 acpi_os_printf (" Range length: %08X\n", memory32_data
->range_length
);
491 /*******************************************************************************
493 * FUNCTION: acpi_rs_dump_fixed_memory32
495 * PARAMETERS: Data - pointer to the resource structure to dump.
499 * DESCRIPTION: Prints out the various members of the Data structure type.
501 ******************************************************************************/
504 acpi_rs_dump_fixed_memory32 (
505 union acpi_resource_data
*data
)
507 struct acpi_resource_fixed_mem32
*fixed_memory32_data
=
508 (struct acpi_resource_fixed_mem32
*) data
;
511 ACPI_FUNCTION_ENTRY ();
514 acpi_os_printf ("32-Bit Fixed Location Memory Range Resource\n");
516 acpi_os_printf (" Read%s\n",
517 ACPI_READ_WRITE_MEMORY
==
518 fixed_memory32_data
->read_write_attribute
? "/Write" : " Only");
520 acpi_os_printf (" Range base address: %08X\n",
521 fixed_memory32_data
->range_base_address
);
523 acpi_os_printf (" Range length: %08X\n",
524 fixed_memory32_data
->range_length
);
530 /*******************************************************************************
532 * FUNCTION: acpi_rs_dump_address16
534 * PARAMETERS: Data - pointer to the resource structure to dump.
538 * DESCRIPTION: Prints out the various members of the Data structure type.
540 ******************************************************************************/
543 acpi_rs_dump_address16 (
544 union acpi_resource_data
*data
)
546 struct acpi_resource_address16
*address16_data
= (struct acpi_resource_address16
*) data
;
549 ACPI_FUNCTION_ENTRY ();
552 acpi_os_printf ("16-Bit Address Space Resource\n");
553 acpi_os_printf (" Resource Type: ");
555 switch (address16_data
->resource_type
) {
556 case ACPI_MEMORY_RANGE
:
558 acpi_os_printf ("Memory Range\n");
560 switch (address16_data
->attribute
.memory
.cache_attribute
) {
561 case ACPI_NON_CACHEABLE_MEMORY
:
562 acpi_os_printf (" Type Specific: Noncacheable memory\n");
565 case ACPI_CACHABLE_MEMORY
:
566 acpi_os_printf (" Type Specific: Cacheable memory\n");
569 case ACPI_WRITE_COMBINING_MEMORY
:
570 acpi_os_printf (" Type Specific: Write-combining memory\n");
573 case ACPI_PREFETCHABLE_MEMORY
:
574 acpi_os_printf (" Type Specific: Prefetchable memory\n");
578 acpi_os_printf (" Type Specific: Invalid cache attribute\n");
582 acpi_os_printf (" Type Specific: Read%s\n",
583 ACPI_READ_WRITE_MEMORY
==
584 address16_data
->attribute
.memory
.read_write_attribute
?
590 acpi_os_printf ("I/O Range\n");
592 switch (address16_data
->attribute
.io
.range_attribute
) {
593 case ACPI_NON_ISA_ONLY_RANGES
:
594 acpi_os_printf (" Type Specific: Non-ISA Io Addresses\n");
597 case ACPI_ISA_ONLY_RANGES
:
598 acpi_os_printf (" Type Specific: ISA Io Addresses\n");
601 case ACPI_ENTIRE_RANGE
:
602 acpi_os_printf (" Type Specific: ISA and non-ISA Io Addresses\n");
606 acpi_os_printf (" Type Specific: Invalid range attribute\n");
610 acpi_os_printf (" Type Specific: %s Translation\n",
611 ACPI_SPARSE_TRANSLATION
==
612 address16_data
->attribute
.io
.translation_attribute
?
616 case ACPI_BUS_NUMBER_RANGE
:
618 acpi_os_printf ("Bus Number Range\n");
623 acpi_os_printf ("0x%2.2X\n", address16_data
->resource_type
);
627 acpi_os_printf (" Resource %s\n",
628 ACPI_CONSUMER
== address16_data
->producer_consumer
?
629 "Consumer" : "Producer");
631 acpi_os_printf (" %s decode\n",
632 ACPI_SUB_DECODE
== address16_data
->decode
?
633 "Subtractive" : "Positive");
635 acpi_os_printf (" Min address is %s fixed\n",
636 ACPI_ADDRESS_FIXED
== address16_data
->min_address_fixed
?
639 acpi_os_printf (" Max address is %s fixed\n",
640 ACPI_ADDRESS_FIXED
== address16_data
->max_address_fixed
?
643 acpi_os_printf (" Granularity: %08X\n",
644 address16_data
->granularity
);
646 acpi_os_printf (" Address range min: %08X\n",
647 address16_data
->min_address_range
);
649 acpi_os_printf (" Address range max: %08X\n",
650 address16_data
->max_address_range
);
652 acpi_os_printf (" Address translation offset: %08X\n",
653 address16_data
->address_translation_offset
);
655 acpi_os_printf (" Address Length: %08X\n",
656 address16_data
->address_length
);
658 if (0xFF != address16_data
->resource_source
.index
) {
659 acpi_os_printf (" Resource Source Index: %X\n",
660 address16_data
->resource_source
.index
);
662 acpi_os_printf (" Resource Source: %s\n",
663 address16_data
->resource_source
.string_ptr
);
670 /*******************************************************************************
672 * FUNCTION: acpi_rs_dump_address32
674 * PARAMETERS: Data - pointer to the resource structure to dump.
678 * DESCRIPTION: Prints out the various members of the Data structure type.
680 ******************************************************************************/
683 acpi_rs_dump_address32 (
684 union acpi_resource_data
*data
)
686 struct acpi_resource_address32
*address32_data
= (struct acpi_resource_address32
*) data
;
689 ACPI_FUNCTION_ENTRY ();
692 acpi_os_printf ("32-Bit Address Space Resource\n");
694 switch (address32_data
->resource_type
) {
695 case ACPI_MEMORY_RANGE
:
697 acpi_os_printf (" Resource Type: Memory Range\n");
699 switch (address32_data
->attribute
.memory
.cache_attribute
) {
700 case ACPI_NON_CACHEABLE_MEMORY
:
701 acpi_os_printf (" Type Specific: Noncacheable memory\n");
704 case ACPI_CACHABLE_MEMORY
:
705 acpi_os_printf (" Type Specific: Cacheable memory\n");
708 case ACPI_WRITE_COMBINING_MEMORY
:
709 acpi_os_printf (" Type Specific: Write-combining memory\n");
712 case ACPI_PREFETCHABLE_MEMORY
:
713 acpi_os_printf (" Type Specific: Prefetchable memory\n");
717 acpi_os_printf (" Type Specific: Invalid cache attribute\n");
721 acpi_os_printf (" Type Specific: Read%s\n",
722 ACPI_READ_WRITE_MEMORY
==
723 address32_data
->attribute
.memory
.read_write_attribute
?
729 acpi_os_printf (" Resource Type: Io Range\n");
731 switch (address32_data
->attribute
.io
.range_attribute
) {
732 case ACPI_NON_ISA_ONLY_RANGES
:
733 acpi_os_printf (" Type Specific: Non-ISA Io Addresses\n");
736 case ACPI_ISA_ONLY_RANGES
:
737 acpi_os_printf (" Type Specific: ISA Io Addresses\n");
740 case ACPI_ENTIRE_RANGE
:
741 acpi_os_printf (" Type Specific: ISA and non-ISA Io Addresses\n");
745 acpi_os_printf (" Type Specific: Invalid Range attribute");
749 acpi_os_printf (" Type Specific: %s Translation\n",
750 ACPI_SPARSE_TRANSLATION
==
751 address32_data
->attribute
.io
.translation_attribute
?
755 case ACPI_BUS_NUMBER_RANGE
:
757 acpi_os_printf (" Resource Type: Bus Number Range\n");
762 acpi_os_printf (" Resource Type: 0x%2.2X\n",
763 address32_data
->resource_type
);
767 acpi_os_printf (" Resource %s\n",
768 ACPI_CONSUMER
== address32_data
->producer_consumer
?
769 "Consumer" : "Producer");
771 acpi_os_printf (" %s decode\n",
772 ACPI_SUB_DECODE
== address32_data
->decode
?
773 "Subtractive" : "Positive");
775 acpi_os_printf (" Min address is %s fixed\n",
776 ACPI_ADDRESS_FIXED
== address32_data
->min_address_fixed
?
779 acpi_os_printf (" Max address is %s fixed\n",
780 ACPI_ADDRESS_FIXED
== address32_data
->max_address_fixed
?
783 acpi_os_printf (" Granularity: %08X\n",
784 address32_data
->granularity
);
786 acpi_os_printf (" Address range min: %08X\n",
787 address32_data
->min_address_range
);
789 acpi_os_printf (" Address range max: %08X\n",
790 address32_data
->max_address_range
);
792 acpi_os_printf (" Address translation offset: %08X\n",
793 address32_data
->address_translation_offset
);
795 acpi_os_printf (" Address Length: %08X\n",
796 address32_data
->address_length
);
798 if(0xFF != address32_data
->resource_source
.index
) {
799 acpi_os_printf (" Resource Source Index: %X\n",
800 address32_data
->resource_source
.index
);
802 acpi_os_printf (" Resource Source: %s\n",
803 address32_data
->resource_source
.string_ptr
);
810 /*******************************************************************************
812 * FUNCTION: acpi_rs_dump_address64
814 * PARAMETERS: Data - pointer to the resource structure to dump.
818 * DESCRIPTION: Prints out the various members of the Data structure type.
820 ******************************************************************************/
823 acpi_rs_dump_address64 (
824 union acpi_resource_data
*data
)
826 struct acpi_resource_address64
*address64_data
= (struct acpi_resource_address64
*) data
;
829 ACPI_FUNCTION_ENTRY ();
832 acpi_os_printf ("64-Bit Address Space Resource\n");
834 switch (address64_data
->resource_type
) {
835 case ACPI_MEMORY_RANGE
:
837 acpi_os_printf (" Resource Type: Memory Range\n");
839 switch (address64_data
->attribute
.memory
.cache_attribute
) {
840 case ACPI_NON_CACHEABLE_MEMORY
:
841 acpi_os_printf (" Type Specific: Noncacheable memory\n");
844 case ACPI_CACHABLE_MEMORY
:
845 acpi_os_printf (" Type Specific: Cacheable memory\n");
848 case ACPI_WRITE_COMBINING_MEMORY
:
849 acpi_os_printf (" Type Specific: Write-combining memory\n");
852 case ACPI_PREFETCHABLE_MEMORY
:
853 acpi_os_printf (" Type Specific: Prefetchable memory\n");
857 acpi_os_printf (" Type Specific: Invalid cache attribute\n");
861 acpi_os_printf (" Type Specific: Read%s\n",
862 ACPI_READ_WRITE_MEMORY
==
863 address64_data
->attribute
.memory
.read_write_attribute
?
869 acpi_os_printf (" Resource Type: Io Range\n");
871 switch (address64_data
->attribute
.io
.range_attribute
) {
872 case ACPI_NON_ISA_ONLY_RANGES
:
873 acpi_os_printf (" Type Specific: Non-ISA Io Addresses\n");
876 case ACPI_ISA_ONLY_RANGES
:
877 acpi_os_printf (" Type Specific: ISA Io Addresses\n");
880 case ACPI_ENTIRE_RANGE
:
881 acpi_os_printf (" Type Specific: ISA and non-ISA Io Addresses\n");
885 acpi_os_printf (" Type Specific: Invalid Range attribute");
889 acpi_os_printf (" Type Specific: %s Translation\n",
890 ACPI_SPARSE_TRANSLATION
==
891 address64_data
->attribute
.io
.translation_attribute
?
895 case ACPI_BUS_NUMBER_RANGE
:
897 acpi_os_printf (" Resource Type: Bus Number Range\n");
902 acpi_os_printf (" Resource Type: 0x%2.2X\n",
903 address64_data
->resource_type
);
907 acpi_os_printf (" Resource %s\n",
908 ACPI_CONSUMER
== address64_data
->producer_consumer
?
909 "Consumer" : "Producer");
911 acpi_os_printf (" %s decode\n",
912 ACPI_SUB_DECODE
== address64_data
->decode
?
913 "Subtractive" : "Positive");
915 acpi_os_printf (" Min address is %s fixed\n",
916 ACPI_ADDRESS_FIXED
== address64_data
->min_address_fixed
?
919 acpi_os_printf (" Max address is %s fixed\n",
920 ACPI_ADDRESS_FIXED
== address64_data
->max_address_fixed
?
923 acpi_os_printf (" Granularity: %8.8X%8.8X\n",
924 ACPI_FORMAT_UINT64 (address64_data
->granularity
));
926 acpi_os_printf (" Address range min: %8.8X%8.8X\n",
927 ACPI_FORMAT_UINT64 (address64_data
->min_address_range
));
929 acpi_os_printf (" Address range max: %8.8X%8.8X\n",
930 ACPI_FORMAT_UINT64 (address64_data
->max_address_range
));
932 acpi_os_printf (" Address translation offset: %8.8X%8.8X\n",
933 ACPI_FORMAT_UINT64 (address64_data
->address_translation_offset
));
935 acpi_os_printf (" Address Length: %8.8X%8.8X\n",
936 ACPI_FORMAT_UINT64 (address64_data
->address_length
));
938 acpi_os_printf (" Type Specific Attributes: %8.8X%8.8X\n",
939 ACPI_FORMAT_UINT64 (address64_data
->type_specific_attributes
));
941 if (0xFF != address64_data
->resource_source
.index
) {
942 acpi_os_printf (" Resource Source Index: %X\n",
943 address64_data
->resource_source
.index
);
945 acpi_os_printf (" Resource Source: %s\n",
946 address64_data
->resource_source
.string_ptr
);
953 /*******************************************************************************
955 * FUNCTION: acpi_rs_dump_extended_irq
957 * PARAMETERS: Data - pointer to the resource structure to dump.
961 * DESCRIPTION: Prints out the various members of the Data structure type.
963 ******************************************************************************/
966 acpi_rs_dump_extended_irq (
967 union acpi_resource_data
*data
)
969 struct acpi_resource_ext_irq
*ext_irq_data
= (struct acpi_resource_ext_irq
*) data
;
973 ACPI_FUNCTION_ENTRY ();
976 acpi_os_printf ("Extended IRQ Resource\n");
978 acpi_os_printf (" Resource %s\n",
979 ACPI_CONSUMER
== ext_irq_data
->producer_consumer
?
980 "Consumer" : "Producer");
982 acpi_os_printf (" %s\n",
983 ACPI_LEVEL_SENSITIVE
== ext_irq_data
->edge_level
?
986 acpi_os_printf (" Active %s\n",
987 ACPI_ACTIVE_LOW
== ext_irq_data
->active_high_low
?
990 acpi_os_printf (" %s\n",
991 ACPI_SHARED
== ext_irq_data
->shared_exclusive
?
992 "Shared" : "Exclusive");
994 acpi_os_printf (" Interrupts : %X ( ", ext_irq_data
->number_of_interrupts
);
996 for (index
= 0; index
< ext_irq_data
->number_of_interrupts
; index
++) {
997 acpi_os_printf ("%X ", ext_irq_data
->interrupts
[index
]);
1000 acpi_os_printf (")\n");
1002 if(0xFF != ext_irq_data
->resource_source
.index
) {
1003 acpi_os_printf (" Resource Source Index: %X",
1004 ext_irq_data
->resource_source
.index
);
1006 acpi_os_printf (" Resource Source: %s",
1007 ext_irq_data
->resource_source
.string_ptr
);
1014 /*******************************************************************************
1016 * FUNCTION: acpi_rs_dump_resource_list
1018 * PARAMETERS: Resource - pointer to the resource structure to dump.
1022 * DESCRIPTION: Dispatches the structure to the correct dump routine.
1024 ******************************************************************************/
1027 acpi_rs_dump_resource_list (
1028 struct acpi_resource
*resource
)
1034 ACPI_FUNCTION_ENTRY ();
1037 if (acpi_dbg_level
& ACPI_LV_RESOURCES
&& _COMPONENT
& acpi_dbg_layer
) {
1039 acpi_os_printf ("Resource structure %X.\n", count
++);
1041 switch (resource
->id
) {
1042 case ACPI_RSTYPE_IRQ
:
1043 acpi_rs_dump_irq (&resource
->data
);
1046 case ACPI_RSTYPE_DMA
:
1047 acpi_rs_dump_dma (&resource
->data
);
1050 case ACPI_RSTYPE_START_DPF
:
1051 acpi_rs_dump_start_depend_fns (&resource
->data
);
1054 case ACPI_RSTYPE_END_DPF
:
1055 acpi_os_printf ("end_dependent_functions Resource\n");
1056 /* acpi_rs_dump_end_dependent_functions (Resource->Data);*/
1059 case ACPI_RSTYPE_IO
:
1060 acpi_rs_dump_io (&resource
->data
);
1063 case ACPI_RSTYPE_FIXED_IO
:
1064 acpi_rs_dump_fixed_io (&resource
->data
);
1067 case ACPI_RSTYPE_VENDOR
:
1068 acpi_rs_dump_vendor_specific (&resource
->data
);
1071 case ACPI_RSTYPE_END_TAG
:
1072 /*rs_dump_end_tag (Resource->Data);*/
1073 acpi_os_printf ("end_tag Resource\n");
1077 case ACPI_RSTYPE_MEM24
:
1078 acpi_rs_dump_memory24 (&resource
->data
);
1081 case ACPI_RSTYPE_MEM32
:
1082 acpi_rs_dump_memory32 (&resource
->data
);
1085 case ACPI_RSTYPE_FIXED_MEM32
:
1086 acpi_rs_dump_fixed_memory32 (&resource
->data
);
1089 case ACPI_RSTYPE_ADDRESS16
:
1090 acpi_rs_dump_address16 (&resource
->data
);
1093 case ACPI_RSTYPE_ADDRESS32
:
1094 acpi_rs_dump_address32 (&resource
->data
);
1097 case ACPI_RSTYPE_ADDRESS64
:
1098 acpi_rs_dump_address64 (&resource
->data
);
1101 case ACPI_RSTYPE_EXT_IRQ
:
1102 acpi_rs_dump_extended_irq (&resource
->data
);
1106 acpi_os_printf ("Invalid resource type\n");
1111 resource
= ACPI_PTR_ADD (struct acpi_resource
, resource
, resource
->length
);
1118 /*******************************************************************************
1120 * FUNCTION: acpi_rs_dump_irq_list
1122 * PARAMETERS: route_table - pointer to the routing table to dump.
1126 * DESCRIPTION: Dispatches the structures to the correct dump routine.
1128 ******************************************************************************/
1131 acpi_rs_dump_irq_list (
1134 u8
*buffer
= route_table
;
1137 struct acpi_pci_routing_table
*prt_element
;
1140 ACPI_FUNCTION_ENTRY ();
1143 if (acpi_dbg_level
& ACPI_LV_RESOURCES
&& _COMPONENT
& acpi_dbg_layer
) {
1144 prt_element
= ACPI_CAST_PTR (struct acpi_pci_routing_table
, buffer
);
1147 acpi_os_printf ("PCI IRQ Routing Table structure %X.\n", count
++);
1149 acpi_os_printf (" Address: %8.8X%8.8X\n",
1150 ACPI_FORMAT_UINT64 (prt_element
->address
));
1152 acpi_os_printf (" Pin: %X\n", prt_element
->pin
);
1154 acpi_os_printf (" Source: %s\n", prt_element
->source
);
1156 acpi_os_printf (" source_index: %X\n", prt_element
->source_index
);
1158 buffer
+= prt_element
->length
;
1159 prt_element
= ACPI_CAST_PTR (struct acpi_pci_routing_table
, buffer
);
1160 if (0 == prt_element
->length
) {