From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wr0-x22c.google.com (mail-wr0-x22c.google.com [IPv6:2a00:1450:400c:c0c::22c]) (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 89A2E821DE for ; Wed, 1 Mar 2017 06:42:37 -0800 (PST) Received: by mail-wr0-x22c.google.com with SMTP id u108so31701775wrb.3 for ; Wed, 01 Mar 2017 06:42:37 -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; bh=cqStoyENYTEJuv/Y9/D43ASXpL7uT1U1bxskZLitEhk=; b=V0wzhk/G3RQmmNGqIGdvqyrmqkjTXoj3NGxwezW/ku1jygGO22vaiyLbl4OI56hyjr zqtDAiVhvEoNSvvPsBSJfFW35A03i6pQAWD1MpsNZPzDZxeAp6rD8DydF3kgzPkLIzLK ZQRGjTNYKKFEqz7kuE8HWcabaLDDtqRmSfFKc= 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; bh=cqStoyENYTEJuv/Y9/D43ASXpL7uT1U1bxskZLitEhk=; b=MFnanUx5zIqMxTz1R8eCzqmGidNMvBI428Z6XUzC0p8ys1kF1KxyYtW2TGwvnwL+I5 JhXQ/WIEM1k6YuyIvscHlK/S6akjZ+2SSrBszdaQChuJn5ohvqpzLNA1C8HPqUIF33AK dAuA6RaNBly0k95txegOXVGQFE3FXkejtldkdjAidg7KYjoSeO0jRqDC7jQ9bPzbKbOr D/WbrY9bnMFehEKMXcz7zGC5FFvX2CFZkyTcKijtXrGvKVLqnX7rPTiT9KnpaDJcCRAM eXkOdrpmXD5cZU3VF5ksJ2dOkSupC5+vK6te0GQVGaxNUaRhFoxQxlVIWbcGsgYiKLJT Kdtw== X-Gm-Message-State: AMke39lqTsM9vsEvc+0jLc95TWPb6/oWS4dAvkMe09oYWu13/PAmZz2BPekl+zxpHE09gOc2 X-Received: by 10.223.142.201 with SMTP id q67mr7051333wrb.182.1488379355800; Wed, 01 Mar 2017 06:42:35 -0800 (PST) Received: from localhost.localdomain ([105.147.1.203]) by smtp.gmail.com with ESMTPSA id h75sm6867958wrh.37.2017.03.01.06.42.34 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 01 Mar 2017 06:42:35 -0800 (PST) From: Ard Biesheuvel To: edk2-devel@lists.01.org, leif.lindholm@linaro.org, lersek@redhat.com Cc: Ard Biesheuvel Date: Wed, 1 Mar 2017 14:42:24 +0000 Message-Id: <1488379344-16273-5-git-send-email-ard.biesheuvel@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1488379344-16273-1-git-send-email-ard.biesheuvel@linaro.org> References: <1488379344-16273-1-git-send-email-ard.biesheuvel@linaro.org> Subject: [PATCH 4/4] ArmVirtPkg: enable PE/COFF image and memory protection for ARM platforms X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 01 Mar 2017 14:42:37 -0000 Like for AARCH64, enable PE/COFF image and NX memory protection for all 32-bit ARM virt platforms. Note that this does not [yet] protect EfiLoaderData regions, due to compatibility issues with GRUB. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel --- ArmVirtPkg/ArmVirt.dsc.inc | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/ArmVirtPkg/ArmVirt.dsc.inc b/ArmVirtPkg/ArmVirt.dsc.inc index a91b27f13cf2..acfb71d3ff6c 100644 --- a/ArmVirtPkg/ArmVirt.dsc.inc +++ b/ArmVirtPkg/ArmVirt.dsc.inc @@ -18,7 +18,7 @@ [Defines] DEFINE TTY_TERMINAL = FALSE [BuildOptions.common.EDKII.DXE_DRIVER,BuildOptions.common.EDKII.UEFI_DRIVER,BuildOptions.common.EDKII.UEFI_APPLICATION] - GCC:*_*_AARCH64_DLINK_FLAGS = -z common-page-size=0x1000 + GCC:*_*_*_DLINK_FLAGS = -z common-page-size=0x1000 [BuildOptions.common.EDKII.DXE_RUNTIME_DRIVER] GCC:*_*_ARM_DLINK_FLAGS = -z common-page-size=0x1000 @@ -373,10 +373,6 @@ [PcdsFixedAtBuild.common] gArmVirtTokenSpaceGuid.PcdTerminalTypeGuidBuffer|{0x80, 0x6d, 0x91, 0x7d, 0xb1, 0x5b, 0x8c, 0x45, 0xa4, 0x8f, 0xe2, 0x5f, 0xdd, 0x51, 0xef, 0x94} !endif -[PcdsFixedAtBuild.ARM] - gEmbeddedTokenSpaceGuid.PcdPrePiCpuMemorySize|40 - -[PcdsFixedAtBuild.AARCH64] # # Enable strict image permissions for all images. (This applies # only to images that were built with >= 4 KB section alignment.) @@ -390,6 +386,9 @@ [PcdsFixedAtBuild.AARCH64] # gEfiMdeModulePkgTokenSpaceGuid.PcdDxeNxMemoryProtectionPolicy|0xC000000000007FD1 +[PcdsFixedAtBuild.ARM] + gEmbeddedTokenSpaceGuid.PcdPrePiCpuMemorySize|40 + [Components.common] # # Networking stack -- 2.7.4