net: allow using any PCI NICs in -net or -nic
authorPaolo Bonzini <pbonzini@redhat.com>
Fri, 2 Mar 2018 09:30:50 +0000 (10:30 +0100)
committerPaolo Bonzini <pbonzini@redhat.com>
Mon, 12 Mar 2018 15:12:45 +0000 (16:12 +0100)
commit52310c3fa7dc854dd2376ae8a518141abcdb78f3
tree29b2447b2f36061d43c4b6b6d3a57193b1e6bce6
parent47c66009ab793241e8210b3018c77a9ce9506aa8
net: allow using any PCI NICs in -net or -nic

Remove the hard-coded list of PCI NIC names; instead, fill an array
using all PCI devices listed under DEVICE_CATEGORY_NETWORK. Keep
the old shortcut "virtio" for virtio-net-pci.

Suggested-by: Thomas Huth <thuth@redhat.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Reviewed-by: Jason Wang <jasowang@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
hw/pci/pci.c
hw/ppc/e500.c