From: Marcelo Tosatti
>
>Index: kvm-userspace.hotplug2/qemu/hw/pci.c
>===================================================================
>--- kvm-userspace.hotplug2.orig/qemu/hw/pci.c
>+++ kvm-userspace.hotplug2/qemu/hw/pci.c
>@@ -236,6 +236,13 @@ void pci_register_io_region(PCIDevice *p
>
>     if ((unsigned int)region_num >= PCI_NUM_REGIONS)
>         return;
>+
>+    /* IO region size must be power of two */
>+    if (type == PCI_ADDRESS_SPACE_IO && (size & (size-1))) {

Why only for PCI IO regions ? Don't PCI memory regions have the same 
restriction ?

>+        size = size << 1;
>+        size &= size-1;

That would not make size a power of 2 (e.g. size=7 --> size=12).

>+    }
>+

Regards,
Uri.
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel

Reply via email to