From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:35933) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XLsi5-0000VM-0h for qemu-devel@nongnu.org; Mon, 25 Aug 2014 07:45:22 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XLsi0-0003wO-7s for qemu-devel@nongnu.org; Mon, 25 Aug 2014 07:45:16 -0400 Received: from mx1.redhat.com ([209.132.183.28]:52057) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XLsi0-0003vA-02 for qemu-devel@nongnu.org; Mon, 25 Aug 2014 07:45:12 -0400 Message-ID: <53FB21C1.2020304@redhat.com> Date: Mon, 25 Aug 2014 13:45:05 +0200 From: Paolo Bonzini MIME-Version: 1.0 References: <1407752887-6351-1-git-send-email-m.ilin@samsung.com> In-Reply-To: <1407752887-6351-1-git-send-email-m.ilin@samsung.com> Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH] translate-all.c: fix debug memory maps printing List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Mikhail Ilyin , qemu-devel@nongnu.org Cc: peter.maydell@linaro.org, mst@redhat.com, afaerber@suse.de, rth@twiddle.net Il 11/08/2014 12:28, Mikhail Ilyin ha scritto: > Fix memory maps textualizing function. The output was not correct because of > wrong base address calculation. The initial address has to be shifted also > for TARGET_PAGE_BITS. > > Signed-off-by: Mikhail Ilyin > --- > translate-all.c | 3 +-- > 1 file changed, 1 insertion(+), 2 deletions(-) > > diff --git a/translate-all.c b/translate-all.c > index 8f7e11b..cb7a33d 100644 > --- a/translate-all.c > +++ b/translate-all.c > @@ -1728,9 +1728,8 @@ int walk_memory_regions(void *priv, walk_memory_regions_fn fn) > data.prot = 0; > > for (i = 0; i < V_L1_SIZE; i++) { > - int rc = walk_memory_regions_1(&data, (abi_ulong)i << V_L1_SHIFT, > + int rc = walk_memory_regions_1(&data, (abi_ulong)i << (V_L1_SHIFT + TARGET_PAGE_BITS), > V_L1_SHIFT / V_L2_BITS - 1, l1_map + i); > - > if (rc != 0) { > return rc; > } > Thanks, this is simple enough that I've queued it. Paolo