RE: Biweekly KVM Test report, kernel 94252... qemu 5cc3c...

2009-10-13 Thread Xu, Jiajun
On Monday, October 05, 2009 7:00 PM Avi Kivity wrote:

 On 09/29/2009 05:34 AM, Xu, Jiajun wrote:
 Hi All,
 
 This Weekly KVM Testing Report against lastest kvm.git
 94252a58662dc4ca6191eac479efb40e0716865c and qemu-kvm.git
 5cc3cfb6c2254483ae324da407a13307fe7355f3.
 
 Qemu-kvm tree build issue is fixed by qemu commit
 781774b38c90797add71d029b7fbee43200c66d4.
 There is no other new bug found in this two weeks. There are
 7 old bugs open in bug tracking.
 
 
 Seven Old Issues:
 
 1. Guest hang with exhausted IRQ sources error if 8 VFs assigned
 
 https://sourceforge.net/tracker/?func=detailaid=2847560group_
 id=180599atid=893831
 
 
 Does the attached patch fix this issue?

With attached patch, VF can not be enabled with following error:

igb :01:00.0: can't find IRQ for PCI INT A; probably buggy MP table
igb :01:00.0: setting latency timer to 64
igb :01:00.0: irq 88 for MSI/MSI-X
igb :01:00.0: irq 89 for MSI/MSI-X
igb :01:00.0: irq 90 for MSI/MSI-X
igb :01:00.0: irq 91 for MSI/MSI-X
igb :01:00.0: irq 92 for MSI/MSI-X
igb :01:00.0: irq 93 for MSI/MSI-X
igb :01:00.0: irq 94 for MSI/MSI-X
igb :01:00.0: irq 95 for MSI/MSI-X
igb :01:00.0: irq 96 for MSI/MSI-X
igb :01:00.0: Intel(R) Gigabit Ethernet Network Connection
igb :01:00.0: eth0: (PCIe:2.5Gb/s:Width x4) 00:30:48:cb:79:e8
igb :01:00.0: eth0: PBA No: 0010ff-0ff
igb :01:00.0: Using MSI-X interrupts. 4 rx queue(s), 4 tx queue(s)
igb :01:00.1: can't find IRQ for PCI INT B; probably buggy MP table
igb :01:00.1: setting latency timer to 64
igb :01:00.1: irq 97 for MSI/MSI-X
igb :01:00.1: irq 98 for MSI/MSI-X
igb :01:00.1: irq 99 for MSI/MSI-X
igb :01:00.1: irq 100 for MSI/MSI-X
igb :01:00.1: irq 101 for MSI/MSI-X
igb :01:00.1: irq 102 for MSI/MSI-X
igb :01:00.1: irq 103 for MSI/MSI-X
igb :01:00.1: irq 104 for MSI/MSI-X
igb :01:00.1: irq 105 for MSI/MSI-X
igb :01:00.1: Intel(R) Gigabit Ethernet Network Connection
igb :01:00.1: eth1: (PCIe:2.5Gb/s:Width x4) 00:30:48:cb:79:e9
igb :01:00.1: eth1: PBA No: 0010ff-0ff
igb :01:00.1: Using MSI-X interrupts. 4 rx queue(s), 4 tx queue(s)


Best Regards
Jiajun--
To unsubscribe from this list: send the line unsubscribe kvm in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: Biweekly KVM Test report, kernel 94252... qemu 5cc3c...

2009-10-05 Thread Avi Kivity

On 09/29/2009 05:34 AM, Xu, Jiajun wrote:

Hi All,

This Weekly KVM Testing Report against lastest kvm.git
94252a58662dc4ca6191eac479efb40e0716865c and qemu-kvm.git
5cc3cfb6c2254483ae324da407a13307fe7355f3.

Qemu-kvm tree build issue is fixed by qemu commit 
781774b38c90797add71d029b7fbee43200c66d4.
There is no other new bug found in this two weeks. There are 7 old bugs open in 
bug tracking.


Seven Old Issues:

1. Guest hang with exhausted IRQ sources error if 8 VFs assigned
https://sourceforge.net/tracker/?func=detailaid=2847560group_id=180599atid=893831
   


Does the attached patch fix this issue?

--
error compiling committee.c: too many arguments to function

diff --git a/virt/kvm/assigned-dev.c b/virt/kvm/assigned-dev.c
index fd9c097..91b3d99 100644
--- a/virt/kvm/assigned-dev.c
+++ b/virt/kvm/assigned-dev.c
@@ -142,7 +142,8 @@ static void deassign_guest_irq(struct kvm *kvm,
 	kvm_unregister_irq_ack_notifier(kvm, assigned_dev-ack_notifier);
 	assigned_dev-ack_notifier.gsi = -1;
 
-	if (assigned_dev-irq_source_id != -1)
+	if (assigned_dev-irq_source_id != -1
+	 assigned_dev-irq_source_id != KVM_USERSPACE_IRQ_SOURCE_ID)
 		kvm_free_irq_source_id(kvm, assigned_dev-irq_source_id);
 	assigned_dev-irq_source_id = -1;
 	assigned_dev-irq_requested_type = ~(KVM_DEV_IRQ_GUEST_MASK);
@@ -396,20 +397,17 @@ static int assign_guest_irq(struct kvm *kvm,
 			struct kvm_assigned_irq *irq,
 			unsigned long guest_irq_type)
 {
-	int id;
+	int id = KVM_USERSPACE_IRQ_SOURCE_ID;
 	int r = -EEXIST;
 
 	if (dev-irq_requested_type  KVM_DEV_IRQ_GUEST_MASK)
 		return r;
 
-	id = kvm_request_irq_source_id(kvm);
-	if (id  0)
-		return id;
-
-	dev-irq_source_id = id;
-
 	switch (guest_irq_type) {
 	case KVM_DEV_IRQ_GUEST_INTX:
+		id = kvm_request_irq_source_id(kvm);
+		if (id  0)
+			return id;
 		r = assigned_device_enable_guest_intx(kvm, dev, irq);
 		break;
 #ifdef __KVM_HAVE_MSI
@@ -426,11 +424,15 @@ static int assign_guest_irq(struct kvm *kvm,
 		r = -EINVAL;
 	}
 
+	dev-irq_source_id = id;
+
 	if (!r) {
 		dev-irq_requested_type |= guest_irq_type;
 		kvm_register_irq_ack_notifier(kvm, dev-ack_notifier);
-	} else
-		kvm_free_irq_source_id(kvm, dev-irq_source_id);
+	} else {
+		if (dev-irq_source_id != KVM_USERSPACE_IRQ_SOURCE_ID)
+			kvm_free_irq_source_id(kvm, dev-irq_source_id);
+	}
 
 	return r;
 }