Yuji Shimada
2008-Aug-28 08:11 UTC
[Xen-devel] [PATCH 0/2] make upper field of 64 bit bar writable.
This series of patches makes upper field of 64 bit base address register writable for pass-through device. 1. update ioemu-remote&ioemu to make upper field of 64 bit base address register writable. 2. update hvmloader to skip upper field of 64 bit base address register. Current hvmloader does not handle 64 bit base address register, while some devices have 64 bit base address register. To prevent hvmloader to set some value to upper field of 64 bit base address register, the field is hardwired to 0 by ioemu&ioemu-remote currently. Upper field of 64 bit base address register should be writable to follow pci spec. So the series of patches update both ioemu-remote&ioemu and hvmloader. Thanks, -- Yuji Shimada _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Yuji Shimada
2008-Aug-28 08:15 UTC
[Xen-devel] [PATCH 2/2] hvmloader: skip upper field of 64 bit base address register.
This patch skips upper field of 64 bit base address register. Signed-off-by: Yuji Shimada <shimada-yxb@necst.nec.co.jp> diff -r 598d92a5ae7a tools/firmware/hvmloader/hvmloader.c --- a/tools/firmware/hvmloader/hvmloader.c Wed Aug 20 14:45:21 2008 +0100 +++ b/tools/firmware/hvmloader/hvmloader.c Mon Aug 25 10:18:07 2008 +0900 @@ -243,6 +243,14 @@ bars[i].bar_sz = bar_sz; nr_bars++; + + /* skip the upper address for 64bit BAR */ + if ((bar_data & (PCI_BASE_ADDRESS_SPACE | + PCI_BASE_ADDRESS_MEM_TYPE_MASK)) == + (PCI_BASE_ADDRESS_SPACE_MEMORY | + PCI_BASE_ADDRESS_MEM_TYPE_64)) + bar++; + } /* Map the interrupt. */ _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Yuji Shimada
2008-Aug-28 08:15 UTC
[Xen-devel] [PATCH 1/2] ioemu-remote&ioemu: make upper field of 64 bit bar writable.
This patch makes upper field of 64 bit base address register writable. Signed-off-by: Yuji Shimada <shimada-yxb@necst.nec.co.jp> diff --git a/hw/pass-through.c b/hw/pass-through.c index 51d0a12..6b08441 100644 --- a/hw/pass-through.c +++ b/hw/pass-through.c @@ -2338,11 +2338,6 @@ static int pt_bar_reg_write(struct pt_dev *ptdev, return -1; } - /* always keep the emulate register value to 0, - * because hvmloader does not support high MMIO for now. - */ - cfg_entry->data = 0; - /* never mapping the ''empty'' upper region, * because we''ll do it enough for the lower region. */ _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel