From patchwork Wed Jul 6 13:48: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: 71470 Delivered-To: patch@linaro.org Received: by 10.140.28.4 with SMTP id 4csp875280qgy; Wed, 6 Jul 2016 06:48:58 -0700 (PDT) X-Received: by 10.55.197.149 with SMTP id k21mr30349790qkl.89.1467812938562; Wed, 06 Jul 2016 06:48:58 -0700 (PDT) Return-Path: Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id 22si2258721qtq.132.2016.07.06.06.48.57; Wed, 06 Jul 2016 06:48:58 -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 3901A68429; Wed, 6 Jul 2016 13:48:57 +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 C7B1F683F8; Wed, 6 Jul 2016 13:48:51 +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 8A1676841E; Wed, 6 Jul 2016 13:48:47 +0000 (UTC) Received: from mail-wm0-f42.google.com (mail-wm0-f42.google.com [74.125.82.42]) by lists.linaro.org (Postfix) with ESMTPS id 4AF7A683F8 for ; Wed, 6 Jul 2016 13:48:46 +0000 (UTC) Received: by mail-wm0-f42.google.com with SMTP id a66so193595642wme.0 for ; Wed, 06 Jul 2016 06:48: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=k4zneye5r3aY2YVkIi7c+dg42NpbRbOZUlB0ogKbEnw=; b=faIuoHoG/i/RibL8oSm4gQU84v4PjC6qShHrGxZ7VYzUvDLOSECSLqUuUoWnHRA0Bx XjMLYNBYjxfZQUoJ2rt7YfnL1RoIKlZ7qBBVpoJVZEjc4nw3RCAdoRHJnYCuvUE4tGzh HIel5qP5UXslItVgfPiDRg9gaOvMqoxxNx1pj8qNrqX0Kwl0GQ0tVhP54xhTCsNo4Bm0 s/dxZF1FFc7cletJ0b+ocLojdR1sc27w10R99nLrBtpKlsTAjJTzg8Sjv4gI8XRve+bT H2V+4m346Tk3a1JmGFXyIRnvqjhszcEKWu5xXL4MwmP/tr4RVadpwBwuQVhRg0u/uqSL FgCQ== X-Gm-Message-State: ALyK8tI6zX4V9/d+4sLNhGPXt1TjgbFvk+Eez7l5d4gM0i63iLvvNDXqjStCJzFj4FXyKZTZc/k= X-Received: by 10.194.31.137 with SMTP id a9mr24214338wji.113.1467812925129; Wed, 06 Jul 2016 06:48:45 -0700 (PDT) Received: from localhost.localdomain (ip16-2-212-87.adsl2.static.versatel.nl. [87.212.2.16]) by smtp.gmail.com with ESMTPSA id d4sm2294812wjb.47.2016.07.06.06.48.43 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 06 Jul 2016 06:48:44 -0700 (PDT) From: Ard Biesheuvel To: linaro-uefi@lists.linaro.org, leif.lindholm@linaro.org, ryan.harkin@linaro.org, heyi.guo@linaro.org, ricardo.salveti@linaro.org Date: Wed, 6 Jul 2016 15:48:42 +0200 Message-Id: <1467812922-24584-1-git-send-email-ard.biesheuvel@linaro.org> X-Mailer: git-send-email 1.9.1 Subject: [Linaro-uefi] [PATCH] Platforms: add resolution for new library class 'ArmMmuLib' 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" Now that the page table manipulation code has been split off from ArmLib into ArmMmuLib, we need a resolution for this new library class in all platforms. For most platforms, this is simply a matter of adding a new line ArmMmuLib|ArmPkg/Library/ArmMmuLib/ArmMmuBaseLib.inf to a common [LibraryClass] section. For D02/D03, which were users of the special PEI_CORE/PEIM implementation of ArmLib, we drop the reference to this special version from the [LibraryClasses.PEI_CORE] section (since PEI core does use ArmLib but does not use the MMU code), and replace the one in [LibraryClasses.PEIM] with the new ArmMmuPeiLib.inf implementation, which is the new version that takes care not to issue cache maintenance ops on NOR flash. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel --- This change will be needed as soon as I commit the series 'ArmPkg: refactor MMU handling routines into separate ArmMmuLib', which is good to go from review perspective. If people are ok with this patch, I will merge it at the same time as the series (unless there are other reasons to wait) Since this change is not bisectable anyway (since the EDK2 change and the OPP change both need to occur at the same time), I saw little point in splitting this into several patches. Chips/Hisilicon/Pv660/Pv660.dsc.inc | 4 ++-- Chips/TexasInstruments/Omap35xx/Omap35xxPkg.dsc | 1 + Platforms/AMD/Styx/CelloBoard/CelloBoard.dsc | 1 + Platforms/AMD/Styx/OverdriveBoard/OverdriveBoard.dsc | 1 + Platforms/ARM/Juno/ArmJuno.dsc | 1 + Platforms/ARM/VExpress/ArmVExpress-CTA15-A7.dsc | 1 + Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc | 1 + Platforms/TexasInstruments/BeagleBoard/BeagleBoardPkg.dsc | 1 + 8 files changed, 9 insertions(+), 2 deletions(-) diff --git a/Chips/Hisilicon/Pv660/Pv660.dsc.inc b/Chips/Hisilicon/Pv660/Pv660.dsc.inc index 2a0ffac9c72d..029608ceeb78 100644 --- a/Chips/Hisilicon/Pv660/Pv660.dsc.inc +++ b/Chips/Hisilicon/Pv660/Pv660.dsc.inc @@ -65,6 +65,7 @@ ArmGicArchLib|ArmPkg/Library/ArmGicArchLib/ArmGicArchLib.inf ArmPlatformStackLib|ArmPlatformPkg/Library/ArmPlatformStackLib/ArmPlatformStackLib.inf ArmSmcLib|ArmPkg/Library/ArmSmcLib/ArmSmcLib.inf + ArmMmuLib|ArmPkg/Library/ArmMmuLib/ArmMmuBaseLib.inf # Versatile Express Specific Libraries ArmPlatformSysConfigLib|ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressSysConfigLib/ArmVExpressSysConfigLib.inf @@ -166,7 +167,6 @@ PeiServicesTablePointerLib|ArmPkg/Library/PeiServicesTablePointerLib/PeiServicesTablePointerLib.inf PcdLib|MdePkg/Library/PeiPcdLib/PeiPcdLib.inf - ArmLib|ArmPkg/Library/ArmLib/AArch64/AArch64LibPei.inf [LibraryClasses.common.PEIM] HobLib|MdePkg/Library/PeiHobLib/PeiHobLib.inf @@ -186,7 +186,7 @@ ## Fixed compile error after upgrade to 14.10 PlatformPeiLib|ArmPlatformPkg/PlatformPei/PlatformPeiLib.inf PcdLib|MdePkg/Library/PeiPcdLib/PeiPcdLib.inf - ArmLib|ArmPkg/Library/ArmLib/AArch64/AArch64LibPei.inf + ArmMmuLib|ArmPkg/Library/ArmMmuLib/ArmMmuPeiLib.inf [LibraryClasses.common.DXE_CORE] HobLib|MdePkg/Library/DxeCoreHobLib/DxeCoreHobLib.inf diff --git a/Chips/TexasInstruments/Omap35xx/Omap35xxPkg.dsc b/Chips/TexasInstruments/Omap35xx/Omap35xxPkg.dsc index f6606cafb849..2b15d7f5667b 100644 --- a/Chips/TexasInstruments/Omap35xx/Omap35xxPkg.dsc +++ b/Chips/TexasInstruments/Omap35xx/Omap35xxPkg.dsc @@ -34,6 +34,7 @@ DebugLib|MdePkg/Library/BaseDebugLibNull/BaseDebugLibNull.inf ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.inf + ArmMmuLib|ArmPkg/Library/ArmMmuLib/ArmMmuBaseLib.inf MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf BaseLib|MdePkg/Library/BaseLib/BaseLib.inf diff --git a/Platforms/AMD/Styx/CelloBoard/CelloBoard.dsc b/Platforms/AMD/Styx/CelloBoard/CelloBoard.dsc index 437286876a31..6b9446a1387d 100644 --- a/Platforms/AMD/Styx/CelloBoard/CelloBoard.dsc +++ b/Platforms/AMD/Styx/CelloBoard/CelloBoard.dsc @@ -101,6 +101,7 @@ DEFINE DO_KCS = 0 ArmLib|ArmPkg/Library/ArmLib/AArch64/AArch64Lib.inf ArmCpuLib|ArmPkg/Drivers/ArmCpuLib/ArmCortexA5xLib/ArmCortexA5xLib.inf + ArmMmuLib|ArmPkg/Library/ArmMmuLib/ArmMmuBaseLib.inf ArmPlatformLib|OpenPlatformPkg/Platforms/AMD/Styx/Library/AmdStyxLib/AmdStyxLib.inf TimerLib|ArmPkg/Library/ArmArchTimerLib/ArmArchTimerLib.inf UefiScsiLib|MdePkg/Library/UefiScsiLib/UefiScsiLib.inf diff --git a/Platforms/AMD/Styx/OverdriveBoard/OverdriveBoard.dsc b/Platforms/AMD/Styx/OverdriveBoard/OverdriveBoard.dsc index c73bd55c1558..0f8dd814ad15 100644 --- a/Platforms/AMD/Styx/OverdriveBoard/OverdriveBoard.dsc +++ b/Platforms/AMD/Styx/OverdriveBoard/OverdriveBoard.dsc @@ -104,6 +104,7 @@ DEFINE DO_KCS = 1 ArmLib|ArmPkg/Library/ArmLib/AArch64/AArch64Lib.inf ArmCpuLib|ArmPkg/Drivers/ArmCpuLib/ArmCortexA5xLib/ArmCortexA5xLib.inf + ArmMmuLib|ArmPkg/Library/ArmMmuLib/ArmMmuBaseLib.inf ArmPlatformLib|OpenPlatformPkg/Platforms/AMD/Styx/Library/AmdStyxLib/AmdStyxLib.inf TimerLib|ArmPkg/Library/ArmArchTimerLib/ArmArchTimerLib.inf UefiScsiLib|MdePkg/Library/UefiScsiLib/UefiScsiLib.inf diff --git a/Platforms/ARM/Juno/ArmJuno.dsc b/Platforms/ARM/Juno/ArmJuno.dsc index 490e08eb9248..4f41fb159f19 100644 --- a/Platforms/ARM/Juno/ArmJuno.dsc +++ b/Platforms/ARM/Juno/ArmJuno.dsc @@ -34,6 +34,7 @@ !include OpenPlatformPkg/Platforms/ARM/VExpress/ArmVExpress.dsc.inc [LibraryClasses.common] + ArmMmuLib|ArmPkg/Library/ArmMmuLib/ArmMmuBaseLib.inf ArmPlatformLib|ArmPlatformPkg/ArmJunoPkg/Library/ArmJunoLib/ArmJunoLib.inf ArmSmcLib|ArmPkg/Library/ArmSmcLib/ArmSmcLib.inf diff --git a/Platforms/ARM/VExpress/ArmVExpress-CTA15-A7.dsc b/Platforms/ARM/VExpress/ArmVExpress-CTA15-A7.dsc index 9daf3c8ff512..ef8fd971e66b 100644 --- a/Platforms/ARM/VExpress/ArmVExpress-CTA15-A7.dsc +++ b/Platforms/ARM/VExpress/ArmVExpress-CTA15-A7.dsc @@ -39,6 +39,7 @@ [LibraryClasses.common] ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.inf + ArmMmuLib|ArmPkg/Library/ArmMmuLib/ArmMmuBaseLib.inf ArmPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibCTA15-A7/ArmVExpressLib.inf ArmPlatformSysConfigLib|ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressSysConfigLib/ArmVExpressSysConfigLib.inf diff --git a/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc b/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc index 1e871b541c6e..65b14eb793a8 100644 --- a/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc +++ b/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc @@ -42,6 +42,7 @@ ArmLib|ArmPkg/Library/ArmLib/AArch64/AArch64Lib.inf ArmCpuLib|ArmPkg/Drivers/ArmCpuLib/ArmCortexAEMv8Lib/ArmCortexAEMv8Lib.inf ArmPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/ArmVExpressLib.inf + ArmMmuLib|ArmPkg/Library/ArmMmuLib/ArmMmuBaseLib.inf ArmPlatformSysConfigLib|ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressSysConfigLib/ArmVExpressSysConfigLib.inf NorFlashPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/NorFlashArmVExpressLib/NorFlashArmVExpressLib.inf diff --git a/Platforms/TexasInstruments/BeagleBoard/BeagleBoardPkg.dsc b/Platforms/TexasInstruments/BeagleBoard/BeagleBoardPkg.dsc index e24df3b7a8df..3c2b767552fa 100644 --- a/Platforms/TexasInstruments/BeagleBoard/BeagleBoardPkg.dsc +++ b/Platforms/TexasInstruments/BeagleBoard/BeagleBoardPkg.dsc @@ -32,6 +32,7 @@ [LibraryClasses.common] ArmLib|ArmPkg/Library/ArmLib/ArmV7/ArmV7Lib.inf + ArmMmuLib|ArmPkg/Library/ArmMmuLib/ArmMmuBaseLib.inf ArmPlatformLib|OpenPlatformPkg/Platforms/TexasInstruments/BeagleBoard/Library/BeagleBoardLib/BeagleBoardLib.inf ArmCpuLib|ArmPkg/Drivers/ArmCpuLib/ArmCortexA8Lib/ArmCortexA8Lib.inf ArmPlatformStackLib|ArmPlatformPkg/Library/ArmPlatformStackLib/ArmPlatformStackLib.inf