public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: "Lendacky, Thomas" <thomas.lendacky@amd.com>
To: Ard Biesheuvel <ardb@kernel.org>
Cc: devel@edk2.groups.io, kraxel@redhat.com,
	Laszlo Ersek <lersek@redhat.com>,
	Oliver Steffen <osteffen@redhat.com>,
	Ard Biesheuvel <ardb+tianocore@kernel.org>,
	Jordan Justen <jordan.l.justen@intel.com>,
	Jiewen Yao <jiewen.yao@intel.com>,
	Pawel Polawski <ppolawsk@redhat.com>
Subject: Re: [edk2-devel] [PATCH 1/1] OvmfPkg/PlatformInitLib: pass through reservations from qemu
Date: Tue, 17 Jan 2023 15:43:37 -0600	[thread overview]
Message-ID: <90f05b21-3fb6-44cd-3254-2275b5fb072d@amd.com> (raw)
In-Reply-To: <CAMj1kXEm3zNLQ0H=CEwe6DCp7KWASCbYXhytbSNxtr4DhK+HRQ@mail.gmail.com>

On 1/17/23 10:49, Ard Biesheuvel wrote:
> On Mon, 16 Jan 2023 at 21:10, Tom Lendacky <thomas.lendacky@amd.com> wrote:
>>
>> On 1/16/23 11:09, Ard Biesheuvel wrote:
>>> On Thu, 12 Jan 2023 at 18:09, Tom Lendacky <thomas.lendacky@amd.com> wrote:
>>>>
>>>> On 12/6/22 23:32, Gerd Hoffmann via groups.io wrote:
>>>>> qemu uses the etc/e820 fw_cfg file not only for memory, but
>>>>> also for reservations.  Handle reservations by adding resource
>>>>> descriptor hobs for them.
>>>>>
>>>>> A typical qemu configuration has a small reservation between
>>>>> lapic and flash:
>>>>>
>>>>>      # sudo cat /proc/iomem
>>>>>      [ ... ]
>>>>>      fee00000-fee00fff : Local APIC
>>>>>      feffc000-feffffff : Reserved          <= HERE
>>>>>      ffc00000-ffffffff : Reserved
>>>>>      [ ... ]
>>>>>
>>>>> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
>>>>
>>>> On newer versions of Qemu, this patch causes a boot failure on my
>>>> AMD system with the following output:
>>>>
>>>> ...
>>>> PciHostBridgeUtilityInitRootBridge: populated root bus 0, with room for 255 subordinate bus(es)
>>>> RootBridge: PciRoot(0x0)
>>>>      Support/Attr: 70069 / 70069
>>>>        DmaAbove4G: No
>>>> NoExtConfSpace: No
>>>>         AllocAttr: 3 (CombineMemPMem Mem64Decode)
>>>>               Bus: 0 - FF Translation=0
>>>>                Io: 6000 - FFFF Translation=0
>>>>               Mem: C0000000 - FBFFFFFF Translation=0
>>>>        MemAbove4G: E000000000 - FFFFFFFFFF Translation=0
>>>>              PMem: FFFFFFFFFFFFFFFF - 0 Translation=0
>>>>       PMemAbove4G: FFFFFFFFFFFFFFFF - 0 Translation=0
>>>> PciHostBridgeDxe: IntersectMemoryDescriptor: desc [FD00000000, 10000000000) type 1 cap 8000000000026000 conflicts with aperture [E000000000, 10000000000) cap 1
>>>>
>>>> ASSERT_EFI_ERROR (Status = Invalid Parameter)
>>>> ASSERT [PciHostBridgeDxe] /root/kernels/ovmf-build-X64/MdeModulePkg/Bus/Pci/PciHostBridgeDxe/PciHostBridge.c(550): !(((INTN)(RETURN_STATUS)(Status)) < 0)
>>>>
>>>> Doing some bisecting, before Qemu patch
>>>>
>>>>       8504f129450b ("i386/pc: relocate 4g start to 1T where applicable")
>>>>
>>>> this issue wasn't observed. And before this OVMF patch, the newer version
>>>> of Qemu doesn't have an issue.
>>>>
>>>> Also, if I add host-phys-bits=true to the Qemu -cpu parameter, then
>>>> the issue isn't observed regardless of Qemu/OVMF level.
>>>>
>>>> I'm hoping someone has an understanding of what is going on and what
>>>> can be done to fix it.
>>>>
>>>
>>> Could someone look into this please? Gerd?
>>
>> Looks like Gerd is already on it.
>>
>> See https://bugzilla.tianocore.org/show_bug.cgi?id=4251
>>
> 
> Right, I didn't realize these things were related.
> 
> In any case, those patches have been merged now - care to check
> whether the issue has been resolved? Thanks.

Yes, the issue is now resolved.

Thanks,
Tom


      reply	other threads:[~2023-01-17 21:43 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-07  5:32 [PATCH 1/1] OvmfPkg/PlatformInitLib: pass through reservations from qemu Gerd Hoffmann
2022-12-23 11:55 ` [edk2-devel] " Ard Biesheuvel
2023-01-12 17:09 ` Lendacky, Thomas
2023-01-16 17:09   ` Ard Biesheuvel
2023-01-16 20:10     ` Lendacky, Thomas
2023-01-17 16:49       ` Ard Biesheuvel
2023-01-17 21:43         ` Lendacky, Thomas [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=90f05b21-3fb6-44cd-3254-2275b5fb072d@amd.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