[edk2-devel] [edk2-staging/SmmCpuFeaturesLib_AMD][PATCH 0/4] Reconstruction on SmmCpuFeaturesLib

Chang, Abner via groups.io posted 4 patches 1 year, 7 months ago
Only 0 patches received!
There is a newer version of this series
.../SmmCpuFeaturesLib/SmmCpuFeaturesLib.inf   |   6 +-
.../SmmCpuFeaturesLibStm.inf                  |  20 +-
.../StandaloneMmCpuFeaturesLib.inf            |   4 +
.../SmmCpuFeaturesLib/CpuFeaturesLib.h        |   7 +
.../SmmCpuFeaturesLib/{ => X86}/SmmStm.h      |   0
.../SmmCpuFeaturesLibCommon.c                 | 392 +----------------
.../{ => X86}/Ia32/SmmStmSupport.c            |   0
.../X86/SmmCpuFeaturesLibIntel.c              | 404 ++++++++++++++++++
.../SmmCpuFeaturesLib/{ => X86}/SmmStm.c      |   3 -
.../{ => X86}/X64/SmmStmSupport.c             |   0
.../{ => X86}/Ia32/SmiEntry.nasm              |   0
.../{ => X86}/Ia32/SmiException.nasm          |   0
.../{ => X86}/X64/SmiEntry.nasm               |   0
.../{ => X86}/X64/SmiException.nasm           |   0
14 files changed, 434 insertions(+), 402 deletions(-)
rename UefiCpuPkg/Library/SmmCpuFeaturesLib/{ => X86}/SmmStm.h (100%)
rename UefiCpuPkg/Library/SmmCpuFeaturesLib/{ => X86}/Ia32/SmmStmSupport.c (100%)
create mode 100644 UefiCpuPkg/Library/SmmCpuFeaturesLib/X86/SmmCpuFeaturesLibIntel.c
rename UefiCpuPkg/Library/SmmCpuFeaturesLib/{ => X86}/SmmStm.c (96%)
rename UefiCpuPkg/Library/SmmCpuFeaturesLib/{ => X86}/X64/SmmStmSupport.c (100%)
rename UefiCpuPkg/Library/SmmCpuFeaturesLib/{ => X86}/Ia32/SmiEntry.nasm (100%)
rename UefiCpuPkg/Library/SmmCpuFeaturesLib/{ => X86}/Ia32/SmiException.nasm (100%)
rename UefiCpuPkg/Library/SmmCpuFeaturesLib/{ => X86}/X64/SmiEntry.nasm (100%)
rename UefiCpuPkg/Library/SmmCpuFeaturesLib/{ => X86}/X64/SmiException.nasm (100%)
[edk2-devel] [edk2-staging/SmmCpuFeaturesLib_AMD][PATCH 0/4] Reconstruction on SmmCpuFeaturesLib
Posted by Chang, Abner via groups.io 1 year, 7 months ago
From: Abner Chang <abner.chang@amd.com>

This is the reconstruction on SmmCpuFeaturesLib to accommodate AMD
implementation of SmmCpuFeaturesLib. A new folder \X86 under
SmmCpuFeaturesLib is created for X86 architecture, this gives
SmmCpuFeaturesLib a well folder structure for not only X86 but also
for other processor architectures.

There are two cases that can trigger the reconstruction on the
modules (not only SmmCpuFeaturesLib) under UefiCpuPkg,
1. Create the X86 folder to accommodate both Intel and AMD
   implementation, with this AMD implementation can leverage the
   modules design and source files.
2. Create the X86 folder for X86 architecture when the new processor
   architecture is added to the module and leverage the module design
   and source files. For example, the upcoming RISC-V and loongson
   processor architecture.

This patch set is also part of below BZ 3860:
https://bugzilla.tianocore.org/show_bug.cgi?id=3860

This reconstruction keeps all INF files as where those are,
which prevents the impacts on the existing platform DSC
that has the reference to SmmCpuFeaturesLib INF file.

This patch set is the preparation for AMD SmmCpuFeaturesLib
upstream. In the follow up pacthes, AMD will create a new INF file
SmmCpuFeaturesLibAmd.inf under \SmmCpuFeaturesLib and pull in the source
files that located under SmmCpuFeaturesLib\X86.

This reconstruction would be the sample for the follow up reconstruction
on UefiCpuPkg modules, if there is no objection from the UefiCpuPkg
maintainer and edk2 community.

Signed-off-by: Abner Chang <abner.chang@amd.com>
Cc: Abdul Lateef Attar <abdattar@amd.com>
Cc: Garrett Kirkendall <garrett.kirkendall@amd.com>
Cc: Paul Grimes <paul.grimes@amd.com>
Cc: Eric Dong <eric.dong@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Rahul Kumar <rahul1.kumar@intel.com>

Abner Chang (4):
  Add X86 folder
  Abstract arch dependent code
  Relocate STM files
  Clean up header file inclusion

 .../SmmCpuFeaturesLib/SmmCpuFeaturesLib.inf   |   6 +-
 .../SmmCpuFeaturesLibStm.inf                  |  20 +-
 .../StandaloneMmCpuFeaturesLib.inf            |   4 +
 .../SmmCpuFeaturesLib/CpuFeaturesLib.h        |   7 +
 .../SmmCpuFeaturesLib/{ => X86}/SmmStm.h      |   0
 .../SmmCpuFeaturesLibCommon.c                 | 392 +----------------
 .../{ => X86}/Ia32/SmmStmSupport.c            |   0
 .../X86/SmmCpuFeaturesLibIntel.c              | 404 ++++++++++++++++++
 .../SmmCpuFeaturesLib/{ => X86}/SmmStm.c      |   3 -
 .../{ => X86}/X64/SmmStmSupport.c             |   0
 .../{ => X86}/Ia32/SmiEntry.nasm              |   0
 .../{ => X86}/Ia32/SmiException.nasm          |   0
 .../{ => X86}/X64/SmiEntry.nasm               |   0
 .../{ => X86}/X64/SmiException.nasm           |   0
 14 files changed, 434 insertions(+), 402 deletions(-)
 rename UefiCpuPkg/Library/SmmCpuFeaturesLib/{ => X86}/SmmStm.h (100%)
 rename UefiCpuPkg/Library/SmmCpuFeaturesLib/{ => X86}/Ia32/SmmStmSupport.c (100%)
 create mode 100644 UefiCpuPkg/Library/SmmCpuFeaturesLib/X86/SmmCpuFeaturesLibIntel.c
 rename UefiCpuPkg/Library/SmmCpuFeaturesLib/{ => X86}/SmmStm.c (96%)
 rename UefiCpuPkg/Library/SmmCpuFeaturesLib/{ => X86}/X64/SmmStmSupport.c (100%)
 rename UefiCpuPkg/Library/SmmCpuFeaturesLib/{ => X86}/Ia32/SmiEntry.nasm (100%)
 rename UefiCpuPkg/Library/SmmCpuFeaturesLib/{ => X86}/Ia32/SmiException.nasm (100%)
 rename UefiCpuPkg/Library/SmmCpuFeaturesLib/{ => X86}/X64/SmiEntry.nasm (100%)
 rename UefiCpuPkg/Library/SmmCpuFeaturesLib/{ => X86}/X64/SmiException.nasm (100%)

-- 
2.37.1.windows.1



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#93708): https://edk2.groups.io/g/devel/message/93708
Mute This Topic: https://groups.io/mt/93651470/1787277
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org]
-=-=-=-=-=-=-=-=-=-=-=-