Skip to contentSkip to conversation

VFIO: platform: clear IRQ_NOAUTOEN when de-assigning the IRQ

PATCH New Eric Auger 1 participant 1 message Oct 14, 2015

Subsystems (4)
lore
Share & tools
lore

Eric Auger

author
#0 lore raw

PATCH 1/1 VFIO: platform: clear IRQ_NOAUTOEN when de-assigning the IRQ

The vfio platform driver currently sets the IRQ_NOAUTOEN before doing the request_irq to properly handle the user masking. However it does not clear it when de-assigning the IRQ. This brings issues when loading the native driver again which may not explicitly enable the IRQ. This problem was observed with xgbe driver.

---
 drivers/vfio/platform/vfio_platform_irq.c | 1 +
 1 file changed, 1 insertion(+)
drivers/vfio/platform/vfio_platform_irq.c +1 -0
index 88bba57..46d4750 100644
@@ -185,6 +185,7 @@ static int vfio_set_trigger(struct vfio_platform_device *vdev, int index,
 	int ret;
 
 	if (irq->trigger) {
+		irq_clear_status_flags(irq->hwirq, IRQ_NOAUTOEN);
 		free_irq(irq->hwirq, irq);
 		kfree(irq->name);
 		eventfd_ctx_put(irq->trigger);
Signature · 1 line
1.9.1