public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: "Gerd Hoffmann via groups.io" <kraxel=redhat.com@groups.io>
To: devel@edk2.groups.io, mitchell.augustin@canonical.com
Subject: Re: [edk2-devel] [BUG] Extremely slow boot times with CPU and GPU passthrough and host phys-bits > 40
Date: Fri, 22 Nov 2024 11:35:36 +0100	[thread overview]
Message-ID: <sqpqbftklcx24l4sjngsb2tgan6k4a2mnhpd3t2iz6pdqjzy57@o3mbmyjwgqkb> (raw)
In-Reply-To: <24555.1732235012902185669@groups.io>

On Thu, Nov 21, 2024 at 04:23:32PM -0800, mitchell.augustin via groups.io wrote:
> Thanks for the suggestions, Gerd.
> 
> > '-global ICH9-LPC.acpi-pci-hotplug-with-bridge-support=off'
> 
> Unfortunatly, this did not result in any change in boot time.
> 
> > '-cpu $name,host-phys-bits=on,host-phys-bits-limit=$bits'
> 
> -cpu host,host-phys-bits=on,host-phys-bits-limit=40 does result in the desired very fast boot time, but I get errors when I try to load the GPU driver:
> 
> NVRM: BAR0 is 0M @ 0x0 (PCI:0000:06:00.0)

OVMF scales the pcie root port bridge windows with the address space.

So you can try increase host-phys-bits-limit.  Values between 40 and 46
should have an effect.

The opt/ovmf/X-PciMmio64Mb setting already mentioned elsewhere in this
thread should also work with the dynamic mmio window.

> * *I ask this because I notice that when I disable host passthrough *(which works with my GPUs and results in a fast boot if `pci=realloc pci=nocrs` are used)* , my VM shows "Address sizes: 40 bits physical, 48 bits virtual", but when I use host passthrough and only override the physbits (which fails as described above), my VM shows "Address sizes: 40 bits physical, 57 bits virtual". (so I'm wondering if that could be a factor here.)*

It's 5-level paging support, and the qemu option name for that is la57
(-cpu $name,la57={on|off})

take care,
  Gerd



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



  reply	other threads:[~2024-11-22 10:35 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-11-14 16:46 [edk2-devel] [BUG] Extremely slow boot times with CPU and GPU passthrough and host phys-bits > 40 mitchell.augustin via groups.io
2024-11-18 21:14 ` xpahos via groups.io
2024-11-19 22:25   ` mitchell.augustin via groups.io
2024-11-20  9:35     ` xpahos via groups.io
2024-11-20 11:26     ` Gerd Hoffmann via groups.io
2024-11-20 15:20       ` mitchell.augustin via groups.io
2024-11-20 20:00         ` mitchell.augustin via groups.io
2024-11-21 12:32         ` Gerd Hoffmann via groups.io
2024-11-22  0:23           ` mitchell.augustin via groups.io
2024-11-22 10:35             ` Gerd Hoffmann via groups.io [this message]
2024-11-22 17:38               ` Brian J. Johnson via groups.io
2024-11-22 22:32               ` mitchell.augustin via groups.io
2024-11-24  2:05                 ` mitchell.augustin via groups.io
2024-11-25 11:47                   ` Gerd Hoffmann via groups.io
2024-11-25 19:58                     ` mitchell.augustin via groups.io
2024-11-26  8:09                       ` Gerd Hoffmann via groups.io
2024-11-26 22:27                         ` mitchell.augustin via groups.io
2024-12-04 14:56                           ` mitchell.augustin via groups.io
2024-11-25 11:18                 ` Gerd Hoffmann via groups.io
2024-11-18 21:32 ` Ard Biesheuvel via groups.io

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=sqpqbftklcx24l4sjngsb2tgan6k4a2mnhpd3t2iz6pdqjzy57@o3mbmyjwgqkb \
    --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