From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from linux.microsoft.com (linux.microsoft.com [13.77.154.182]) by mx.groups.io with SMTP id smtpd.web09.983.1613177902728859435 for ; Fri, 12 Feb 2021 16:58:22 -0800 Authentication-Results: mx.groups.io; dkim=fail reason="body hash did not verify" header.i=@linux.microsoft.com header.s=default header.b=MBEN6BPY; spf=pass (domain: linux.microsoft.com, ip: 13.77.154.182, mailfrom: mikuback@linux.microsoft.com) Received: from localhost.localdomain (unknown [131.107.174.202]) by linux.microsoft.com (Postfix) with ESMTPSA id E291520B6C40; Fri, 12 Feb 2021 16:58:21 -0800 (PST) DKIM-Filter: OpenDKIM Filter v2.11.0 linux.microsoft.com E291520B6C40 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.microsoft.com; s=default; t=1613177902; bh=47CLdbcslJbXbel/FgKaYRPyC+yFB+i4Ivu+9BgJ03Q=; h=From:To:Cc:Subject:Date:From; b=MBEN6BPYc9Rj/hgxxX+IZGG9n7575PJbHLxqIbSRqpOOpRJ2V2BlnyU/XbqH6MkjZ LqyHXgBDbOwjf13ZszgMceu6Q36S+4vKPME7dH1GYEFOpuVAqu9br6xs90eKvPmPf8 6si4ESArHQOGIsM7VEg8tFaNfgUq4DoErfR0Lptc= From: "Michael Kubacki" To: devel@edk2.groups.io Cc: Eric Dong , Ray Ni , Laszlo Ersek , Rahul Kumar Subject: [PATCH v2 0/4] UefiCpuPkg/StandaloneMmCpuFeaturesLib: Add Standalone MM support Date: Fri, 12 Feb 2021 16:58:02 -0800 Message-Id: <20210213005806.2927-1-mikuback@linux.microsoft.com> X-Mailer: git-send-email 2.28.0.windows.1 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable From: Michael Kubacki REF:https://bugzilla.tianocore.org/show_bug.cgi?id=3D3218 This patch series is v2 of the following v1 patch: https://edk2.groups.io/g/devel/message/71626 Due to some pre-existing design issues in the library that affected that patch, it was suggested to first address those issues and then add the new INF StandaloneMmCpuFeaturesLib.inf. The first two patches in this series primarily address those concerns. The present SmmCpuFeaturesLib implementation in UefiCpuPkg can be useful for IA32/X64 platforms that need a library instance for a Standalone MM environment. Much of the logic can be reused and a new INF can isolate the differences unique to Standalone MM. PATCH v2 1/4 and PATCH v2 2/4 focus on fixing pre-existing design issues. PATCH v2 3/4 and PATCH v2 4/4 focus on the changes needed to add Standalone MM support. Cc: Eric Dong Cc: Ray Ni Cc: Laszlo Ersek Cc: Rahul Kumar Signed-off-by: Michael Kubacki Michael Kubacki (4): UefiCpuPkg/SmmCpuFeaturesLib: Move multi-instance function decl to header UefiCpuPkg/SmmCpuFeaturesLib: Cleanup library constructors UefiCpuPkg/SmmCpuFeaturesLib: Abstract PcdCpuMaxLogicalProcessorNumber UefiCpuPkg/SmmCpuFeaturesLib: Add Standalone MM support UefiCpuPkg/Library/SmmCpuFeaturesLib/SmmCpuFeaturesLib.c = | 34 ++++--------- UefiCpuPkg/Library/SmmCpuFeaturesLib/SmmCpuFeaturesLibNoStm.c = | 25 +++++++++- UefiCpuPkg/Library/SmmCpuFeaturesLib/SmmStm.c = | 24 ++------- UefiCpuPkg/Library/SmmCpuFeaturesLib/StandaloneMmCpuFeaturesLib.c = | 51 ++++++++++++++++++++ UefiCpuPkg/Library/SmmCpuFeaturesLib/TraditionalMmCpuFeaturesLib.c = | 28 +++++++++++ UefiCpuPkg/Library/SmmCpuFeaturesLib/CpuFeaturesLib.h = | 48 ++++++++++++++++++ UefiCpuPkg/Library/SmmCpuFeaturesLib/SmmCpuFeaturesLib.inf = | 2 + UefiCpuPkg/Library/SmmCpuFeaturesLib/SmmCpuFeaturesLibStm.inf = | 2 + UefiCpuPkg/Library/SmmCpuFeaturesLib/{SmmCpuFeaturesLib.inf =3D> Standal= oneMmCpuFeaturesLib.inf} | 20 +++++--- UefiCpuPkg/UefiCpuPkg.dsc = | 1 + 10 files changed, 182 insertions(+), 53 deletions(-) create mode 100644 UefiCpuPkg/Library/SmmCpuFeaturesLib/StandaloneMmCpuF= eaturesLib.c create mode 100644 UefiCpuPkg/Library/SmmCpuFeaturesLib/TraditionalMmCpu= FeaturesLib.c create mode 100644 UefiCpuPkg/Library/SmmCpuFeaturesLib/CpuFeaturesLib.h copy UefiCpuPkg/Library/SmmCpuFeaturesLib/{SmmCpuFeaturesLib.inf =3D> St= andaloneMmCpuFeaturesLib.inf} (56%) --=20 2.28.0.windows.1