From patchwork Wed Nov 28 14:33:53 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Ard Biesheuvel X-Patchwork-Id: 152284 Delivered-To: patch@linaro.org Received: by 2002:a2e:299d:0:0:0:0:0 with SMTP id p29-v6csp1164817ljp; Wed, 28 Nov 2018 06:34:57 -0800 (PST) X-Google-Smtp-Source: AFSGD/UOdnD/GogL6mEVplTTP0iSkP95Sv3jG8/nvW3GncSPrUaoH54uGYJ8peJ2AneZfgChDvEi X-Received: by 2002:a17:902:690c:: with SMTP id j12mr1200501plk.206.1543415697579; Wed, 28 Nov 2018 06:34:57 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1543415697; cv=none; d=google.com; s=arc-20160816; b=phICfmRVpUHC1K1iiBLn4nh8GvmxPAXZAyNwD0ieVaAZQE/Cna+uca6FljQfBRh8ae ByGnwzFNkHRVHI7/VGk4bYfYBbMbeKioL6iNRjlpKCoqMSfTvsnOD8xKYVedimWg5Jpr o+fw5eHh9DwWRBNET9HMatxxjGxpFi0u4R/JYRVb9b4/exBApK7uoR2EWb195jaPzPfm 4qtDOxBoWQL0j3xpnSBcqjY+5Pm/t13dq87jX4ISY55waSUueNEnNHPnVrHIQ/AZpjGl /UBgqHM1jUTxKVNLP49B+0oBhxYsCJ2V1s1oM1Fw4ftca9yLvE0nCFCZDAT7/vwGhv0k iG/A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:cc:list-subscribe :list-help:list-post:list-archive:list-unsubscribe:list-id :precedence:subject:mime-version:references:in-reply-to:message-id :date:to:from:dkim-signature:delivered-to; bh=2yrJb1ywv28RrJZEDPoQaSpRKlS8Qtu1Ouo0u1wzUJ0=; b=ySbFq/5J4K0LWdrvDaxJSn7QrdmW1XVRq4mYtmo/Y/KAU4rFUDlqVQR5QwGdVw8LEL sqi2aSYw12L8oqnr9EZoWtdhh1NF4YuZKUNGQd+RvI5WWCNr0Hf7bQxL0w4XAfBnnEnw +QsVp0y/PQUy639W6Uu0lFOhelz/ygSZpwGKjDOZMT8+OMO5N8hFOoijJcD+iGVAwKC7 rq/fzSpRVVMtGDV8wHUAE2KkX+bc49aPWcdMryRQK5Q+mOzrMPjA517k8/txTMkmSLsl WOG3a1OmF9yPRqoE1Uhzxe7/F1B8+NmhpbU0+Pyt4MYsNB72MN507w9/azkVIbLB3obd fOjw== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=JLqluZJ+; spf=pass (google.com: best guess record for domain of edk2-devel-bounces@lists.01.org designates 2001:19d0:306:5::1 as permitted sender) smtp.mailfrom=edk2-devel-bounces@lists.01.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from ml01.01.org (ml01.01.org. [2001:19d0:306:5::1]) by mx.google.com with ESMTPS id q13si7111226pgj.86.2018.11.28.06.34.57 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 28 Nov 2018 06:34:57 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of edk2-devel-bounces@lists.01.org designates 2001:19d0:306:5::1 as permitted sender) client-ip=2001:19d0:306:5::1; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=JLqluZJ+; spf=pass (google.com: best guess record for domain of edk2-devel-bounces@lists.01.org designates 2001:19d0:306:5::1 as permitted sender) smtp.mailfrom=edk2-devel-bounces@lists.01.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id CDA1421196232; Wed, 28 Nov 2018 06:34:24 -0800 (PST) X-Original-To: edk2-devel@lists.01.org Delivered-To: edk2-devel@lists.01.org Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=2a00:1450:4864:20::343; helo=mail-wm1-x343.google.com; envelope-from=ard.biesheuvel@linaro.org; receiver=edk2-devel@lists.01.org Received: from mail-wm1-x343.google.com (mail-wm1-x343.google.com [IPv6:2a00:1450:4864:20::343]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 69FA221196226 for ; Wed, 28 Nov 2018 06:34:21 -0800 (PST) Received: by mail-wm1-x343.google.com with SMTP id n133so2811462wmd.4 for ; Wed, 28 Nov 2018 06:34:21 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=URUyurxf667iFbDXbP2kN6XPe58zIYvx3JM7hp6HbeI=; b=JLqluZJ+olvYIObBegeHmjIYt/NW9o84DIcMiUDd9fHA9pqu2kHPB/07y++bD1pOl0 7Hebp/ZlCXk5acs+cCVzAykbJ6X6t8rFZlGCK2q9Mh9MHTuoRq9vlmw6ZVeAyIve1v8C HyhLRwqfVZdVEzH+rlR4oL6dz0umk+PwTQd4o= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=URUyurxf667iFbDXbP2kN6XPe58zIYvx3JM7hp6HbeI=; b=R3+uFOkg7awlbvN30WGT68Z8FnYcprfZiLRW0y3LP8e3XjtXtjUuEWHW66tN73aRXr okooREgbN3NB5KX1+6tHc3ebsH613MNFycelFS9O2Y20wxiVS0GEaNzzNTGefG79pehV E+Qh4HhPmmqNPFMAV7Mjy1y0RRxLu6GXe66CDqiFRkgFA97fz3QdCEOroLvKvMJB7GZy 6vCR7Ic/Q+EQl+vZk+QEgUXhA5GVIzNcBvVuCqgCSk4FVWewWnTpBW7mBZ6GCw6R80HL j2OjgzsbQsanrt/VdoemH+7yvIkkkzge91B9kpS9/jIi0T3oJeLtpIN48cY/F74Uc7X8 Foyw== X-Gm-Message-State: AA+aEWaAlglxHzHRte3dSyQCsH4jyKGW7wPbz0AIPyop9rdfuna7RVYe m1P58gYOjQQv4VhvHh6BMTUJxc+H83Q= X-Received: by 2002:a7b:c5d1:: with SMTP id n17mr2972139wmk.152.1543415659695; Wed, 28 Nov 2018 06:34:19 -0800 (PST) Received: from harold.home ([2a01:cb1d:112:6f00:296f:238b:c20d:3626]) by smtp.gmail.com with ESMTPSA id 6sm3391891wmk.26.2018.11.28.06.34.18 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 28 Nov 2018 06:34:18 -0800 (PST) From: Ard Biesheuvel To: edk2-devel@lists.01.org Date: Wed, 28 Nov 2018 15:33:53 +0100 Message-Id: <20181128143357.991-13-ard.biesheuvel@linaro.org> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20181128143357.991-1-ard.biesheuvel@linaro.org> References: <20181128143357.991-1-ard.biesheuvel@linaro.org> MIME-Version: 1.0 Subject: [edk2] [PATCH v3 12/16] BeagleBoardPkg/PrePi: base GCD memory space size on CPU's PA range X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Andrew Jones , Laszlo Ersek Errors-To: edk2-devel-bounces@lists.01.org Sender: "edk2-devel" Derive the size of the GCD memory space map directly from the CPU's information registers rather than from the PcdPrePiCpuMemorySize PCD, which will be removed. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Ard Biesheuvel --- BeagleBoardPkg/PrePi/PeiUniCore.inf | 1 - BeagleBoardPkg/PrePi/PrePi.c | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) -- 2.19.1 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel Reviewed-by: Philippe Mathieu-Daudé Acked-by: Laszlo Ersek Reviewed-by: Leif Lindholm diff --git a/BeagleBoardPkg/PrePi/PeiUniCore.inf b/BeagleBoardPkg/PrePi/PeiUniCore.inf index 3d72bc5b46e1..53c71d8eafc2 100644 --- a/BeagleBoardPkg/PrePi/PeiUniCore.inf +++ b/BeagleBoardPkg/PrePi/PeiUniCore.inf @@ -86,7 +86,6 @@ [FixedPcd] gArmPlatformTokenSpaceGuid.PcdCoreCount - gEmbeddedTokenSpaceGuid.PcdPrePiCpuMemorySize gEmbeddedTokenSpaceGuid.PcdPrePiCpuIoSize gEmbeddedTokenSpaceGuid.PcdMemoryTypeEfiACPIReclaimMemory diff --git a/BeagleBoardPkg/PrePi/PrePi.c b/BeagleBoardPkg/PrePi/PrePi.c index 46f63f40c46e..bc9b0c80b84c 100644 --- a/BeagleBoardPkg/PrePi/PrePi.c +++ b/BeagleBoardPkg/PrePi/PrePi.c @@ -110,7 +110,7 @@ PrePiMain ( BuildStackHob (StacksBase, StacksSize); //TODO: Call CpuPei as a library - BuildCpuHob (PcdGet8 (PcdPrePiCpuMemorySize), PcdGet8 (PcdPrePiCpuIoSize)); + BuildCpuHob (ArmGetPhysicalAddressBits (), PcdGet8 (PcdPrePiCpuIoSize)); // Store timer value logged at the beginning of firmware image execution Performance.ResetEnd = GetTimeInNanoSecond (StartTimeStamp);