From nobody Sun Feb 8 17:13:00 2026 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+87710+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+87710+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=intel.com ARC-Seal: i=1; a=rsa-sha256; t=1647564505; cv=none; d=zohomail.com; s=zohoarc; b=GcZCwYTjFhWeTgiaiLh8rGSEkc9pkBmKUWecphwRKY3Hyxn67D2vQscYnyQ6C+1BiRJuEP7Az/pxAbOkmI7SpyTvk/3WY7u1fyLgieDn7UfOPl/xsfo9pvqh6dfLRYOHuSW083GsLsilxcKQq1UQ8kApeHoWSNu0lSp6712tD8w= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1647564505; 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=gfxfUl0HR2T+P6g1QadyeTjU6wgvY/mGrMDdjuBm0kw=; b=K/Ku/TqCrG6WO/N6SSXNVm26zU3hDdju3KPThsgu6yelzJP1ZdjeBszppAAi0xb1TeQXuiijMjNHebaLaQ12T4mwnSf1uYYfi/O+Mfax940vVDLQ8sv0Oq+6prx3f/3A8Bk8j/QkOWMcEVvjbVoWfZOzP3k4cyutCrd+QBq/GkA= 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+87710+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 1647564505062736.4707096386492; Thu, 17 Mar 2022 17:48:25 -0700 (PDT) Return-Path: X-Received: by 127.0.0.2 with SMTP id 5XYXYY1788612xOmvoo1vE04; Thu, 17 Mar 2022 17:48:24 -0700 X-Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by mx.groups.io with SMTP id smtpd.web10.4356.1647564500124120641 for ; Thu, 17 Mar 2022 17:48:22 -0700 X-IronPort-AV: E=McAfee;i="6200,9189,10289"; a="281818422" X-IronPort-AV: E=Sophos;i="5.90,190,1643702400"; d="scan'208";a="281818422" X-Received: from orsmga007.jf.intel.com ([10.7.209.58]) by fmsmga101.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 17 Mar 2022 17:48:12 -0700 X-IronPort-AV: E=Sophos;i="5.90,190,1643702400"; d="scan'208";a="541603265" X-Received: from mxu9-mobl1.ccr.corp.intel.com ([10.249.172.84]) by orsmga007-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 17 Mar 2022 17:48:09 -0700 From: "Min Xu" To: devel@edk2.groups.io Cc: Min Xu , Jian J Wang , Hao A Wu , Brijesh Singh , Erdem Aktas , James Bottomley , Jiewen Yao , Tom Lendacky , Gerd Hoffmann Subject: [edk2-devel] [PATCH V9 35/47] MdeModulePkg: Skip setting IA32_ERER.NXE if it has already been set Date: Fri, 18 Mar 2022 08:45:53 +0800 Message-Id: In-Reply-To: References: 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,min.m.xu@intel.com X-Gm-Message-State: XnGKROZzyD5n2PAbIRenRvWUx1787277AA= Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1647564504; bh=7QWDE2ONEHMLZG2GW50i0USlaemd67sKPxKIAFsKrVc=; h=Cc:Date:From:Reply-To:Subject:To; b=HXbvl1chUjvbEBf+kpW5/O/Je4jvTX26/bXoUDOD2QAqINBSqFF/iqLdgGhN9/ICscx 1A4r1oJebkWS9kieAMs2t6N+WD+oYobpgkAUD+Q+8SnccYE3yerwQ1yv8i2tY/KWVb7J7 JpOwhZFIv55gx9k6uYYT8CizY+uNUhVbmaU= X-ZohoMail-DKIM: pass (identity @groups.io) X-ZM-MESSAGEID: 1647564506207100014 Content-Type: text/plain; charset="utf-8" RFC: https://bugzilla.tianocore.org/show_bug.cgi?id=3D3429 If IA32_ERER.NXE has already been set, skip setting it again. Cc: Jian J Wang Cc: Hao A Wu Cc: Brijesh Singh Cc: Erdem Aktas Cc: James Bottomley Cc: Jiewen Yao Cc: Tom Lendacky Cc: Gerd Hoffmann Acked-by: Gerd Hoffmann Reviewed-by: Jian J Wang Signed-off-by: Min Xu Reviewed-by: Ray Ni --- MdeModulePkg/Core/DxeIplPeim/X64/VirtualMemory.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/MdeModulePkg/Core/DxeIplPeim/X64/VirtualMemory.c b/MdeModulePk= g/Core/DxeIplPeim/X64/VirtualMemory.c index 1ebab2782010..a451ca160408 100644 --- a/MdeModulePkg/Core/DxeIplPeim/X64/VirtualMemory.c +++ b/MdeModulePkg/Core/DxeIplPeim/X64/VirtualMemory.c @@ -179,9 +179,11 @@ EnableExecuteDisableBit ( { UINT64 MsrRegisters; =20 - MsrRegisters =3D AsmReadMsr64 (0xC0000080); - MsrRegisters |=3D BIT11; - AsmWriteMsr64 (0xC0000080, MsrRegisters); + MsrRegisters =3D AsmReadMsr64 (0xC0000080); + if ((MsrRegisters & BIT11) =3D=3D 0) { + MsrRegisters |=3D BIT11; + AsmWriteMsr64 (0xC0000080, MsrRegisters); + } } =20 /** --=20 2.29.2.windows.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 (#87710): https://edk2.groups.io/g/devel/message/87710 Mute This Topic: https://groups.io/mt/89859052/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-