<feed xmlns='http://www.w3.org/2005/Atom'>
<title>Tianocore/edk2.git/UefiCpuPkg/Library/SmmRelocationLib, branch master</title>
<subtitle>EDK II (mirror)</subtitle>
<id>https://git.radix-linux.su/Tianocore/edk2.git/atom?h=master</id>
<link rel='self' href='https://git.radix-linux.su/Tianocore/edk2.git/atom?h=master'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/'/>
<updated>2026-03-07T03:58:40+00:00</updated>
<entry>
<title>UefiCpuPkg: Set up 256 IDT Descs in SEC/PEI/SMM</title>
<updated>2026-03-07T03:58:40+00:00</updated>
<author>
<name>Oliver Smith-Denny</name>
<email>osde@microsoft.com</email>
</author>
<published>2026-02-20T20:48:56+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=3454d7ab417b3dcfa2b631a56b72833477bc8e6b'/>
<id>urn:sha1:3454d7ab417b3dcfa2b631a56b72833477bc8e6b</id>
<content type='text'>
Currently, SEC, PEI, and SMM only set up 32 - 34 IDT
descs. This means that any exceptions received above
that number will cause a #GP fault.

This commit updates these environments to follow DXE
and set up the IDT with the architecturally defined
256 entries, each of which point to the common
exception handler.

This does two things:
- Has well defined behavior for receiving exceptions in
  these environments instead of relying on a #GP fault to
  occur.
- Allows the stack cookie interrupt (0x42) to be routed
  correctly instead of appearing as a #GP fault.

Signed-off-by: Oliver Smith-Denny &lt;osde@microsoft.com&gt;
</content>
</entry>
<entry>
<title>UefiCpuPkg: Replace include guards with #pragma once</title>
<updated>2026-02-23T21:01:28+00:00</updated>
<author>
<name>Michael Kubacki</name>
<email>michael.kubacki@microsoft.com</email>
</author>
<published>2026-02-03T19:32:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=2ff7f990d162894d03f7c1f82ddc2bd4b27e0e3e'/>
<id>urn:sha1:2ff7f990d162894d03f7c1f82ddc2bd4b27e0e3e</id>
<content type='text'>
Replace traditional `#ifndef`/`#define`/`#endif` include guards with
`#pragma` once.

`#pragma once` is a widely supported preprocessor directive that
prevents header files from being included multiple times. It is
supported by all toolchains used to build edk2: GCC, Clang/LLVM, and
MSVC.

Compared to macro-based include guards, `#pragma once`:

- Eliminates the risk of macro name collisions or copy/paste errors
  where two headers inadvertently use the same guard macro.
- Eliminate inconsistency in the way include guard macros are named
  (e.g., some files use `__FILE_H__`, others use `FILE_H_`, etc.).
- Reduces boilerplate (three lines replaced by one).
- Avoids polluting the macro namespace with guard symbols.
- Can improve build times as the preprocessor can skip re-opening the
  file entirely, rather than re-reading it to find the matching
  `#endif` ("multiple-include optimization").
  - Note that some compilers may already optimize traditional include
    guards, by recognzining the idiomatic pattern.

This change is made acknowledging that overall portability of the
code will technically be reduced, as `#pragma once` is not part of the
C/C++ standards.

However, this is considered acceptable given:

1. edk2 already defines a subset of supported compilers in
   BaseTools/Conf/tools_def.template, all of which have supported
   `#pragma once` for over two decades.
2. There have been concerns raised to the project about inconsistent
   include guard naming and potential macro collisions.

Approximate compiler support dates:

- MSVC: Supported since Visual C++ 4.2 (1996)
- GCC: Supported since 3.4 (2004)
  (http://gnu.ist.utl.pt/software/gcc/gcc-3.4/changes.html)
- Clang (LLVM based): Since initial release in 2007

Signed-off-by: Michael Kubacki &lt;michael.kubacki@microsoft.com&gt;
</content>
</entry>
<entry>
<title>UefiCpuPkg/Library: Rename EDKII_PEI_MP_SERVICES2_PPI</title>
<updated>2025-04-18T17:13:55+00:00</updated>
<author>
<name>INDIA\sachinganesh</name>
<email>sachinganesh@ami.com</email>
</author>
<published>2025-02-20T09:36:58+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=1d6b8aafa729846b707b8303dea9087f3a4a8e9e'/>
<id>urn:sha1:1d6b8aafa729846b707b8303dea9087f3a4a8e9e</id>
<content type='text'>
EDKII_PEI_MP_SERVICES2_PPI has been renamed to EFI_PEI_MP_SERVICES2_PPI
and moved to MdePkg.

Relevant changes have been made here.

Signed-off-by: Sachin Ganesh &lt;sachinganesh@ami.com&gt;
</content>
</entry>
<entry>
<title>UefiCpuPkg: Use public Architectural MSRs from MdePkg</title>
<updated>2024-11-12T01:07:12+00:00</updated>
<author>
<name>Vivian Nowka-Keane</name>
<email>vnowkakeane@linux.microsoft.com</email>
</author>
<published>2024-10-22T21:19:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=5a7377615639df9c6731d75fbd2204dc139b86da'/>
<id>urn:sha1:5a7377615639df9c6731d75fbd2204dc139b86da</id>
<content type='text'>
Replaced local Msr defines with inclusion of Register/Amd/Msr.h in Amd
libraries.

Signed-off-by: Vivian Nowka-Keane &lt;vnowkakeane@linux.microsoft.com&gt;
</content>
</entry>
<entry>
<title>UefiCpuPkg: Remove AMD 32-bit SMRAM save state map</title>
<updated>2024-11-01T13:53:09+00:00</updated>
<author>
<name>Phil Noh</name>
<email>Phil.Noh@amd.com</email>
</author>
<published>2024-10-31T19:51:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=03d8907321c1f8f7d062e08a9c84ee74afbe3e8a'/>
<id>urn:sha1:03d8907321c1f8f7d062e08a9c84ee74afbe3e8a</id>
<content type='text'>
Per AMD64 Architecture Programmer's Manual Volume 2: System
Programming - 10.2.3 SMRAM State-Save Area (Rev 24593), the AMD64
architecture does not use the legacy SMM state-save area format
(Table 10-2) for 32-bit SMRAM save state map. Clean up codes for the
invalid save state map.

Signed-off-by: Phil Noh &lt;Phil.Noh@amd.com&gt;
</content>
</entry>
<entry>
<title>UefiCpuPkg/SmmRelocationLib: Add library instance for AMD</title>
<updated>2024-05-08T01:53:58+00:00</updated>
<author>
<name>Jiaxin Wu</name>
<email>jiaxin.wu@intel.com</email>
</author>
<published>2024-04-10T05:05:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=47f212295f17ef2473b37e3e8cfbddd411ad85ea'/>
<id>urn:sha1:47f212295f17ef2473b37e3e8cfbddd411ad85ea</id>
<content type='text'>
Due to the definition difference of SMRAM Save State,
SmmBase config in SMRAM Save State for AMD is also different.

This patch provides the AmdSmmRelocationLib library instance
to handle the SMRAM Save State difference.

Cc: Abdul Lateef Attar &lt;AbdulLateef.Attar@amd.com&gt;
Cc: Abner Chang &lt;abner.chang@amd.com&gt;
Cc: Ray Ni &lt;ray.ni@intel.com&gt;
Cc: Zeng Star &lt;star.zeng@intel.com&gt;
Cc: Gerd Hoffmann &lt;kraxel@redhat.com&gt;
Cc: Rahul Kumar &lt;rahul1.kumar@intel.com&gt;
Signed-off-by: Jiaxin Wu &lt;jiaxin.wu@intel.com&gt;
Acked-by: Ray Ni &lt;ray.ni@intel.com&gt;
Reviewed-by: Abdul Lateef Attar &lt;AbdulLateef.Attar@amd.com&gt;
</content>
</entry>
<entry>
<title>UefiCpuPkg/SmmRelocationLib: Remove unnecessary CpuIndex</title>
<updated>2024-05-08T01:53:58+00:00</updated>
<author>
<name>Jiaxin Wu</name>
<email>jiaxin.wu@intel.com</email>
</author>
<published>2024-04-23T06:00:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=c56ea95b2845d2846eda8ceb740586fe936627c9'/>
<id>urn:sha1:c56ea95b2845d2846eda8ceb740586fe936627c9</id>
<content type='text'>
This patch is to remove unnecessary CpuIndex.

Cc: Ray Ni &lt;ray.ni@intel.com&gt;
Cc: Zeng Star &lt;star.zeng@intel.com&gt;
Cc: Gerd Hoffmann &lt;kraxel@redhat.com&gt;
Cc: Rahul Kumar &lt;rahul1.kumar@intel.com&gt;
Signed-off-by: Jiaxin Wu &lt;jiaxin.wu@intel.com&gt;
Reviewed-by: Ray Ni &lt;ray.ni@intel.com&gt;
</content>
</entry>
<entry>
<title>UefiCpuPkg/SmmRelocationLib: Remove unnecessary global variable</title>
<updated>2024-05-08T01:53:58+00:00</updated>
<author>
<name>Jiaxin Wu</name>
<email>jiaxin.wu@intel.com</email>
</author>
<published>2024-04-23T05:46:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=9783dc01cccf557e6955dfc938f8b4acd7b16c88'/>
<id>urn:sha1:9783dc01cccf557e6955dfc938f8b4acd7b16c88</id>
<content type='text'>
This patch aims on mProcessorInfo global variable, which can be
defined as local variable in SmmRelocateBases(). With this patch,
no need to allocate the memory for all CPUs to store the
Processor Info.

Cc: Ray Ni &lt;ray.ni@intel.com&gt;
Cc: Zeng Star &lt;star.zeng@intel.com&gt;
Cc: Gerd Hoffmann &lt;kraxel@redhat.com&gt;
Cc: Rahul Kumar &lt;rahul1.kumar@intel.com&gt;
Signed-off-by: Jiaxin Wu &lt;jiaxin.wu@intel.com&gt;
Reviewed-by: Ray Ni &lt;ray.ni@intel.com&gt;
</content>
</entry>
<entry>
<title>UefiCpuPkg/SmmRelocationLib: Avoid unnecessary memory allocation</title>
<updated>2024-05-08T01:53:58+00:00</updated>
<author>
<name>Jiaxin Wu</name>
<email>jiaxin.wu@intel.com</email>
</author>
<published>2024-04-18T04:35:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=7421094136989fe53c73efd9c90eefd289a28a01'/>
<id>urn:sha1:7421094136989fe53c73efd9c90eefd289a28a01</id>
<content type='text'>
Since SMM relocation is performed serially for each CPU, there is
no need to allocate buffers for all CPUs to store the SmBase
address in mSmBase and the Rebased flag in mRebased. A defined
global variable is sufficient.

This patch focuses on the mSmBase and mRebased global variables
to prevent unnecessary memory allocation for these variables.

Cc: Ray Ni &lt;ray.ni@intel.com&gt;
Cc: Zeng Star &lt;star.zeng@intel.com&gt;
Cc: Gerd Hoffmann &lt;kraxel@redhat.com&gt;
Cc: Rahul Kumar &lt;rahul1.kumar@intel.com&gt;
Signed-off-by: Jiaxin Wu &lt;jiaxin.wu@intel.com&gt;
Reviewed-by: Ray Ni &lt;ray.ni@intel.com&gt;
</content>
</entry>
<entry>
<title>UefiCpuPkg/SmmRelocationLib: Rename global variables</title>
<updated>2024-05-08T01:53:58+00:00</updated>
<author>
<name>Jiaxin Wu</name>
<email>jiaxin.wu@intel.com</email>
</author>
<published>2024-04-18T03:13:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=42e8fa84f782d79cd18cd10493375d5b71bcc71b'/>
<id>urn:sha1:42e8fa84f782d79cd18cd10493375d5b71bcc71b</id>
<content type='text'>
This patch aims to rename global variables for clearer
association with Smm Init, ensuring their names are
distinct from those used in the PiSmmCpuDxeSmm Driver.

Cc: Ray Ni &lt;ray.ni@intel.com&gt;
Cc: Zeng Star &lt;star.zeng@intel.com&gt;
Cc: Gerd Hoffmann &lt;kraxel@redhat.com&gt;
Cc: Rahul Kumar &lt;rahul1.kumar@intel.com&gt;
Signed-off-by: Jiaxin Wu &lt;jiaxin.wu@intel.com&gt;
Reviewed-by: Ray Ni &lt;ray.ni@intel.com&gt;
</content>
</entry>
</feed>
