pc: fix regression for 64 bit PCI memory
authorMichael S. Tsirkin <mst@redhat.com>
Tue, 27 Aug 2013 05:37:26 +0000 (08:37 +0300)
committerSeokYeon Hwang <syeon.hwang@samsung.com>
Thu, 7 Nov 2013 04:48:34 +0000 (13:48 +0900)
commit481c2b91b8a7530feea6b2ad4900769b87719cb7
treeed5b3e3de68ec9868a6ee1c204dcc8cb25f42af7
parentee76a5e34fb4d4f358668b1d1f3552b12f0be1f1
pc: fix regression for 64 bit PCI memory

commit 398489018183d613306ab022653552247d93919f
    pc: limit 64 bit hole to 2G by default
introduced a way for management to control
the window allocated to the 64 bit PCI hole.

This is useful, but existing management tools do not know how to set
this property.  As a result, e.g. specifying a large ivshmem device with
size > 4G is broken by default.  For example this configuration no
longer works:

-device ivshmem,size=4294967296,chardev=cfoo
-chardev socket,path=/tmp/sock,id=cfoo,server,nowait

Fix this by detecting that hole size was not specified
and defaulting to the backwards-compatible value of 1 << 62.

Cc: qemu-stable@nongnu.org
Cc: Igor Mammedov <imammedo@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
(cherry picked from commit 1466cef32dd5e7ef3c6477e96d85d92302ad02e3)

Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
hw/pci-host/piix.c
hw/pci-host/q35.c
include/hw/i386/pc.h