[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-devel] [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

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.