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-changelog

[Xen-changelog] [xen-unstable] ioemu: fix offset of MSI-X memory-mapped

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] ioemu: fix offset of MSI-X memory-mapped table.
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Sat, 06 Sep 2008 01:40:17 -0700
Delivery-date: Sat, 06 Sep 2008 01:40:42 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1220609900 -3600
# Node ID 1a785d213573ebbbfb94947de16ed4e34618e727
# Parent  392b04ccaf3c3be6efda73ae75b0af386920bf20
ioemu: fix offset of MSI-X memory-mapped table.

Current code does not set dev->msix->table_off variable.
The offset of MSI-X memory mapped table is treated as 0.
The wrong region is unmapped from guest physical memory space.
As a result, guest device driver can't access memory mapped resource.

Signed-off-by: Yuji Shimada <shimada-yxb@xxxxxxxxxxxxxxx>
---
 tools/ioemu/hw/pt-msi.c |    2 +-
 1 files changed, 1 insertion(+), 1 deletion(-)

diff -r 392b04ccaf3c -r 1a785d213573 tools/ioemu/hw/pt-msi.c
--- a/tools/ioemu/hw/pt-msi.c   Thu Sep 04 16:29:38 2008 +0100
+++ b/tools/ioemu/hw/pt-msi.c   Fri Sep 05 11:18:20 2008 +0100
@@ -313,7 +313,7 @@ int pt_msix_init(struct pt_dev *dev, int
 
     table_off = pci_read_long(pd, pos + PCI_MSIX_TABLE);
     bar_index = dev->msix->bar_index = table_off & PCI_MSIX_BIR;
-    table_off &= table_off & ~PCI_MSIX_BIR;
+    table_off = dev->msix->table_off = table_off & ~PCI_MSIX_BIR;
     dev->msix->table_base = dev->pci_dev->base_addr[bar_index];
     PT_LOG("get MSI-X table bar base %llx\n",
            (unsigned long long)dev->msix->table_base);

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-unstable] ioemu: fix offset of MSI-X memory-mapped table., Xen patchbot-unstable <=