]> Git Repo - qemu.git/commit
hw/pci: Fix crash when running QEMU with "-nic model=rocker"
authorThomas Huth <[email protected]>
Wed, 27 May 2020 15:31:52 +0000 (17:31 +0200)
committerMichael S. Tsirkin <[email protected]>
Fri, 12 Jun 2020 14:17:06 +0000 (10:17 -0400)
commit00823980b296c80a3ff7b448df20c48897cd62e9
treecd0bde968145d9c03a5d9cd3a797a7d1349be3af
parenta9a5c473d25d83bcdad27d97e5fb451950ee894a
hw/pci: Fix crash when running QEMU with "-nic model=rocker"

QEMU currently aborts when being started with "-nic model=rocker" or with
"-net nic,model=rocker". This happens because the "rocker" device is not
a normal NIC but a switch, which has different properties. Thus we should
only consider real NIC devices for "-nic" and "-net". These devices can
be identified by the "netdev" property, so check for this property before
adding the device to the list.

Reported-by: Michael Tokarev <[email protected]>
Fixes: 52310c3fa7dc854d ("net: allow using any PCI NICs in -net or -nic")
Signed-off-by: Thomas Huth <[email protected]>
Message-Id: <20200527153152[email protected]>
Reviewed-by: Paolo Bonzini <[email protected]>
Reviewed-by: Michael S. Tsirkin <[email protected]>
Signed-off-by: Michael S. Tsirkin <[email protected]>
hw/pci/pci.c
This page took 0.025745 seconds and 4 git commands to generate.