From patchwork Wed Jan 14 15:04:57 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hanjun Guo X-Patchwork-Id: 43115 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-wg0-f69.google.com (mail-wg0-f69.google.com [74.125.82.69]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 7D28D240B9 for ; Wed, 14 Jan 2015 15:08:14 +0000 (UTC) Received: by mail-wg0-f69.google.com with SMTP id x12sf5165739wgg.0 for ; Wed, 14 Jan 2015 07:08:13 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:sender:precedence:list-id :x-original-sender:x-original-authentication-results:mailing-list :list-post:list-help:list-archive:list-unsubscribe; bh=WpGOK+kKxcMMFQpjNsjlY5POKX89Ujqlp4ckmtP/1IA=; b=JSDVNYwon7+uSe9a+FmB8t+R72wOcWF/BoysAFWPsjxGdZKniITHbCSI4gQ8AygsoK /TcmGH/sLUZrx5vGwPCRFKrL1cGrWIf9zeNofA5GtgABmTqmacWV/hQt3+T/3zsHTFTj VvY5GbVTTdPs5WJgggYD8DpqQwtyrdtF2C5wioTtpikJ9d0PoJg3NwEvXK5mQfe0BLq/ GlmKrZaEpTsIjc58DFStrw80MMXZxgeIdH7/k4zT7C5XBtH9auM3hlrbdxUbG4Y3fdcG QOMPb8xuYLjpYiVHmbh5jHEP1pVc8i0A8gi7MX1b16IQolEbU5gLLFHDIcUz7lf1bqTn y2CA== X-Gm-Message-State: ALoCoQlmDO4nWY68Lu7Cc7Lxd00R8NE5sjl4hb8MFjYW5Q9DFs6QSAwxpEOLGeIdM0yXvkI5JOrn X-Received: by 10.194.176.200 with SMTP id ck8mr591312wjc.0.1421248093717; Wed, 14 Jan 2015 07:08:13 -0800 (PST) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.87.50 with SMTP id u18ls119870laz.96.gmail; Wed, 14 Jan 2015 07:08:13 -0800 (PST) X-Received: by 10.112.25.7 with SMTP id y7mr4408055lbf.94.1421248093515; Wed, 14 Jan 2015 07:08:13 -0800 (PST) Received: from mail-lb0-f176.google.com (mail-lb0-f176.google.com. [209.85.217.176]) by mx.google.com with ESMTPS id e8si6150394lam.60.2015.01.14.07.08.13 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 14 Jan 2015 07:08:13 -0800 (PST) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.176 as permitted sender) client-ip=209.85.217.176; Received: by mail-lb0-f176.google.com with SMTP id p9so8415223lbv.7 for ; Wed, 14 Jan 2015 07:08:13 -0800 (PST) X-Received: by 10.152.87.100 with SMTP id w4mr4390189laz.71.1421248093385; Wed, 14 Jan 2015 07:08:13 -0800 (PST) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.9.200 with SMTP id c8csp1726290lbb; Wed, 14 Jan 2015 07:08:12 -0800 (PST) X-Received: by 10.66.250.198 with SMTP id ze6mr6216498pac.99.1421248091517; Wed, 14 Jan 2015 07:08:11 -0800 (PST) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id if2si31031665pbc.95.2015.01.14.07.08.10; Wed, 14 Jan 2015 07:08:11 -0800 (PST) Received-SPF: none (google.com: linux-kernel-owner@vger.kernel.org does not designate permitted sender hosts) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753840AbbANPIG (ORCPT + 28 others); Wed, 14 Jan 2015 10:08:06 -0500 Received: from mail-pa0-f54.google.com ([209.85.220.54]:38575 "EHLO mail-pa0-f54.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753078AbbANPIB (ORCPT ); Wed, 14 Jan 2015 10:08:01 -0500 Received: by mail-pa0-f54.google.com with SMTP id fb1so10964816pad.13 for ; Wed, 14 Jan 2015 07:08:01 -0800 (PST) X-Received: by 10.70.37.166 with SMTP id z6mr6247353pdj.89.1421248081424; Wed, 14 Jan 2015 07:08:01 -0800 (PST) Received: from localhost (119.81.172.112-static.reverse.softlayer.com. [119.81.172.112]) by mx.google.com with ESMTPSA id gi6sm19906559pbd.93.2015.01.14.07.07.58 (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Wed, 14 Jan 2015 07:08:00 -0800 (PST) From: Hanjun Guo To: Catalin Marinas , "Rafael J. Wysocki" , Olof Johansson , Arnd Bergmann , Mark Rutland , Grant Likely , Will Deacon Cc: Lorenzo Pieralisi , Graeme Gregory , Sudeep Holla , Jon Masters , Jason Cooper , Marc Zyngier , Bjorn Helgaas , Mark Brown , Rob Herring , Robert Richter , Randy Dunlap , Charles.Garcia-Tobin@arm.com, phoenix.liyi@huawei.com, Timur Tabi , suravee.suthikulpanit@amd.com, wangyijing@huawei.com, linux-acpi@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linaro-acpi@lists.linaro.org, Hanjun Guo , Tomasz Nowicki Subject: [PATCH v7 09/17] ACPI / table: Print GIC information when MADT is parsed Date: Wed, 14 Jan 2015 23:04:57 +0800 Message-Id: <1421247905-3749-10-git-send-email-hanjun.guo@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1421247905-3749-1-git-send-email-hanjun.guo@linaro.org> References: <1421247905-3749-1-git-send-email-hanjun.guo@linaro.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: hanjun.guo@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.176 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , When MADT is parsed, print GIC information to make the boot log look pretty: 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) These information will be very helpful to bring up early systems to see if acpi_id and MPIDR are matched or not as spec defined. Tested-by: Suravee Suthikulpanit Tested-by: Yijing Wang Signed-off-by: Hanjun Guo Signed-off-by: Tomasz Nowicki --- drivers/acpi/tables.c | 43 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) diff --git a/drivers/acpi/tables.c b/drivers/acpi/tables.c index 93b8152..42d314f 100644 --- a/drivers/acpi/tables.c +++ b/drivers/acpi/tables.c @@ -183,6 +183,49 @@ 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_info("GICC (acpi_id[0x%04x] address[%p] MPIDR[0x%llx] %s)\n", + p->uid, (void *)(unsigned long)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_info("GIC Distributor (gic_id[0x%04x] address[%p] gsi_base[%d])\n", + p->gic_id, + (void *)(unsigned long)p->base_address, + p->global_irq_base); + } + break; + + case ACPI_MADT_TYPE_GENERIC_MSI_FRAME: + { + struct acpi_madt_generic_msi_frame *p = + (struct acpi_madt_generic_msi_frame *)header; + pr_info("GIC MSI Frame (msi_fame_id[%d] address[%p])\n", + p->msi_frame_id, + (void *)(unsigned long)p->base_address); + } + break; + + case ACPI_MADT_TYPE_GENERIC_REDISTRIBUTOR: + { + struct acpi_madt_generic_redistributor *p = + (struct acpi_madt_generic_redistributor *)header; + pr_info("GIC Redistributor (address[%p] region_size[0x%x])\n", + (void *)(unsigned long)p->base_address, + p->length); + } + break; + default: pr_warn("Found unsupported MADT entry (type = 0x%x)\n", header->type);