From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga18.intel.com (mga18.intel.com [134.134.136.126]) by mx.groups.io with SMTP id smtpd.web10.63049.1673235475386702032 for ; Sun, 08 Jan 2023 19:37:55 -0800 Authentication-Results: mx.groups.io; dkim=fail reason="unable to parse pub key" header.i=@intel.com header.s=intel header.b=VO4H3227; spf=pass (domain: intel.com, ip: 134.134.136.126, mailfrom: yuanhao.xie@intel.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1673235475; x=1704771475; h=from:to:subject:date:message-id:mime-version: content-transfer-encoding; bh=c/y8ybTyGLQ3f5+uK16T1mu0a2S93fHj0IjWqh+csXc=; b=VO4H3227B1F4TcYac6s0qMVDEmIJQ+A0wv2drSkdzU9wE9ri/OGCliSC UEKqCrZ32wgks4Wgl40GSDnUwPcGWD7llwN9lDym4C+Z26x1Chyfrsv8g m/5xDcRBLoCviYM9OfijXKco3wtUlvcYnfmGYs/TWUMR828EFy5lhUBx+ OKzQdmaoF7rk7IOpzwyHLc7SUVZyOLNVdKXo3JoybWVzUK17B+DUcP0mJ mXF4uMrqKasd+Fg18tD+tCTg9KjE57T4hFflirOKHovLtxRTZliLm8bV0 NXT+ofQSXTC5IqroIuRn4r4w8N2W4kPx5PUSltSPid4nXVKzK9T7Vl6fI A==; X-IronPort-AV: E=McAfee;i="6500,9779,10584"; a="306306763" X-IronPort-AV: E=Sophos;i="5.96,311,1665471600"; d="scan'208";a="306306763" Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by orsmga106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 08 Jan 2023 19:37:54 -0800 X-IronPort-AV: E=McAfee;i="6500,9779,10584"; a="764169978" X-IronPort-AV: E=Sophos;i="5.96,311,1665471600"; d="scan'208";a="764169978" Received: from shwdeopenlab705.ccr.corp.intel.com ([10.239.182.166]) by fmsmga002-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 08 Jan 2023 19:37:53 -0800 From: "Yuanhao Xie" To: devel@edk2.groups.io Subject: [PATCH 0/4] Revert the series of the patches which put APs in Date: Mon, 9 Jan 2023 11:37:20 +0800 Message-Id: <20230109033724.1130-1-yuanhao.xie@intel.com> X-Mailer: git-send-email 2.36.1.windows.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit This series of original patches requiring revert, redo and further cleanup. 4GB limitation of memory allocation will be kept for the case APs still need to be transferred to 32-bit mode before handoff to the OS. Stack offset for AsmRelocateApLoopStart in 32-bit mode needs to be fixed up, as it is calculated taking into account the removed parameters. The allocation size of the stack should be updated as the variant of APs loop function is introduced. Keep the logic that removes the XP attribute. Since the commit 73ccde8f6d04 introduced CpuPageTableLib dependency which resolved for OvmfPkg and UefiPayloadPkg, it follows the revert order shown as below instead of the reverse order of original commits to ensure the tree buildable at every stage of the revert: 73ccde8f6d04 UefiCpuPkg: Has APs in 64 bit long-mode before booting to OS. 3f378450dfaf UefiPayloadPkg: Add CpuPageTableLib required by MpInitLib. 4a8642422460 OvmfPkg: Add CpuPageTableLib required by MpInitLib. 7bda8c648192 UefiCpuPkg: Duplicated AsmRelocateApLoop as AsmRelocateApLoopAmd Yuanhao Xie (4): Revert "UefiCpuPkg: Has APs in 64 bit long-mode before booting to OS." Revert "UefiPayloadPkg: Add CpuPageTableLib required by MpInitLib." Revert "OvmfPkg: Add CpuPageTableLib required by MpInitLib." Revert "UefiCpuPkg: Duplicated AsmRelocateApLoop as AsmRelocateApLoopAmd" OvmfPkg/AmdSev/AmdSevX64.dsc | 3 +- OvmfPkg/CloudHv/CloudHvX64.dsc | 1 - OvmfPkg/IntelTdx/IntelTdxX64.dsc | 4 +- OvmfPkg/Microvm/MicrovmX64.dsc | 3 +- OvmfPkg/OvmfPkgIa32X64.dsc | 1 - OvmfPkg/OvmfPkgX64.dsc | 2 - OvmfPkg/OvmfXen.dsc | 3 +- UefiCpuPkg/Library/MpInitLib/DxeMpInitLib.inf | 7 +- UefiCpuPkg/Library/MpInitLib/DxeMpLib.c | 128 +++++++------ .../Library/MpInitLib/Ia32/CreatePageTable.c | 27 --- UefiCpuPkg/Library/MpInitLib/MpEqu.inc | 2 - UefiCpuPkg/Library/MpInitLib/MpLib.h | 46 +---- UefiCpuPkg/Library/MpInitLib/X64/AmdSev.nasm | 169 ----------------- .../Library/MpInitLib/X64/CreatePageTable.c | 75 -------- UefiCpuPkg/Library/MpInitLib/X64/MpFuncs.nasm | 176 ++++++++++++++---- UefiCpuPkg/UefiCpuPkg.dsc | 1 - UefiPayloadPkg/UefiPayloadPkg.dsc | 1 - 17 files changed, 220 insertions(+), 429 deletions(-) delete mode 100644 UefiCpuPkg/Library/MpInitLib/Ia32/CreatePageTable.c delete mode 100644 UefiCpuPkg/Library/MpInitLib/X64/CreatePageTable.c -- 2.36.1.windows.1