From nobody Fri Oct 18 08:31:23 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) client-ip=66.175.222.108; envelope-from=bounce+27952+101926+1787277+3901457@groups.io; helo=mail02.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+101926+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=kernel.org ARC-Seal: i=1; a=rsa-sha256; t=1679914902; cv=none; d=zohomail.com; s=zohoarc; b=X8b37ADSW9HB1kaG6EtNYBsA7BvXTS9CxY9E6M1xX/GrQ6N0Rm/rgh1xq18wFLEVZM/k9EgV5c8rsmxplr65HVbZBVCUsN7d4OVzp7q+GYCvEbT4uD0srAylqFcKG7DKLxbZQeE/z4TPtmojq5Jgk2o14ol/68g+AtB4q1nBHb4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1679914902; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=iR3wUS2LuzXESlgM/feeYDND87rZwrxgtIp1QOyuiLg=; b=MPOGGT4nCISU/hZqn+Wj+YxQzpNiXXl0wNHE5xj0I0Fs2Kj16jtoyhZmf7wjj6nKCScGVeEKl7gaPf8qcGCOqmY/o2dMTMf2myp5SdnNpEOs4teBXQN/XbJfVU1toRDvV3rx+cveM3/rENHJVU+4+sFZHSbK4iA9H9GJPOrhJXk= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+101926+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by mx.zohomail.com with SMTPS id 1679914902819990.3534866834101; Mon, 27 Mar 2023 04:01:42 -0700 (PDT) Return-Path: X-Received: by 127.0.0.2 with SMTP id yTrUYY1788612xwIZtqsrnWH; Mon, 27 Mar 2023 04:01:42 -0700 X-Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by mx.groups.io with SMTP id smtpd.web11.32009.1679914901399619742 for ; Mon, 27 Mar 2023 04:01:41 -0700 X-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 2F728B80DA9; Mon, 27 Mar 2023 11:01:39 +0000 (UTC) X-Received: by smtp.kernel.org (Postfix) with ESMTPSA id 67FC0C433A4; Mon, 27 Mar 2023 11:01:35 +0000 (UTC) From: "Ard Biesheuvel" To: devel@edk2.groups.io Cc: Ard Biesheuvel , Michael Kinney , Liming Gao , Jiewen Yao , Michael Kubacki , Sean Brogan , Rebecca Cran , Leif Lindholm , Sami Mujawar , Taylor Beebe , =?UTF-8?q?Marvin=20H=C3=A4user?= , Bob Feng Subject: [edk2-devel] [PATCH v2 02/17] MdePkg/BaseCpuLib AARCH64: Make asm files BTI compatible Date: Mon, 27 Mar 2023 13:00:57 +0200 Message-Id: <20230327110112.262503-3-ardb@kernel.org> In-Reply-To: <20230327110112.262503-1-ardb@kernel.org> References: <20230327110112.262503-1-ardb@kernel.org> MIME-Version: 1.0 Precedence: Bulk List-Unsubscribe: List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,ardb@kernel.org X-Gm-Message-State: 8eROA2NqmQHW1dBVdo5DlC26x1787277AA= Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1679914902; bh=8FR4hsLOi4vnU/G92mYtB9X877i/AL8rmbIhN7i6W0c=; h=Cc:Date:From:Reply-To:Subject:To; b=kqNBr+lU28gOBoQKFjcWBLy+xTLE+QY6RCL11pc4+6T/Wm8FK8Ri9XF8vS6deDGEmfK nbfr7AoennsntEAlK/PqaEM1Q6/pL5QEsYH9fOY7fk/IlPbgnfWaPx8MdswiNSyR/meX9 MyiBotB3mekmhVbWZ35vobeW3UTuyzBNOy8= X-ZohoMail-DKIM: pass (identity @groups.io) X-ZM-MESSAGEID: 1679914903154100002 Content-Type: text/plain; charset="utf-8" Add the BTI instructions and the associated note to make the AArch64 asm objects compatible with BTI enforcement. Signed-off-by: Ard Biesheuvel --- MdePkg/Library/BaseCpuLib/AArch64/CpuFlushTlb.S | 1 + MdePkg/Library/BaseCpuLib/AArch64/CpuSleep.S | 1 + 2 files changed, 2 insertions(+) diff --git a/MdePkg/Library/BaseCpuLib/AArch64/CpuFlushTlb.S b/MdePkg/Libra= ry/BaseCpuLib/AArch64/CpuFlushTlb.S index 82a7232268f59809..12c2421b6d327a7b 100644 --- a/MdePkg/Library/BaseCpuLib/AArch64/CpuFlushTlb.S +++ b/MdePkg/Library/BaseCpuLib/AArch64/CpuFlushTlb.S @@ -26,6 +26,7 @@ GCC_ASM_EXPORT(CpuFlushTlb) # )# # ASM_PFX(CpuFlushTlb): + AARCH64_BTI(c) tlbi vmalle1 // Invalidate Inst TLB and Data TLB dsb sy isb diff --git a/MdePkg/Library/BaseCpuLib/AArch64/CpuSleep.S b/MdePkg/Library/= BaseCpuLib/AArch64/CpuSleep.S index 410a271565edfb68..6853e0c56e0bb135 100644 --- a/MdePkg/Library/BaseCpuLib/AArch64/CpuSleep.S +++ b/MdePkg/Library/BaseCpuLib/AArch64/CpuSleep.S @@ -29,5 +29,6 @@ GCC_ASM_EXPORT(CpuSleep) # =20 ASM_PFX(CpuSleep): + AARCH64_BTI(c) wfi ret --=20 2.39.2 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#101926): https://edk2.groups.io/g/devel/message/101926 Mute This Topic: https://groups.io/mt/97879283/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-