summaryrefslogtreecommitdiffstats
path: root/hw/s390x
diff options
context:
space:
mode:
authorMichael S. Tsirkin2016-12-12 19:42:03 +0100
committerMichael S. Tsirkin2016-12-16 00:14:38 +0100
commitd93ddfb1f8fb72a7c175a8cf1028c639f769d105 (patch)
treecf4265f7ff97dbf85fde0819f48e5e6eecda6821 /hw/s390x
parenti386: amd_iommu: fix MMIO register count and access (diff)
downloadqemu-d93ddfb1f8fb72a7c175a8cf1028c639f769d105.tar.gz
qemu-d93ddfb1f8fb72a7c175a8cf1028c639f769d105.tar.xz
qemu-d93ddfb1f8fb72a7c175a8cf1028c639f769d105.zip
pci: fix error message for express slots
PCI Express downstream slot has a single PCI slot behind it, using PCI_DEVFN(PCI_SLOT(devfn), 0) does not give you function 0 in cases such as ARI as well as some error cases. This is exactly what we are hitting: $ qemu-system-x86_64 -machine q35 -readconfig docs/q35-chipset.cfg -monitor stdio (qemu) device_add e1000e,bus=ich9-pcie-port-4,addr=00 (qemu) device_add e1000e,bus=ich9-pcie-port-4,addr=08 Segmentation fault (core dumped) The fix is to use the pci_get_function_0 API. Cc: qemu-stable@nongnu.org Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Reported-by: Eduardo Habkost <ehabkost@redhat.com> Tested-by: Cao jin <caoj.fnst@cn.fujitsu.com> Tested-by: Eduardo Habkost <ehabkost@redhat.com> Reviewed-by: Eduardo Habkost <ehabkost@redhat.com>
Diffstat (limited to 'hw/s390x')
0 files changed, 0 insertions, 0 deletions