From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:37119) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Upg70-0006aA-26 for qemu-devel@nongnu.org; Thu, 20 Jun 2013 10:45:26 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Upg6v-00079V-9t for qemu-devel@nongnu.org; Thu, 20 Jun 2013 10:45:21 -0400 Received: from mail-ee0-x22d.google.com ([2a00:1450:4013:c00::22d]:64350) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Upg6v-00079P-3k for qemu-devel@nongnu.org; Thu, 20 Jun 2013 10:45:17 -0400 Received: by mail-ee0-f45.google.com with SMTP id c1so3994999eek.4 for ; Thu, 20 Jun 2013 07:45:16 -0700 (PDT) Received: from playground.lan (net-37-116-217-184.cust.dsl.vodafone.it. [37.116.217.184]) by mx.google.com with ESMTPSA id y10sm973958eev.3.2013.06.20.07.45.14 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Thu, 20 Jun 2013 07:45:15 -0700 (PDT) Sender: Paolo Bonzini From: Paolo Bonzini Date: Thu, 20 Jun 2013 16:44:36 +0200 Message-Id: <1371739493-10187-9-git-send-email-pbonzini@redhat.com> In-Reply-To: <1371739493-10187-1-git-send-email-pbonzini@redhat.com> References: <1371739493-10187-1-git-send-email-pbonzini@redhat.com> Subject: [Qemu-devel] [PATCH 08/25] Revert "memory: limit sections in the radix tree to the actual address space size" List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org This reverts commit 86a8623692b1b559a419a92eb8b6897c221bca74. Signed-off-by: Paolo Bonzini --- exec.c | 13 +------------ include/exec/memory.h | 3 --- 2 files changed, 1 insertion(+), 15 deletions(-) diff --git a/exec.c b/exec.c index 3a8ef42..0448224 100644 --- a/exec.c +++ b/exec.c @@ -835,21 +835,10 @@ static void register_multipage(AddressSpaceDispatch *d, MemoryRegionSection *sec section_index); } -QEMU_BUILD_BUG_ON(TARGET_PHYS_ADDR_SPACE_BITS > MAX_PHYS_ADDR_SPACE_BITS) - -static MemoryRegionSection limit(MemoryRegionSection section) -{ - section.size = MIN(section.offset_within_address_space + section.size, - MAX_PHYS_ADDR + 1) - - section.offset_within_address_space; - - return section; -} - static void mem_add(MemoryListener *listener, MemoryRegionSection *section) { AddressSpaceDispatch *d = container_of(listener, AddressSpaceDispatch, listener); - MemoryRegionSection now = limit(*section), remain = limit(*section); + MemoryRegionSection now = *section, remain = *section; if ((now.offset_within_address_space & ~TARGET_PAGE_MASK) || (now.size < TARGET_PAGE_SIZE)) { diff --git a/include/exec/memory.h b/include/exec/memory.h index c747f67..c11a3f8 100644 --- a/include/exec/memory.h +++ b/include/exec/memory.h @@ -26,9 +26,6 @@ #include "exec/ioport.h" #include "qemu/int128.h" -#define MAX_PHYS_ADDR_SPACE_BITS 62 -#define MAX_PHYS_ADDR (((hwaddr)1 << MAX_PHYS_ADDR_SPACE_BITS) - 1) - typedef struct MemoryRegionOps MemoryRegionOps; typedef struct MemoryRegionPortio MemoryRegionPortio; typedef struct MemoryRegionMmio MemoryRegionMmio; -- 1.8.1.4