From patchwork Fri Jun 24 10:29:42 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ard Biesheuvel X-Patchwork-Id: 70815 Delivered-To: patch@linaro.org Received: by 10.140.28.4 with SMTP id 4csp873456qgy; Fri, 24 Jun 2016 03:29:55 -0700 (PDT) X-Received: by 10.55.125.7 with SMTP id y7mr3790135qkc.46.1466764195832; Fri, 24 Jun 2016 03:29:55 -0700 (PDT) Return-Path: Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id s66si4399637qkf.111.2016.06.24.03.29.55; Fri, 24 Jun 2016 03:29:55 -0700 (PDT) Received-SPF: pass (google.com: domain of linaro-uefi-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) client-ip=54.225.227.206; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linaro-uefi-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) smtp.mailfrom=linaro-uefi-bounces@lists.linaro.org; dmarc=pass (p=NONE dis=NONE) header.from=linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 0F742681D9; Fri, 24 Jun 2016 10:29:55 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on ip-10-142-244-252 X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, URIBL_BLOCKED autolearn=disabled version=3.4.0 Received: from [127.0.0.1] (localhost [127.0.0.1]) by lists.linaro.org (Postfix) with ESMTP id BBED0681C6; Fri, 24 Jun 2016 10:29:49 +0000 (UTC) X-Original-To: linaro-uefi@lists.linaro.org Delivered-To: linaro-uefi@lists.linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id A8CCD681D6; Fri, 24 Jun 2016 10:29:47 +0000 (UTC) Received: from mail-wm0-f45.google.com (mail-wm0-f45.google.com [74.125.82.45]) by lists.linaro.org (Postfix) with ESMTPS id 3B55F681C6 for ; Fri, 24 Jun 2016 10:29:46 +0000 (UTC) Received: by mail-wm0-f45.google.com with SMTP id v199so17013512wmv.0 for ; Fri, 24 Jun 2016 03:29:46 -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; bh=yRA4qn+QzSoQpRfauFTEtgtT67F1sgFox9o8VlStFiw=; b=hJv99KgcnDczq0hklXBIfSQRN3VlfylUxi5Eo6cF4rKeEeFvHRq9/F9Xck/PrNLAyg SdagYGtfEfwYNwXzxdNhzLsjWJpWLv19l7R7Aj+00Fhs0HSP/WpbQdA9rTbmcirW+oqa SMads1dGXxE8/nhpPat8AYm6JAQVCQ3LqTwCyGwSNifOYkr41JjmTo01W8TDH3t2biGW 9pv4WWvk8BP+FciyN8X8psFqEVEg1gQ72K1C0bNYOqfGxodbXbkDPhOdzbGlzK7fwaIn HJQe4cICuf4jgO2LO0+vdn/+b8Fzu1elkztRMNRKhFfDuhrQDBfFQDxFAS7FkReTUd9f Np/Q== X-Gm-Message-State: ALyK8tJhMY/tfXw6KI7TpxETDM/nTiCNGX/0RqMd3UcKf4JrPztGnWmGy/vP8EM93JHUyUWucmM= X-Received: by 10.28.157.199 with SMTP id g190mr5444769wme.2.1466764185338; Fri, 24 Jun 2016 03:29:45 -0700 (PDT) Received: from localhost.localdomain ([188.203.148.129]) by smtp.gmail.com with ESMTPSA id r7sm4479340wjh.17.2016.06.24.03.29.43 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 24 Jun 2016 03:29:44 -0700 (PDT) From: Ard Biesheuvel To: linaro-uefi@lists.linaro.org Date: Fri, 24 Jun 2016 12:29:42 +0200 Message-Id: <1466764182-17988-1-git-send-email-ard.biesheuvel@linaro.org> X-Mailer: git-send-email 2.7.4 Subject: [Linaro-uefi] [PATCH] Platforms/FVP: Fix MADT to run the Foundation model in GICv3 mode with 4 CPUs X-BeenThere: linaro-uefi@lists.linaro.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: linaro-uefi-bounces@lists.linaro.org Sender: "Linaro-uefi" This upgrades the MADT table so that it exposes the GIC as a v3. The virtual base address and interrupt, and the hypervisor base address are corrected as well. Since the Foundation model has 4 cores at the most, and since refactoring this code to update the ACPI tables dynamically based on the actual core count is more trouble that its worth, remove the second cluster while we are at it. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel --- This applies in combination with Graeme's 'Platforms/ARM: Fix FVP FADT version' Platforms/ARM/VExpress/AcpiTables/rtsm_ve-aemv8a/apic.asl | 116 ++++---------------- 1 file changed, 19 insertions(+), 97 deletions(-) diff --git a/Platforms/ARM/VExpress/AcpiTables/rtsm_ve-aemv8a/apic.asl b/Platforms/ARM/VExpress/AcpiTables/rtsm_ve-aemv8a/apic.asl index 9cd303184352..7d915621efef 100644 --- a/Platforms/ARM/VExpress/AcpiTables/rtsm_ve-aemv8a/apic.asl +++ b/Platforms/ARM/VExpress/AcpiTables/rtsm_ve-aemv8a/apic.asl @@ -61,9 +61,9 @@ [0004] Performance Interrupt : 00000000 [0008] Parked Address : 0000000000000000 [0008] Base Address : 000000002C000000 /* armv8 FVP Base GIC address */ -[0008] Virtual GIC Base Address : 0 -[0008] Hypervisor GIC Base Address : 0 -[0004] Virtual GIC Interrupt : 0 +[0008] Virtual GIC Base Address : 000000002C02F000 +[0008] Hypervisor GIC Base Address : 000000002C010000 +[0004] Virtual GIC Interrupt : 00000019 [0008] Redistributor Base Address : 0 [0008] ARM MPIDR : 0 [0001] Efficiency Class : 00 @@ -82,9 +82,9 @@ [0004] Performance Interrupt : 00000000 [0008] Parked Address : 0000000000000000 [0008] Base Address : 000000002C000000 -[0008] Virtual GIC Base Address : 0 -[0008] Hypervisor GIC Base Address : 0 -[0004] Virtual GIC Interrupt : 0 +[0008] Virtual GIC Base Address : 000000002C02F000 +[0008] Hypervisor GIC Base Address : 000000002C010000 +[0004] Virtual GIC Interrupt : 00000019 [0008] Redistributor Base Address : 0 [0008] ARM MPIDR : 0000000000000001 [0001] Efficiency Class : 00 @@ -103,9 +103,9 @@ [0004] Performance Interrupt : 00000000 [0008] Parked Address : 0000000000000000 [0008] Base Address : 000000002C000000 -[0008] Virtual GIC Base Address : 0 -[0008] Hypervisor GIC Base Address : 0 -[0004] Virtual GIC Interrupt : 0 +[0008] Virtual GIC Base Address : 000000002C02F000 +[0008] Hypervisor GIC Base Address : 000000002C010000 +[0004] Virtual GIC Interrupt : 00000019 [0008] Redistributor Base Address : 0 [0008] ARM MPIDR : 0000000000000002 [0001] Efficiency Class : 00 @@ -124,103 +124,25 @@ [0004] Performance Interrupt : 00000000 [0008] Parked Address : 0000000000000000 [0008] Base Address : 000000002C000000 -[0008] Virtual GIC Base Address : 0 -[0008] Hypervisor GIC Base Address : 0 -[0004] Virtual GIC Interrupt : 0 +[0008] Virtual GIC Base Address : 000000002C02F000 +[0008] Hypervisor GIC Base Address : 000000002C010000 +[0004] Virtual GIC Interrupt : 00000019 [0008] Redistributor Base Address : 0 [0008] ARM MPIDR : 0000000000000003 [0001] Efficiency Class : 00 [0003] Reserved : 000000 -[0001] Subtable Type : 0B [Generic Interrupt Controller] -[0001] Length : 50 -[0002] Reserved : 0000 -[0004] CPU Interface Number : 00000004 -[0004] Processor UID : 00000004 -[0004] Flags (decoded below) : 00000001 - Processor Enabled : 1 - Performance Interrupt Trigger Mode : 0 - Virtual GIC Interrupt Trigger Mode : 0 -[0004] Parking Protocol Version : 00000000 -[0004] Performance Interrupt : 00000000 -[0008] Parked Address : 0000000000000000 -[0008] Base Address : 000000002C000000 -[0008] Virtual GIC Base Address : 0 -[0008] Hypervisor GIC Base Address : 0 -[0004] Virtual GIC Interrupt : 0 -[0008] Redistributor Base Address : 0 -[0008] ARM MPIDR : 0000000000000100 -[0001] Efficiency Class : 00 -[0003] Reserved : 000000 - -[0001] Subtable Type : 0B [Generic Interrupt Controller] -[0001] Length : 50 -[0002] Reserved : 0000 -[0004] CPU Interface Number : 00000005 -[0004] Processor UID : 00000005 -[0004] Flags (decoded below) : 00000001 - Processor Enabled : 1 - Performance Interrupt Trigger Mode : 0 - Virtual GIC Interrupt Trigger Mode : 0 -[0004] Parking Protocol Version : 00000000 -[0004] Performance Interrupt : 00000000 -[0008] Parked Address : 0000000000000000 -[0008] Base Address : 000000002C000000 -[0008] Virtual GIC Base Address : 0 -[0008] Hypervisor GIC Base Address : 0 -[0004] Virtual GIC Interrupt : 0 -[0008] Redistributor Base Address : 0 -[0008] ARM MPIDR : 0000000000000101 -[0001] Efficiency Class : 00 -[0003] Reserved : 000000 - -[0001] Subtable Type : 0B [Generic Interrupt Controller] -[0001] Length : 50 -[0002] Reserved : 0000 -[0004] CPU Interface Number : 00000006 -[0004] Processor UID : 00000006 -[0004] Flags (decoded below) : 00000001 - Processor Enabled : 1 - Performance Interrupt Trigger Mode : 0 - Virtual GIC Interrupt Trigger Mode : 0 -[0004] Parking Protocol Version : 00000000 -[0004] Performance Interrupt : 00000000 -[0008] Parked Address : 0000000000000000 -[0008] Base Address : 000000002C000000 -[0008] Virtual GIC Base Address : 0 -[0008] Hypervisor GIC Base Address : 0 -[0004] Virtual GIC Interrupt : 0 -[0008] Redistributor Base Address : 0 -[0008] ARM MPIDR : 0000000000000102 -[0001] Efficiency Class : 00 -[0003] Reserved : 000000 - -[0001] Subtable Type : 0B [Generic Interrupt Controller] -[0001] Length : 50 -[0002] Reserved : 0000 -[0004] CPU Interface Number : 00000007 -[0004] Processor UID : 00000007 -[0004] Flags (decoded below) : 00000001 - Processor Enabled : 1 - Performance Interrupt Trigger Mode : 0 - Virtual GIC Interrupt Trigger Mode : 0 -[0004] Parking Protocol Version : 00000000 -[0004] Performance Interrupt : 00000000 -[0008] Parked Address : 0000000000000000 -[0008] Base Address : 000000002C000000 -[0008] Virtual GIC Base Address : 0 -[0008] Hypervisor GIC Base Address : 0 -[0004] Virtual GIC Interrupt : 0 -[0008] Redistributor Base Address : 0 -[0008] ARM MPIDR : 0000000000000103 -[0001] Efficiency Class : 00 -[0003] Reserved : 000000 - [0001] Subtable Type : 0C [Generic Interrupt Distributor] [0001] Length : 18 [0002] Reserved : 0000 [0004] Local GIC Hardware ID : 00000000 [0008] Base Address : 000000002F000000 /* armv8 FVP Base GIC distributor base addr */ [0004] Interrupt Base : 00000000 -[0001] Version : 02 +[0001] Version : 03 [0003] Reserved : 000000 + +[0001] Subtable Type : 0E [Generic Interrupt Redistributor] +[0001] Length : 10 +[0002] Reserved : 0000 +[0008] Base Address : 000000002F100000 /* armv8 FVP Base GIC redistributor base addr */ +[0004] Region Size : 00200000