WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] [PATCH] Fix MSI-x devices assignment.

To: Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx>
Subject: [Xen-devel] [PATCH] Fix MSI-x devices assignment.
From: "Zhang, Xiantao" <xiantao.zhang@xxxxxxxxx>
Date: Fri, 25 Dec 2009 22:16:47 +0800
Accept-language: en-US
Acceptlanguage: en-US
Cc: "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>, Keir Fraser <keir.fraser@xxxxxxxxxxxxx>
Delivery-date: Fri, 25 Dec 2009 06:17:14 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: AcqFbOQs2O708A4YR3eOHq2QFs+1ow==
Thread-topic: [PATCH] Fix MSI-x devices assignment.
Hi, Ian
   This patch should fix MSI-x device assignment issues. Some kinds of MSI-x 
devcies fail to work after assignment, and various kinds of strange issues 
occur with this error. And this patch should them! 
Xiantao


>From e6a8ce7273c612d1b3fb30dd9109e355d4b11d74 Mon Sep 17 00:00:00 2001
From: root <root@vt-dp6.(none)>
Date: Fri, 25 Dec 2009 21:45:58 +0800
Subject: [PATCH] Fix MSI-x devices assignment.
 
Currenlty, assigned MSI-x devices fails to
work due to incorrect table_offset_adjust setting.
The last field msix_entryof struct pt_msix_info is
a variable-size array, so there shouldn't be any field
after it, otherwise they maybe destroyed
when access msix_entry.
 
Signed-off-by: Xiantao Zhang <xiantao.zhang@xxxxxxxxxxxxx@intel.com>
---
 hw/pass-through.h |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
 
diff --git a/hw/pass-through.h b/hw/pass-through.h
index 324df5b..64ce4bf 100644
--- a/hw/pass-through.h
+++ b/hw/pass-through.h
@@ -189,11 +189,11 @@ struct pt_msix_info {
     int bar_index;
     uint64_t table_base;
     uint32_t table_off;
+    uint32_t table_offset_adjust; /* page align mmap */
     uint64_t mmio_base_addr;
     int mmio_index;
     void *phys_iomem_base;
     struct msix_entry_info msix_entry[0];
-    uint32_t table_offset_adjust; /* page align mmap */
 };
 
 struct pt_pm_info {
-- 
1.5.6.1
 

Attachment: 0001-Fix-MSI-x-devices-assignment.patch
Description: 0001-Fix-MSI-x-devices-assignment.patch

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-devel] [PATCH] Fix MSI-x devices assignment., Zhang, Xiantao <=