[edk2-devel] [PATCH 1/1] OvmfPkg/PciHotPlugInitDxe: Do not reserve IO ports by default.

Ard Biesheuvel ardb at kernel.org
Mon May 29 11:41:18 UTC 2023


On Thu, 25 May 2023 at 17:47, Ard Biesheuvel <ardb at kernel.org> wrote:
>
> On Tue, 16 May 2023 at 11:48, Gerd Hoffmann <kraxel at redhat.com> wrote:
> >
> > Flip the default for IO address space reservations for PCI(e) bridges
> > and root ports with hotplug support from TRUE to FALSE.
> >
> > PCI(e) bridges will still get IO address space assigned in case:
> >
> >   (a) Downstream devices actually need IO address space, or
> >   (b) Explicit configuration, using "qemu -device
> >       pcie-root-port,io-reserve=<size>".
> >
> > In case IO address space is exhausted edk2 will stop assigning resources
> > to PCI(e) bridges.  This is not limited to IO resources, the affected
> > bridges will not get any memory resources assigned either.
> >
> > This patch solves this issue by not handing out the scare IO address
> > space, which is in most cases not needed anyway.  Result is a more
> > consistent PCI configuration in virtual machine configurations with many
> > PCie root ports.
> >
> > Signed-off-by: Gerd Hoffmann <kraxel at redhat.com>
>
> Reviewed-by: Ard Biesheuvel <ardb at kernel.org>
>

Merged as #4441

> > ---
> >  OvmfPkg/PciHotPlugInitDxe/PciHotPlugInit.c | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/OvmfPkg/PciHotPlugInitDxe/PciHotPlugInit.c b/OvmfPkg/PciHotPlugInitDxe/PciHotPlugInit.c
> > index 6b2b6797b3b6..69903a600981 100644
> > --- a/OvmfPkg/PciHotPlugInitDxe/PciHotPlugInit.c
> > +++ b/OvmfPkg/PciHotPlugInitDxe/PciHotPlugInit.c
> > @@ -589,7 +589,7 @@ GetResourcePadding (
> >      return EFI_INVALID_PARAMETER;
> >    }
> >
> > -  DefaultIo       = TRUE;
> > +  DefaultIo       = FALSE;
> >    DefaultMmio     = TRUE;
> >    DefaultPrefMmio = TRUE;
> >
> > --
> > 2.40.1
> >


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#105375): https://edk2.groups.io/g/devel/message/105375
Mute This Topic: https://groups.io/mt/98922836/1813853
Group Owner: devel+owner at edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [edk2-devel-archive at redhat.com]
-=-=-=-=-=-=-=-=-=-=-=-




More information about the edk2-devel-archive mailing list