Skip to content

Commit

Permalink
hw/pcie-root-port: Fix PCIe root port initialization
Browse files Browse the repository at this point in the history
Specify the root port interrupt pin as part of the init
process for cases when msi/msix are not enabled.

Fixes "hw/pci/pci.c:196:23: runtime error: shift exponent -1 is negative"
warning from clang's sanitizer.

Reported-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Marcel Apfelbaum <marcel@redhat.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
  • Loading branch information
marcel-apf authored and mstsirkin committed Jul 28, 2016
1 parent 6b44954 commit 2c533c5
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions hw/pci-bridge/ioh3420.c
Expand Up @@ -100,6 +100,7 @@ static int ioh3420_initfn(PCIDevice *d)
int rc;
Error *err = NULL;

pci_config_set_interrupt_pin(d->config, 1);
pci_bridge_initfn(d, TYPE_PCIE_BUS);
pcie_port_init_reg(d);

Expand Down

0 comments on commit 2c533c5

Please sign in to comment.