From patchwork Mon Jul 6 23:16:48 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: al.stone@linaro.org X-Patchwork-Id: 6728361 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id D985FC05AC for ; Mon, 6 Jul 2015 23:19:59 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 0A395206CC for ; Mon, 6 Jul 2015 23:19:59 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 1FC3A206B5 for ; Mon, 6 Jul 2015 23:19:58 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1ZCFdo-0006vw-Ho; Mon, 06 Jul 2015 23:17:36 +0000 Received: from mail-ig0-f169.google.com ([209.85.213.169]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1ZCFdb-0006hv-Oi for linux-arm-kernel@lists.infradead.org; Mon, 06 Jul 2015 23:17:24 +0000 Received: by igcqs7 with SMTP id qs7so21122292igc.0 for ; Mon, 06 Jul 2015 16:17:03 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=+gCMEdhw+J+oQMkeJNcE6C2Xp5GslEJIF3bNL00+d4c=; b=fVXU/P7du2QdhzUdtHqpY03ee5JNxW+tk1c0mcJVa98EbHUjtcegWrAFK5I0Ma9RwY lyivrv06PHPTf8EerQ+tob+KuHLLeTUfRZ6pUnkbQZLwSb/9tgDm+FpgGa16UAVre382 jD9ZrUiHdpgFCTWIG9o4F0SUlySt+IWFS8k8g1aGiUgFyy+UhAE96dYrD8NajJVSA6kh i2//qFeEEe309QHhd30Kiq5Cpq1ReRQFYHWY/yPEajwSxXuDebfG/+CVXMqqFT6715vJ 3QRhK5bneJ1grMXNlAkei3XCKcqUIUvVQ9HD0EtFeOgxKPRn7GvndzBIqNdCWuFVwTog Pz3Q== X-Gm-Message-State: ALoCoQkq0IexdGGeZpZBbSchEMv59sLNTToz1ZyVjnYsdV4AFwPZYaw0nExCDym8rjvBn/XIg3zG X-Received: by 10.50.61.241 with SMTP id t17mr45665379igr.34.1436224622963; Mon, 06 Jul 2015 16:17:02 -0700 (PDT) Received: from fidelio.ahs3.com (c-50-134-239-249.hsd1.co.comcast.net. [50.134.239.249]) by mx.google.com with ESMTPSA id y98sm5531581ioi.25.2015.07.06.16.17.00 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 06 Jul 2015 16:17:01 -0700 (PDT) From: Al Stone To: linux-acpi@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: [PATCH v4 2/2] ACPI / ARM64 : use the new BAD_MADT_GICC_ENTRY macro Date: Mon, 6 Jul 2015 17:16:48 -0600 Message-Id: <1436224608-27754-3-git-send-email-al.stone@linaro.org> X-Mailer: git-send-email 2.4.3 In-Reply-To: <1436224608-27754-1-git-send-email-al.stone@linaro.org> References: <1436224608-27754-1-git-send-email-al.stone@linaro.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20150706_161723_848628_058815EA X-CRM114-Status: GOOD ( 12.42 ) X-Spam-Score: -2.6 (--) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linaro-kernel@lists.linaro.org, jason@lakedaemon.net, linaro-acpi@lists.linaro.org, catalin.marinas@arm.com, patches@linaro.org, rjw@rjwysocki.net, linux-kernel@vger.kernel.org, will.deacon@arm.com, tglx@linutronix.de, lenb@kernel.org MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-4.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP For those parts of the arm64 ACPI code that need to check GICC subtables in the MADT, use the new BAD_MADT_GICC_ENTRY macro instead of the previous BAD_MADT_ENTRY. The new macro takes into account differences in the size of the GICC subtable that the old macro did not; this caused failures even though the subtable entries are valid. Fixes: aeb823bbacc2 (ACPICA: ACPI 6.0: Add changes for FADT table.) Signed-off-by: Al Stone Reviewed-by: Hanjun Guo Acked-by: Will Deacon --- arch/arm64/kernel/smp.c | 2 +- drivers/irqchip/irq-gic.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/arm64/kernel/smp.c b/arch/arm64/kernel/smp.c index a1883bf..25fc88c 100644 --- a/arch/arm64/kernel/smp.c +++ b/arch/arm64/kernel/smp.c @@ -438,7 +438,7 @@ acpi_parse_gic_cpu_interface(struct acpi_subtable_header *header, struct acpi_madt_generic_interrupt *processor; processor = (struct acpi_madt_generic_interrupt *)header; - if (BAD_MADT_ENTRY(processor, end)) + if (BAD_MADT_GICC_ENTRY(processor, end)) return -EINVAL; acpi_table_print_madt_entry(header); diff --git a/drivers/irqchip/irq-gic.c b/drivers/irqchip/irq-gic.c index 8d7e1c8..4dd8826 100644 --- a/drivers/irqchip/irq-gic.c +++ b/drivers/irqchip/irq-gic.c @@ -1055,7 +1055,7 @@ gic_acpi_parse_madt_cpu(struct acpi_subtable_header *header, processor = (struct acpi_madt_generic_interrupt *)header; - if (BAD_MADT_ENTRY(processor, end)) + if (BAD_MADT_GICC_ENTRY(processor, end)) return -EINVAL; /*