From: Hanjun Guo Date: Tue, 24 Mar 2015 14:02:44 +0000 (+0000) Subject: ACPI / table: Print GIC information when MADT is parsed X-Git-Tag: firefly_0821_release~176^2~1869^2~20 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=4c1c8d7a7ebc8b909493a14b21b233e5377b69aa;p=firefly-linux-kernel-4.4.55.git ACPI / table: Print GIC information when MADT is parsed When MADT is parsed, print GIC information as debug message: ACPI: GICC (acpi_id[0x0000] address[00000000e112f000] MPIDR[0x0] enabled) ACPI: GICC (acpi_id[0x0001] address[00000000e112f000] MPIDR[0x1] enabled) ... ACPI: GICC (acpi_id[0x0201] address[00000000e112f000] MPIDR[0x201] enabled) This debug information will be very helpful to bring up early systems to see if acpi_id and MPIDR are matched or not as spec defined. CC: Rafael J. Wysocki Tested-by: Suravee Suthikulpanit Tested-by: Yijing Wang Tested-by: Mark Langsdorf Tested-by: Jon Masters Tested-by: Timur Tabi Tested-by: Robert Richter Acked-by: Robert Richter Acked-by: Sudeep Holla Acked-by: Rafael J. Wysocki Acked-by: Lorenzo Pieralisi Acked-by: Grant Likely Signed-off-by: Hanjun Guo Signed-off-by: Tomasz Nowicki Signed-off-by: Will Deacon --- diff --git a/drivers/acpi/tables.c b/drivers/acpi/tables.c index f4e5b888b98e..2e19189da0ee 100644 --- a/drivers/acpi/tables.c +++ b/drivers/acpi/tables.c @@ -185,6 +185,28 @@ void acpi_table_print_madt_entry(struct acpi_subtable_header *header) } break; + case ACPI_MADT_TYPE_GENERIC_INTERRUPT: + { + struct acpi_madt_generic_interrupt *p = + (struct acpi_madt_generic_interrupt *)header; + pr_debug("GICC (acpi_id[0x%04x] address[%llx] MPIDR[0x%llx] %s)\n", + p->uid, p->base_address, + p->arm_mpidr, + (p->flags & ACPI_MADT_ENABLED) ? "enabled" : "disabled"); + + } + break; + + case ACPI_MADT_TYPE_GENERIC_DISTRIBUTOR: + { + struct acpi_madt_generic_distributor *p = + (struct acpi_madt_generic_distributor *)header; + pr_debug("GIC Distributor (gic_id[0x%04x] address[%llx] gsi_base[%d])\n", + p->gic_id, p->base_address, + p->global_irq_base); + } + break; + default: pr_warn("Found unsupported MADT entry (type = 0x%x)\n", header->type);