From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:54306) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Vd4e9-0004VY-63 for qemu-devel@nongnu.org; Sun, 03 Nov 2013 15:51:51 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Vd4e3-0001in-6m for qemu-devel@nongnu.org; Sun, 03 Nov 2013 15:51:45 -0500 Received: from mx1.redhat.com ([209.132.183.28]:31591) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Vd4e2-0001ij-Uz for qemu-devel@nongnu.org; Sun, 03 Nov 2013 15:51:39 -0500 From: Marcel Apfelbaum Date: Sun, 3 Nov 2013 22:48:43 +0200 Message-Id: <1383511723-11228-1-git-send-email-marcel.a@redhat.com> Subject: [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: qemu-devel@nongnu.org Cc: peter.maydell@linaro.org, mst@redhat.com, jan.kiszka@siemens.com, anthony@codemonkey.ws, pbonzini@redhat.com, afaerber@suse.de, rth@twiddle.net The commit: Commit: a53ae8e934cd54686875b5bcfc2f434244ee55d6 Author: Marcel Apfelbaum Date: Mon Sep 16 11:21:16 2013 +0300 hw/pci: partially handle pci master abort introduced a regression on make check: qemu-system-mips64el: /home/andreas/QEMU/qemu-cpu/exec.c:802: register_subpage: Assertion `existing->mr->subpage || existing->mr == &io_mem_unassigned' failed. The problem appears when a root memory region within an address space with size < UINT64_MAX has overlapping children with the same size. If the size of the root memory region is UINT64_MAX everyting is ok. Solved the regression by making the system-memory region of size UINT64_MAX instead of INT64_MAX. Signed-off-by: Marcel Apfelbaum --- In the mean time I am investigating why the root memory region has to be UINT64_MAX size in order to have overlapping children exec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/exec.c b/exec.c index b453713..8715cf4 100644 --- a/exec.c +++ b/exec.c @@ -1741,7 +1741,7 @@ void address_space_destroy_dispatch(AddressSpace *as) static void memory_map_init(void) { system_memory = g_malloc(sizeof(*system_memory)); - memory_region_init(system_memory, NULL, "system", INT64_MAX); + memory_region_init(system_memory, NULL, "system", UINT64_MAX); address_space_init(&address_space_memory, system_memory, "memory"); system_io = g_malloc(sizeof(*system_io)); -- 1.8.3.1