summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/dev/virtio/pci.cc7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/dev/virtio/pci.cc b/src/dev/virtio/pci.cc
index a051a8f51..fb0735eba 100644
--- a/src/dev/virtio/pci.cc
+++ b/src/dev/virtio/pci.cc
@@ -123,8 +123,11 @@ PciVirtIO::read(PacketPtr pkt)
case OFF_ISR_STATUS: {
DPRINTF(VIOPci, " ISR_STATUS\n");
assert(size == sizeof(uint8_t));
- uint8_t isr_status(interruptDeliveryPending ? 1 : 0);
- interruptDeliveryPending = false;
+ const uint8_t isr_status(interruptDeliveryPending ? 1 : 0);
+ if (interruptDeliveryPending) {
+ interruptDeliveryPending = false;
+ intrClear();
+ }
pkt->set<uint8_t>(isr_status);
} break;