<feed xmlns='http://www.w3.org/2005/Atom'>
<title>Tianocore/edk2.git/MdeModulePkg/Library/CpuExceptionHandlerLibNull/CpuExceptionHandlerLibNull.c, branch trunk</title>
<subtitle>EDK II (mirror)</subtitle>
<id>https://git.radix-linux.su/Tianocore/edk2.git/atom?h=trunk</id>
<link rel='self' href='https://git.radix-linux.su/Tianocore/edk2.git/atom?h=trunk'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/'/>
<updated>2024-06-04T03:43:08+00:00</updated>
<entry>
<title>Renormalized end-of-lines from master@27b044605cd5f6b33a3d231576003850b3fe305b</title>
<updated>2024-06-04T03:43:08+00:00</updated>
<author>
<name>kx</name>
<email>kx@radix.pro</email>
</author>
<published>2024-06-04T03:43:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=7e2ccccace24636f29ddc210b94606abd4c7e42b'/>
<id>urn:sha1:7e2ccccace24636f29ddc210b94606abd4c7e42b</id>
<content type='text'>
</content>
</entry>
<entry>
<title>UefiCpuPkg: Simplify InitializeSeparateExceptionStacks</title>
<updated>2022-08-09T04:12:28+00:00</updated>
<author>
<name>Liu, Zhiguang</name>
<email>Zhiguang.Liu@intel.com</email>
</author>
<published>2022-08-09T01:25:35+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=0f7bccf584d93b2642c0a413a47fc821d1f5dbfd'/>
<id>urn:sha1:0f7bccf584d93b2642c0a413a47fc821d1f5dbfd</id>
<content type='text'>
Hide the Exception implementation details in CpuExcetionHandlerLib and
caller only need to provide buffer

Cc: Eric Dong &lt;eric.dong@intel.com&gt;
Reviewed-by: Ray Ni &lt;ray.ni@intel.com&gt;
Cc: Rahul Kumar &lt;rahul1.kumar@intel.com&gt;
Cc: Leif Lindholm &lt;quic_llindhol@quicinc.com&gt;
Cc: Dandan Bi &lt;dandan.bi@intel.com&gt;
Cc: Liming Gao &lt;gaoliming@byosoft.com.cn&gt;
Cc: Jian J Wang &lt;jian.j.wang@intel.com&gt;
Cc: Ard Biesheuvel &lt;ardb+tianocore@kernel.org&gt;
Reviewed-by: Sami Mujawar &lt;sami.mujawar@arm.com&gt;
Signed-off-by: Zhiguang Liu &lt;zhiguang.liu@intel.com&gt;
</content>
</entry>
<entry>
<title>CpuException: Add InitializeSeparateExceptionStacks</title>
<updated>2022-06-10T07:54:48+00:00</updated>
<author>
<name>Ray Ni</name>
<email>ray.ni@intel.com</email>
</author>
<published>2022-05-20T11:12:35+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=e7abb94d1fb8a0e7725b983bbf5ab1334afe7ed1'/>
<id>urn:sha1:e7abb94d1fb8a0e7725b983bbf5ab1334afe7ed1</id>
<content type='text'>
Today InitializeCpuExceptionHandlersEx is called from three modules:
1. DxeCore (links to DxeCpuExceptionHandlerLib)
    DxeCore expects it initializes the IDT entries as well as
    assigning separate stacks for #DF and #PF.
2. CpuMpPei (links to PeiCpuExceptionHandlerLib)
   and CpuDxe (links to DxeCpuExceptionHandlerLib)
    It's called for each thread for only assigning separate stacks for
    #DF and #PF. The IDT entries initialization is skipped because
    caller sets InitData-&gt;X64.InitDefaultHandlers to FALSE.

Additionally, SecPeiCpuExceptionHandlerLib, SmmCpuExceptionHandlerLib
also implement such API and the behavior of the API is simply to initialize
IDT entries only.

Because it mixes the IDT entries initialization and separate stacks
assignment for certain exception handlers together, in order to know
whether the function call only initializes IDT entries, or assigns stacks,
we need to check:
1. value of InitData-&gt;X64.InitDefaultHandlers
2. library instance

This patch cleans up the code to separate the stack assignment to a new API:
InitializeSeparateExceptionStacks().

Only when caller calls the new API, the separate stacks are assigned.
With this change, the SecPei and Smm instance can return unsupported which
gives caller a very clear status.

The old API InitializeCpuExceptionHandlersEx() is removed in this patch.
Because no platform module is consuming the old API, the impact is none.

Signed-off-by: Ray Ni &lt;ray.ni@intel.com&gt;
Cc: Eric Dong &lt;eric.dong@intel.com&gt;
Cc: Jian J Wang &lt;jian.j.wang@intel.com&gt;
</content>
</entry>
<entry>
<title>CpuException: Remove InitializeCpuInterruptHandlers</title>
<updated>2022-06-10T07:54:48+00:00</updated>
<author>
<name>Ray Ni</name>
<email>ray.ni@intel.com</email>
</author>
<published>2022-05-18T09:51:21+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=2a09527ebcb459b40bc3661d85aa11c3905526dc'/>
<id>urn:sha1:2a09527ebcb459b40bc3661d85aa11c3905526dc</id>
<content type='text'>
InitializeCpuExceptionHandlers() expects caller allocates IDT while
InitializeCpuInterruptHandlers() allocates 256 IDT entries itself.

InitializeCpuExceptionHandlers() fills max 32 IDT entries allocated
by caller. If caller allocates 10 entries, the API just fills 10 IDT
entries.

The inconsistency between the two APIs makes code hard to
unerstand and hard to share.

Because there is only one caller (CpuDxe) for
InitializeCpuInterruptHandler(), this patch updates CpuDxe driver
to allocates 256 IDT entries then call
InitializeCpuExceptionHandlers().

This is also a backward compatible change.

With this change, InitializeCpuInterruptHandlers() is removed
completely.

And InitializeCpuExceptionHandlers() fills max 32 entries for PEI
and SMM instance, max 256 entries for DXE instance.
Such behavior matches to the original one.

Signed-off-by: Ray Ni &lt;ray.ni@intel.com&gt;
Cc: Eric Dong &lt;eric.dong@intel.com&gt;
</content>
</entry>
<entry>
<title>MdeModulePkg: Apply uncrustify changes</title>
<updated>2021-12-07T17:24:28+00:00</updated>
<author>
<name>Michael Kubacki</name>
<email>michael.kubacki@microsoft.com</email>
</author>
<published>2021-12-05T22:54:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=1436aea4d5707e672672a11bda72be2c63c936c3'/>
<id>urn:sha1:1436aea4d5707e672672a11bda72be2c63c936c3</id>
<content type='text'>
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3737

Apply uncrustify changes to .c/.h files in the MdeModulePkg package

Cc: Andrew Fish &lt;afish@apple.com&gt;
Cc: Leif Lindholm &lt;leif@nuviainc.com&gt;
Cc: Michael D Kinney &lt;michael.d.kinney@intel.com&gt;
Signed-off-by: Michael Kubacki &lt;michael.kubacki@microsoft.com&gt;
Reviewed-by: Liming Gao &lt;gaoliming@byosoft.com.cn&gt;
</content>
</entry>
<entry>
<title>MdeModulePkg: Replace BSD License with BSD+Patent License</title>
<updated>2019-04-09T17:58:08+00:00</updated>
<author>
<name>Michael D Kinney</name>
<email>michael.d.kinney@intel.com</email>
</author>
<published>2019-04-03T23:05:13+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=9d510e61fceee7b92955ef9a3c20343752d8ce3f'/>
<id>urn:sha1:9d510e61fceee7b92955ef9a3c20343752d8ce3f</id>
<content type='text'>
https://bugzilla.tianocore.org/show_bug.cgi?id=1373

Replace BSD 2-Clause License with BSD+Patent License.  This change is
based on the following emails:

  https://lists.01.org/pipermail/edk2-devel/2019-February/036260.html
  https://lists.01.org/pipermail/edk2-devel/2018-October/030385.html

RFCs with detailed process for the license change:

  V3: https://lists.01.org/pipermail/edk2-devel/2019-March/038116.html
  V2: https://lists.01.org/pipermail/edk2-devel/2019-March/037669.html
  V1: https://lists.01.org/pipermail/edk2-devel/2019-March/037500.html

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Michael D Kinney &lt;michael.d.kinney@intel.com&gt;
Reviewed-by: Hao Wu &lt;hao.a.wu@intel.com&gt;
Reviewed-by: Jian J Wang &lt;jian.j.wang@intel.com&gt;
</content>
</entry>
<entry>
<title>MdeModulePkg: Clean up source files</title>
<updated>2018-06-28T03:19:45+00:00</updated>
<author>
<name>Liming Gao</name>
<email>liming.gao@intel.com</email>
</author>
<published>2018-06-27T13:08:52+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=d1102dba7210b95e41d06c2338a22ba6af248645'/>
<id>urn:sha1:d1102dba7210b95e41d06c2338a22ba6af248645</id>
<content type='text'>
1. Do not use tab characters
2. No trailing white space in one line
3. All files must end with CRLF

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Liming Gao &lt;liming.gao@intel.com&gt;
Reviewed-by: Star Zeng &lt;star.zeng@intel.com&gt;
</content>
</entry>
<entry>
<title>MdeModulePkg/CpuExceptionHandlerLibNull: Add new API implementation</title>
<updated>2017-12-08T06:38:49+00:00</updated>
<author>
<name>Jian J Wang</name>
<email>jian.j.wang@intel.com</email>
</author>
<published>2017-12-07T12:15:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=2da89195f5a8efc7c085316c706728459126391c'/>
<id>urn:sha1:2da89195f5a8efc7c085316c706728459126391c</id>
<content type='text'>
This patch add implementation of new API InitializeCpuExceptionHandlersEx
introduced into CpuExceptionHandlerLib on behalf of Stack Guard feature.

Cc: Star Zeng &lt;star.zeng@intel.com&gt;
Cc: Eric Dong &lt;eric.dong@intel.com&gt;
Cc: Jiewen Yao &lt;jiewen.yao@intel.com&gt;
Suggested-by: Ayellet Wolman &lt;ayellet.wolman@intel.com&gt;
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Jian J Wang &lt;jian.j.wang@intel.com&gt;
Reviewed-by: Jeff Fan &lt;vanjeff_919@hotmail.com&gt;
Reviewed-by: Jiewen.yao@intel.com
</content>
</entry>
<entry>
<title>MdeModulePkg/CpuExceptionHandlerLib: Add DumpCpuContext()</title>
<updated>2017-04-07T01:43:40+00:00</updated>
<author>
<name>Jeff Fan</name>
<email>jeff.fan@intel.com</email>
</author>
<published>2017-04-01T05:53:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=e2884d2cd07174f987c5932c6eebac71cf4376f9'/>
<id>urn:sha1:e2884d2cd07174f987c5932c6eebac71cf4376f9</id>
<content type='text'>
This API is used to display exception type and all processor context for debug
purpose.

Cc: Jiewen Yao &lt;jiewen.yao@intel.com&gt;
Cc: Michael Kinney &lt;michael.d.kinney@intel.com&gt;
Cc: Feng Tian &lt;feng.tian@intel.com&gt;
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jeff Fan &lt;jeff.fan@intel.com&gt;
Reviewed-by: Jiewen Yao &lt;jiewen.yao@intel.com&gt;
</content>
</entry>
<entry>
<title>MdeModulePkg/CpuExceptionHanderLibNull: RegisterCpuInterruptHandler()</title>
<updated>2016-11-18T01:43:51+00:00</updated>
<author>
<name>Jeff Fan</name>
<email>jeff.fan@intel.com</email>
</author>
<published>2016-11-16T14:18:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=0e99d51637dee0940a23556f3aee2e7c89bd016f'/>
<id>urn:sha1:0e99d51637dee0940a23556f3aee2e7c89bd016f</id>
<content type='text'>
Current CpuExceptionHanderLibNull instance returns EFI_SUCCESS for all three
services. If platform does not want to hook the Exception vector for some
modules (For example DxeCore), it could select this NULL instance in DSC file
for those module. But some modules that want to consume
RegisterCpuInterruptHandler() cannot use NULL instance. If platform does not
select the correct library instance, it will does work. But the caller does not
recognize it.

This update is to return EFI_UNSUPPORTED on RegisterCpuInterruptHandler() in
NULL instance instead of return EFI_SUCCESS. Once platform selects this NULL
instance, the caller could know it from return status.

Cc: Feng Tian &lt;feng.tian@intel.com&gt;
Cc: Michael D Kinney &lt;michael.d.kinney@intel.com&gt;
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jeff Fan &lt;jeff.fan@intel.com&gt;
Reviewed-by: Michael Kinney &lt;michael.d.kinney@intel.com&gt;
</content>
</entry>
</feed>
