Branch: refs/heads/master Home: https://github.com/tianocore/edk2 Commit: b0bc23d1f246dac977b639470a51bcef1bcd6e1d https://github.com/tianocore/edk2/commit/b0bc23d1f246dac977b639470a51bcef1bcd6e1d Author: Aaron Young <aaron.yo...@oracle.com> Date: 2025-06-11 (Wed, 11 Jun 2025)
Changed paths: M UefiCpuPkg/Library/MpInitLib/MpEqu.inc M UefiCpuPkg/Library/MpInitLib/MpLib.c M UefiCpuPkg/Library/MpInitLib/MpLib.h Log Message: ----------- UefiCpuPkg/MpInitLib: Fix split-lock violation from MP_CPU_EXCHANGE_INFO A split-lock violation in OVMF was discovered due to the NumApsExecuting field of the MP_CPU_EXCHANGE_INFO struct (which is used atomically by the AP Reset Vector assembly code) crossing a cacheline boundary. Since the MP_CPU_EXCHANGE_INFO struct is unaligned and the NumApsExecuting field resides after other non-UINTN aligned fields in the struct (i.e. GdtrProfile/IdtrProfile), the NumApsExecuting field was allocated at a non-UINTN aligned address (crossing a cache-line) resulting in the split-lock violation. Therefore, align the MP_CPU_EXCHANGE_INFO struct (on a UINTN boundary) and move the NumApsExecuting field to before the GdtrProfile/IdtrProfile fields to ensure it is UINTN aligned and thus resides within a single cacheline avoiding the split-lock. Do the same for the ApIndex field as it is also used atomically and thus subject to a split-lock violation. Cc: Ray Ni <ray...@intel.com> Cc: Jiaxin Wu <jiaxin...@intel.com> Cc: Zhiguang Liu <zhiguang....@intel.com> Cc: Dun Tan <dun....@intel.com> Cc: Rahul Kumar <rahul1.ku...@intel.com> Cc: Gerd Hoffmann <kra...@redhat.com> Cc: Star Zeng <star.z...@intel.com> Signed-off-by: Aaron Young <aaron.yo...@oracle.com> To unsubscribe from these emails, change your notification settings at https://github.com/tianocore/edk2/settings/notifications _______________________________________________ edk2-commits mailing list edk2-commits@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/edk2-commits