hw/ppc/prep: use pci_init_nic_devices()
authorDavid Woodhouse <dwmw@amazon.co.uk>
Mon, 23 Oct 2023 08:37:14 +0000 (09:37 +0100)
committerDavid Woodhouse <dwmw@amazon.co.uk>
Fri, 2 Feb 2024 16:23:47 +0000 (16:23 +0000)
commit4c71721651454343ff5cead85f02a1ada7520244
tree4890ca898fe865858545b17fdee5ddbadcef6a32
parentd2e82b1744ee81b1b1c8d15b2bfd46d46f2a49ba
hw/ppc/prep: use pci_init_nic_devices()

Previously, the first PCI NIC would be placed in PCI slot 3 and the rest
would be dynamically assigned. Even if the user overrode the default NIC
type and made it something other than PCNet.

Now, the first PCNet NIC (that is, anything not explicitly specified
to be anything different) will go to slot 3 even if it isn't the first
NIC specified on the command line. And anything else will be dynamically
assigned.

Signed-off-by: David Woodhouse <dwmw@amazon.co.uk>
Reviewed-by: Thomas Huth <thuth@redhat.com>
hw/ppc/prep.c