Skip to contentSkip to conversation

msix: unset PCIDevice::msix_vector_poll_notifier in rollback

PATCH In review Robert Hoo 2 participants 3 messages Nov 13, 2023

lore
Share & tools
lore

Robert Hoo

author
#0 lore raw

PATCH 1/1 msix: unset PCIDevice::msix_vector_poll_notifier in rollback

In the rollback in msix_set_vector_notifiers(), original patch forgot to undo msix_vector_poll_notifier pointer.

Fixes bbef882cc193 ("msi: add API to get notified about pending bit poll")
---
 hw/pci/msix.c | 1 +
 1 file changed, 1 insertion(+)
hw/pci/msix.c +1 -0
index ab8869d9d0..cd817f4ca8 100644
@@ -648,6 +648,7 @@ undo:
     }
     dev->msix_vector_use_notifier = NULL;
     dev->msix_vector_release_notifier = NULL;
+    dev->msix_vector_poll_notifier = NULL;
     return ret;
 }
 
Signature · 1 line
2.39.3
Reviewed-by on v1 1/1
#1 lore raw

Hi Robert,

Quoted 2 lines · Robert Hoo

In the rollback in msix_set_vector_notifiers(), original patch forgot to undo msix_vector_poll_notifier pointer.

Out of curiosity, nobody complained during 11 years, so in which use case did you notice this?

Quoted 5 lines
Fixes bbef882cc193 ("msi: add API to get notified about pending bit poll")
---
  hw/pci/msix.c | 1 +
  1 file changed, 1 insertion(+)
author
#2 lore raw
Quoted 9 lines · Philippe Mathieu-Daudé

Hi Robert,

Quoted 2 lines · Robert Hoo

In the rollback in msix_set_vector_notifiers(), original patch forgot to undo msix_vector_poll_notifier pointer.

Out of curiosity, nobody complained during 11 years, so in which use case did you notice this?

Hi Philippe,

I stumbled upon this when looking into another issue.

I think, thanks to the caller's very standardized use, the omission has never been exposed.