From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by mx.groups.io with SMTP id smtpd.web11.5761.1666171362502456752 for ; Wed, 19 Oct 2022 02:22:42 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=VRvhP/Gd; spf=pass (domain: kernel.org, ip: 145.40.68.75, mailfrom: ardb@kernel.org) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 04F08B82465; Wed, 19 Oct 2022 09:22:41 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 5EB00C43470; Wed, 19 Oct 2022 09:22:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1666171359; bh=544RKwrbisFQNaa86z0PKt1yl1R0+eAtySOhWzD41NI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=VRvhP/GdoAuM52GRlngkgGMSJ+YG7y+ZfU7cg1ztR5UbXQJEC+v0lyTMeZw59xtYL gwAitPWxEwrzsp9y/SzLYB36LbiRvMvtoArczWnrWJOSgxXqIPX+Rh4EePHeaVGloa bK7vuNJAjv4bcCB/u6Ngl0Q0fYELiTboq8z/p0SlyoVUkozZHbYfHYNwUdK/CqcAFe NejlfdanrHqdhpvgVcY3bkZGkkfDl2HXgZxAL8uDUHdJA7Q3NpEfPdMH7APlUzQMC/ yjsJRWvd/MQgWvyghQFonjAEEPQBxxeuqMfCSgZzUkPJHCEsTVPbw2/8aIPzcBBlGO z4XHIuqpWoYQQ== From: "Ard Biesheuvel" To: devel@edk2.groups.io Cc: Ard Biesheuvel , Leif Lindholm , Alexander Graf , Gerd Hoffmann , Sami Mujawar Subject: [PATCH v3 resend 09/11] ArmVirtPkg/ArmVirtQemu: avoid shadowing PEIMs unless necessary Date: Wed, 19 Oct 2022 11:22:09 +0200 Message-Id: <20221019092211.465699-10-ardb@kernel.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20221019092211.465699-1-ardb@kernel.org> References: <20221019092211.465699-1-ardb@kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Some PEIMs register for shadow execution explicitly, but others exist that don't care and can happily execute in place. Since the emulated NOR flash is just RAM, shadowing has no performance benefits so let's only do this if needed. Signed-off-by: Ard Biesheuvel --- ArmVirtPkg/ArmVirtQemu.dsc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ArmVirtPkg/ArmVirtQemu.dsc b/ArmVirtPkg/ArmVirtQemu.dsc index de34481673ea..c3d264077bce 100644 --- a/ArmVirtPkg/ArmVirtQemu.dsc +++ b/ArmVirtPkg/ArmVirtQemu.dsc @@ -217,6 +217,9 @@ [PcdsFixedAtBuild.common] gEfiMdePkgTokenSpaceGuid.PcdReportStatusCodePropertyMask|3=0D gEfiShellPkgTokenSpaceGuid.PcdShellFileOperationSize|0x20000=0D =0D + # Shadowing PEI modules is absolutely pointless when the NOR flash is em= ulated=0D + gEfiMdeModulePkgTokenSpaceGuid.PcdShadowPeimOnBoot|FALSE=0D +=0D [PcdsFixedAtBuild.AARCH64]=0D # Clearing BIT0 in this PCD prevents installing a 32-bit SMBIOS entry po= int,=0D # if the entry point version is >=3D 3.0. AARCH64 OSes cannot assume the= =0D --=20 2.35.1