Mailing List Archive

[xen-unstable] vtd: Fix for irq bind failure after PCI attaching 32 times
# HG changeset patch
# User Fengzhe Zhang <fengzhe.zhang@intel.com>
# Date 1296127906 0
# Node ID 48008a2cbc1ed12696cd129d83196f3e04f6ab1b
# Parent 7873885ec74dee5b6dda5d72aebbea85c8ab54a9
vtd: Fix for irq bind failure after PCI attaching 32 times

Originally when detaching a PCI device, pirq_to_emuirq and pirq_to_irq
are freed via hypercall do_physdev_op. Now in function
pt_irq_destroy_bind_vtd, duplicated logic is added to free
pirq_to_emuirq, but not pirq_to_irq. This causes do_physdev_op fail to
free both emuirq and irq. After attaching a PCI device for 32 times,
irq resources run out. This patch removes the redundant logic.

Signed-off-by: Fengzhe Zhang <fengzhe.zhang@intel.com>
---
xen/drivers/passthrough/io.c | 1 -
1 files changed, 1 deletion(-)

diff -r 7873885ec74d -r 48008a2cbc1e xen/drivers/passthrough/io.c
--- a/xen/drivers/passthrough/io.c Thu Jan 27 09:37:19 2011 +0000
+++ b/xen/drivers/passthrough/io.c Thu Jan 27 11:31:46 2011 +0000
@@ -375,7 +375,6 @@ int pt_irq_destroy_bind_vtd(
hvm_irq_dpci->mirq[machine_gsi].dom = NULL;
hvm_irq_dpci->mirq[machine_gsi].flags = 0;
clear_bit(machine_gsi, hvm_irq_dpci->mapping);
- unmap_domain_pirq_emuirq(d, machine_gsi);
}
}
spin_unlock(&d->event_lock);

_______________________________________________
Xen-changelog mailing list
Xen-changelog@lists.xensource.com
http://lists.xensource.com/xen-changelog