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, passthrough: fix flag for expansio

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] ioemu, passthrough: fix flag for expansion rom base address register.
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Fri, 01 Aug 2008 02:20:45 -0700
Delivery-date: Fri, 01 Aug 2008 02:22:55 -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 1217580894 -3600
# Node ID 8951c3b84e2a8c41146347dbda8f0f2934dce3fa
# Parent  6692c3646914ee73c5d3e1792f4040c22b039a6e
ioemu, passthrough: fix flag for expansion rom base address register.

pt_bar_reg_parse() is called for expansion rom base address register.
Currently it returns PT_BAR_FLAG_MEM if bit 0 is 0. It returns
PT_BAR_FLAG_IO if bit 0 is 1.

But bit 0 in expansion rom base address register is enable bit. If bit
0 is 1 for some reason, it returns PT_BAR_FLAG_IO. Expansion rom is
mapped to memory space. It should return PT_BAR_FLAG_MEM.

After applying this patch, it returns PT_BAR_FLAG_MEM regardless
of bit 0, when it is called for expansion rom base address register.

Signed-off-by: Yuji Shimada <shimada-yxb@xxxxxxxxxxxxxxx>
---
 tools/ioemu/hw/pass-through.c |    7 +++++++
 1 files changed, 7 insertions(+)

diff -r 6692c3646914 -r 8951c3b84e2a tools/ioemu/hw/pass-through.c
--- a/tools/ioemu/hw/pass-through.c     Fri Aug 01 09:54:13 2008 +0100
+++ b/tools/ioemu/hw/pass-through.c     Fri Aug 01 09:54:54 2008 +0100
@@ -1528,6 +1528,13 @@ static int pt_bar_reg_parse(
     if (!r->size)
         goto out;
 
+    /* for ExpROM BAR */
+    if (index == PCI_ROM_SLOT)
+    {
+        bar_flag = PT_BAR_FLAG_MEM;
+        goto out;
+    }
+
     /* check BAR I/O indicator */
     if (d->config[reg->offset] & PCI_BASE_ADDRESS_SPACE_IO)
         bar_flag = PT_BAR_FLAG_IO;

_______________________________________________
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, passthrough: fix flag for expansion rom base address register., Xen patchbot-unstable <=