From patchwork Tue Feb 24 18:02:43 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ard Biesheuvel X-Patchwork-Id: 44970 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-la0-f72.google.com (mail-la0-f72.google.com [209.85.215.72]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id F1AC22029F for ; Tue, 24 Feb 2015 18:06:04 +0000 (UTC) Received: by lams18 with SMTP id s18sf18388143lam.1 for ; Tue, 24 Feb 2015 10:06:03 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:from:to:date:message-id:in-reply-to :references:cc:subject:precedence:list-id:list-unsubscribe:list-post :list-help:list-subscribe:mime-version:content-type :content-transfer-encoding:sender:errors-to:x-original-sender :x-original-authentication-results:mailing-list:list-archive; bh=gmNkR60WWgr4fV0ykEr5BIxJ9cSQtTz1CWBePGxXqjA=; b=Hh7mElvVcdMiSnXl8+ZRM7pFQG+L5io+h/uziuUCguRyXXxZTWTZjekPHtV7JNgTgo csrfAgAJfO8eDHn0xVbcq4Lq7QVoq7h3V3/AJd1QTG3/QMggewWZsUm+6fqRJRYhXxat SufoquJXTobKk8jmhl8ub6mpnst9qhpvDHlgOgxD72/ikmCNObXtndbl2uSwzyvZpaEo yus0E5OWOhjPTP9iMbmPaL5bCmNYno/9gnurZK+4VGURPYXSDOCn9MbtpAXk0beSV31l zyjPxtsCPyt3EE/VBOrRpUh7fe830HkMeQBZt+olLCka95Ym2VPxejwMEC/da2TdnBPa v6lA== X-Gm-Message-State: ALoCoQms28WERRMjcwlWYLLgd02yEhKgb2ZbgzwjSAsFZgwh9Q1PurVpgJEU5VU/coY0TguhoKZg X-Received: by 10.152.6.41 with SMTP id x9mr1282742lax.10.1424801163879; Tue, 24 Feb 2015 10:06:03 -0800 (PST) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.36.65 with SMTP id o1ls238378laj.67.gmail; Tue, 24 Feb 2015 10:06:03 -0800 (PST) X-Received: by 10.152.206.7 with SMTP id lk7mr4691248lac.37.1424801163729; Tue, 24 Feb 2015 10:06:03 -0800 (PST) Received: from mail-lb0-f172.google.com (mail-lb0-f172.google.com. [209.85.217.172]) by mx.google.com with ESMTPS id o7si27201571lag.165.2015.02.24.10.06.03 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 24 Feb 2015 10:06:03 -0800 (PST) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.172 as permitted sender) client-ip=209.85.217.172; Received: by lbiz12 with SMTP id z12so26480967lbi.11 for ; Tue, 24 Feb 2015 10:06:03 -0800 (PST) X-Received: by 10.112.118.211 with SMTP id ko19mr15538690lbb.19.1424801163644; Tue, 24 Feb 2015 10:06:03 -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.35.133 with SMTP id h5csp2078946lbj; Tue, 24 Feb 2015 10:06:02 -0800 (PST) X-Received: by 10.236.199.71 with SMTP id w47mr15478344yhn.171.1424801158062; Tue, 24 Feb 2015 10:05:58 -0800 (PST) Received: from lists.xen.org (lists.xen.org. [50.57.142.19]) by mx.google.com with ESMTPS id c18si17125863qaq.47.2015.02.24.10.05.57 (version=TLSv1 cipher=RC4-SHA bits=128/128); Tue, 24 Feb 2015 10:05:58 -0800 (PST) Received-SPF: none (google.com: xen-devel-bounces@lists.xen.org does not designate permitted sender hosts) client-ip=50.57.142.19; Received: from localhost ([127.0.0.1] helo=lists.xen.org) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1YQJqB-0001WK-8s; Tue, 24 Feb 2015 18:04:15 +0000 Received: from mail6.bemta4.messagelabs.com ([85.158.143.247]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1YQJq9-0001VR-QV for xen-devel@lists.xen.org; Tue, 24 Feb 2015 18:04:14 +0000 Received: from [85.158.143.35] by server-3.bemta-4.messagelabs.com id 9A/04-02791-D1DBCE45; Tue, 24 Feb 2015 18:04:13 +0000 X-Env-Sender: ard.biesheuvel@linaro.org X-Msg-Ref: server-16.tower-21.messagelabs.com!1424801052!9430418!1 X-Originating-IP: [74.125.82.48] X-SpamReason: No, hits=0.5 required=7.0 tests=BODY_RANDOM_LONG X-StarScan-Received: X-StarScan-Version: 6.13.4; banners=-,-,- X-VirusChecked: Checked Received: (qmail 14498 invoked from network); 24 Feb 2015 18:04:12 -0000 Received: from mail-wg0-f48.google.com (HELO mail-wg0-f48.google.com) (74.125.82.48) by server-16.tower-21.messagelabs.com with RC4-SHA encrypted SMTP; 24 Feb 2015 18:04:12 -0000 Received: by wggx12 with SMTP id x12so6998912wgg.6 for ; Tue, 24 Feb 2015 10:04:12 -0800 (PST) X-Received: by 10.180.96.168 with SMTP id dt8mr32996467wib.82.1424801052121; Tue, 24 Feb 2015 10:04:12 -0800 (PST) Received: from ards-macbook-pro.lan (bl11-65-113.dsl.telepac.pt. [85.244.65.113]) by mx.google.com with ESMTPSA id w8sm12792521wja.4.2015.02.24.10.04.08 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 24 Feb 2015 10:04:10 -0800 (PST) From: Ard Biesheuvel To: edk2-devel@lists.sourceforge.net, olivier.martin@arm.com, lersek@redhat.com, roy.franz@linaro.org, leif.lindholm@linaro.org, stefano.stabellini@eu.citrix.com, ian.campbell@citrix.com, anthony.perard@citrix.com, xen-devel@lists.xen.org, julien.grall@linaro.org, jordan.l.justen@intel.com, michael.d.kinney@intel.com Date: Tue, 24 Feb 2015 18:02:43 +0000 Message-Id: <1424800990-15777-3-git-send-email-ard.biesheuvel@linaro.org> X-Mailer: git-send-email 1.8.3.2 In-Reply-To: <1424800990-15777-1-git-send-email-ard.biesheuvel@linaro.org> References: <1424800990-15777-1-git-send-email-ard.biesheuvel@linaro.org> Cc: wei.liu2@citrix.com, Ard Biesheuvel Subject: [Xen-devel] [PATCH v5 02/29] ArmPkg: allow patchable PCDs for memory, FD and FV addresses X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Post: , List-Help: , List-Subscribe: , MIME-Version: 1.0 Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: ard.biesheuvel@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.172 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-Archive: In order to allow a runtime self relocating PrePi instance, change the allowable PCD types for the following PCDs: gArmTokenSpaceGuid.PcdSystemMemoryBase gArmTokenSpaceGuid.PcdSystemMemorySize gArmTokenSpaceGuid.PcdFdBaseAddress gArmTokenSpaceGuid.PcdFvBaseAddress to include PcdsPatchableInModule. This makes the build system correctly distinguish fixed PCDs from PCDs whose value may be different from the assigned value at compile time. Note that this only affects platforms that explicitly mark these PCDs as PatchableInModule in the DSC. All existing platforms that use FixedPcd will not be affected by this change. Contributed-under: TianoCore Contribution Agreement 1.0 Acked-by: Laszlo Ersek Reviewed-by: Olivier Martin Signed-off-by: Ard Biesheuvel --- ArmPkg/ArmPkg.dec | 25 ++++++++++++++----------- 1 file changed, 14 insertions(+), 11 deletions(-) diff --git a/ArmPkg/ArmPkg.dec b/ArmPkg/ArmPkg.dec index ced392980102..87dbd11b867f 100644 --- a/ArmPkg/ArmPkg.dec +++ b/ArmPkg/ArmPkg.dec @@ -96,14 +96,6 @@ gArmTokenSpaceGuid.PcdSecureFvSize|0x0|UINT32|0x00000030 # - # ARM Normal (or Non Secure) Firmware PCDs - # - gArmTokenSpaceGuid.PcdFdBaseAddress|0|UINT64|0x0000002B - gArmTokenSpaceGuid.PcdFdSize|0|UINT32|0x0000002C - gArmTokenSpaceGuid.PcdFvBaseAddress|0|UINT64|0x0000002D - gArmTokenSpaceGuid.PcdFvSize|0|UINT32|0x0000002E - - # # ARM Hypervisor Firmware PCDs # gArmTokenSpaceGuid.PcdHypFdBaseAddress|0|UINT32|0x0000003A @@ -130,6 +122,15 @@ # Maximum file size for TFTP servers that do not support 'tsize' extension gArmTokenSpaceGuid.PcdMaxTftpFileSize|0x01000000|UINT32|0x00000000 + # + # ARM Normal (or Non Secure) Firmware PCDs + # + gArmTokenSpaceGuid.PcdFdSize|0|UINT32|0x0000002C + gArmTokenSpaceGuid.PcdFvSize|0|UINT32|0x0000002E + +[PcdsFixedAtBuild.common, PcdsPatchableInModule.common] + gArmTokenSpaceGuid.PcdFdBaseAddress|0|UINT64|0x0000002B + gArmTokenSpaceGuid.PcdFvBaseAddress|0|UINT64|0x0000002D [PcdsFixedAtBuild.ARM] # @@ -210,16 +211,18 @@ # -# These PCDs are also defined as 'PcdsDynamic' to be redefined when using UEFI in a -# context of virtual machine. +# These PCDs are also defined as 'PcdsDynamic' or 'PcdsPatchableInModule' to be +# redefined when using UEFI in a context of virtual machine. # -[PcdsFixedAtBuild.common, PcdsDynamic.common] +[PcdsFixedAtBuild.common, PcdsDynamic.common, PcdsPatchableInModule.common] + # System Memory (DRAM): These PCDs define the region of in-built system memory # Some platforms can get DRAM extensions, these additional regions will be declared # to UEFI by ArmPlatformLib gArmTokenSpaceGuid.PcdSystemMemoryBase|0|UINT64|0x00000029 gArmTokenSpaceGuid.PcdSystemMemorySize|0|UINT64|0x0000002A +[PcdsFixedAtBuild.common, PcdsDynamic.common] # # ARM Architectural Timer #