From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:34028) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VeXP3-0000kQ-QY for qemu-devel@nongnu.org; Thu, 07 Nov 2013 16:46:19 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VeXOx-0007ya-Q2 for qemu-devel@nongnu.org; Thu, 07 Nov 2013 16:46:13 -0500 Received: from mx1.redhat.com ([209.132.183.28]:49431) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VeXOx-0007yP-Fr for qemu-devel@nongnu.org; Thu, 07 Nov 2013 16:46:07 -0500 Message-ID: <527C0AB8.7080105@redhat.com> Date: Thu, 07 Nov 2013 22:48:40 +0100 From: Laszlo Ersek MIME-Version: 1.0 References: <1383511723-11228-1-git-send-email-marcel.a@redhat.com> <527C023F.2060506@redhat.com> <1383859470.2527.64.camel@localhost.localdomain> In-Reply-To: <1383859470.2527.64.camel@localhost.localdomain> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH] exec: fix regression by making system-memory region UINT64_MAX size List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Marcel Apfelbaum Cc: Peter Maydell , "Michael S. Tsirkin" , Jan Kiszka , "edk2-devel@lists.sourceforge.net" , qemu-devel , Anthony Liguori , Paolo Bonzini , Jordan Justen , afaerber , rth@twiddle.net On 11/07/13 22:24, Marcel Apfelbaum wrote: > On Thu, 2013-11-07 at 22:12 +0100, Laszlo Ersek wrote: >> adding subregion 'pci-hole' to region 'system' at offset 60000000 >> warning: subregion collision 60000000/a0000000 (pci-hole) vs ffe00000/200000 (system.flash) > Thank you Laszlo for the detailed info! > I think the problem is right above. Why pci-hole and system.flash collide? > IMHO we should not play with priorities here, better solve the collision. pc_init1() pc_memory_init() pc_system_firmware_init() pc_system_flash_init() <---- sets base address to 0x100000000ULL - flash_size pflash_cfi01_register() sysbus_mmio_map() sysbus_mmio_map_common() memory_region_add_subregion() i440fx_init() memory_region_init_alias("pci-hole") pc_init1() passes 0x100000000ULL - below_4g_mem_size to i440fx_init() as "pci_hole_size", which is then used as the size of the "pci-hole" alias. We should probably subtract the size of the flash from this, but I don't know how to do that "elegantly". Yet another (output) parameter for pc_memory_init()? Blech. Or look up the end address of "system.flash" by name? Thanks Laszlo