summaryrefslogtreecommitdiff
path: root/hw/msix.c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/msix.c')
-rw-r--r--hw/msix.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/hw/msix.c b/hw/msix.c
index 47e014017c..3420ce9b24 100644
--- a/hw/msix.c
+++ b/hw/msix.c
@@ -286,8 +286,9 @@ void msix_save(PCIDevice *dev, QEMUFile *f)
{
unsigned n = dev->msix_entries_nr;
- if (!dev->cap_present & QEMU_PCI_CAP_MSIX)
+ if (!(dev->cap_present & QEMU_PCI_CAP_MSIX)) {
return;
+ }
qemu_put_buffer(f, dev->msix_table_page, n * MSIX_ENTRY_SIZE);
qemu_put_buffer(f, dev->msix_table_page + MSIX_PAGE_PENDING, (n + 7) / 8);