diff options
author | Jan Kiszka | 2012-05-16 01:09:56 +0200 |
---|---|---|
committer | Michael S. Tsirkin | 2012-06-07 16:19:00 +0200 |
commit | cbd2d4342b3d42ab33baa99f5b7a23491b5692f2 (patch) | |
tree | 34edef8be5a550587e9bae0c27d835d35bad1919 /hw/pci.c | |
parent | msi: Guard msi_reset with msi_present (diff) | |
download | qemu-cbd2d4342b3d42ab33baa99f5b7a23491b5692f2.tar.gz qemu-cbd2d4342b3d42ab33baa99f5b7a23491b5692f2.tar.xz qemu-cbd2d4342b3d42ab33baa99f5b7a23491b5692f2.zip |
msi: Invoke msi/msix_reset from PCI core
There is no point in pushing this burden to the devices, they tend to
forget to call them (like intel-hda, ahci, xhci did). Instead, reset
functions are now called from pci_device_reset. They do nothing if
MSI/MSI-X is not in use.
CC: Alexander Graf <agraf@suse.de>
CC: Gerd Hoffmann <kraxel@redhat.com>
CC: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'hw/pci.c')
-rw-r--r-- | hw/pci.c | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -31,6 +31,8 @@ #include "loader.h" #include "range.h" #include "qmp-commands.h" +#include "msi.h" +#include "msix.h" //#define DEBUG_PCI #ifdef DEBUG_PCI @@ -188,6 +190,9 @@ void pci_device_reset(PCIDevice *dev) } } pci_update_mappings(dev); + + msi_reset(dev); + msix_reset(dev); } /* |