public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: "Friedrich Weber" <f.weber@proxmox.com>
To: Ard Biesheuvel <ardb@kernel.org>, devel@edk2.groups.io
Subject: Re: [edk2-devel] Avoid split lock detection warnings triggered by OVMF?
Date: Thu, 5 Jun 2025 11:00:16 +0200	[thread overview]
Message-ID: <abbf6cee-b992-42d7-9c5e-440d88af7dfa@proxmox.com> (raw)
In-Reply-To: <CAMj1kXEjXe7be5MZiRyos8TCOttOwLzVYemyuFtdfedYDTNSkg@mail.gmail.com>

Thank you for your fast answer!

On 05/06/2025 09:04, Ard Biesheuvel wrote:
> Thanks for the elaborate report. Does the following help?
> 
> diff --git a/UefiCpuPkg/Library/MpInitLib/MpLib.h
> b/UefiCpuPkg/Library/MpInitLib/MpLib.h
> index a63bb81bef88..a9b3fa77e14d 100644
> --- a/UefiCpuPkg/Library/MpInitLib/MpLib.h
> +++ b/UefiCpuPkg/Library/MpInitLib/MpLib.h
> @@ -213,8 +213,6 @@ typedef struct {
>    UINTN              StackStart;
>    UINTN              StackSize;
>    UINTN              CFunction;
> -  IA32_DESCRIPTOR    GdtrProfile;
> -  IA32_DESCRIPTOR    IdtrProfile;
>    UINTN              BufferStart;
>    UINTN              ModeOffset;
>    UINTN              ApIndex;
> @@ -227,6 +225,8 @@ typedef struct {
>    UINTN              NumApsExecuting;
>    CPU_MP_DATA        *CpuMpData;
>    UINTN              InitializeFloatingPointUnitsAddress;
> +  IA32_DESCRIPTOR    GdtrProfile;
> +  IA32_DESCRIPTOR    IdtrProfile;
>    UINT32             ModeTransitionMemory;
>    UINT16             ModeTransitionSegment;
>    UINT32             ModeHighMemory;
> diff --git a/UefiCpuPkg/Library/MpInitLib/MpEqu.inc
> b/UefiCpuPkg/Library/MpInitLib/MpEqu.inc
> index d8ba9ea1246c..d67c4c923c82 100644
> --- a/UefiCpuPkg/Library/MpInitLib/MpEqu.inc
> +++ b/UefiCpuPkg/Library/MpInitLib/MpEqu.inc
> @@ -74,8 +74,6 @@ struc MP_CPU_EXCHANGE_INFO
>    .StackStart:                   CTYPE_UINTN 1
>    .StackSize:                    CTYPE_UINTN 1
>    .CFunction:                    CTYPE_UINTN 1
> -  .GdtrProfile:                  CTYPE_UINT8 IA32_DESCRIPTOR_size
> -  .IdtrProfile:                  CTYPE_UINT8 IA32_DESCRIPTOR_size
>    .BufferStart:                  CTYPE_UINTN 1
>    .ModeOffset:                   CTYPE_UINTN 1
>    .ApIndex:                      CTYPE_UINTN 1
> @@ -88,6 +86,8 @@ struc MP_CPU_EXCHANGE_INFO
>    .NumApsExecuting:              CTYPE_UINTN 1
>    .CpuMpData:                    CTYPE_UINTN 1
>    .InitializeFloatingPointUnits: CTYPE_UINTN 1
> +  .GdtrProfile:                  CTYPE_UINT8 IA32_DESCRIPTOR_size
> +  .IdtrProfile:                  CTYPE_UINT8 IA32_DESCRIPTOR_size
>    .ModeTransitionMemory:         CTYPE_UINT32 1
>    .ModeTransitionSegment:        CTYPE_UINT16 1
>    .ModeHighMemory:               CTYPE_UINT32 1

Applied this on top of 8c04bcc7ed, and the minimal reproducer doesn't
trigger any split lock warnings anymore. I also booted some
Linux+Windows test VMs with a patched firmware build and didn't see any
split lock warnings caused by OVMF (the Windows VMs seem to occasionally
trigger some when booted, but this is a different issue).



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#121395): https://edk2.groups.io/g/devel/message/121395
Mute This Topic: https://groups.io/mt/113480235/7686176
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io]
-=-=-=-=-=-=-=-=-=-=-=-



      reply	other threads:[~2025-06-05  9:00 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-06-04  9:56 [edk2-devel] Avoid split lock detection warnings triggered by OVMF? Friedrich Weber
2025-06-05  7:04 ` Ard Biesheuvel via groups.io
2025-06-05  9:00   ` Friedrich Weber [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-list from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=abbf6cee-b992-42d7-9c5e-440d88af7dfa@proxmox.com \
    --to=devel@edk2.groups.io \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox