Hi David,

On Tue, Jul 13, 2021 at 7:12 AM David Gibson <da...@gibson.dropbear.id.au>
wrote:

> On Tue, Jul 13, 2021 at 02:42:01AM +0200, Julia Suvorova wrote:
> > Add acpi_pcihp to ich9_pm as part of
> > 'acpi-pci-hotplug-with-bridge-support' option. Set default to false.
> >
> > Signed-off-by: Julia Suvorova <jus...@redhat.com>
> > Signed-off-by: Marcel Apfelbaum <marcel.apfelb...@gmail.com>
> > Reviewed-by: Igor Mammedov <imamm...@redhat.com>
>
> Reviewed-by: David Gibson <da...@gibson.dropbear.id.au>
>
> Since it looks safe, however I think there are a couple of unnecessary
> changes here:
>
>
> [snip]
> > @@ -103,6 +105,7 @@ static void *acpi_set_bsel(PCIBus *bus, void *opaque)
> >  static void acpi_set_pci_info(void)
> >  {
> >      static bool bsel_is_set;
> > +    Object *host = acpi_get_i386_pci_host();
> >      PCIBus *bus;
> >      unsigned bsel_alloc = ACPI_PCIHP_BSEL_DEFAULT;
> >
> > @@ -111,7 +114,11 @@ static void acpi_set_pci_info(void)
> >      }
> >      bsel_is_set = true;
> >
> > -    bus = find_i440fx(); /* TODO: Q35 support */
> > +    if (!host) {
>
> AFAICT acpi_get_i386_pci_host() still can't return NULL, so I'm not
> sure this test is necessary.
>

It can, please see the new stub in hw/acpi/acpi-x86-stub.c

Object *acpi_get_i386_pci_host(void)
{
       return NULL;
}

Thanks,
Marcel

[...]

Reply via email to