From patchwork Wed Jul 2 17:16:23 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexander Graf X-Patchwork-Id: 366433 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 9F8BC1400E8 for ; Thu, 3 Jul 2014 03:16:56 +1000 (EST) Received: from localhost ([::1]:55645 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1X2O9O-0000aF-P8 for incoming@patchwork.ozlabs.org; Wed, 02 Jul 2014 13:16:54 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:33582) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1X2O92-0000FM-39 for qemu-devel@nongnu.org; Wed, 02 Jul 2014 13:16:39 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1X2O8u-0007Gp-Dl for qemu-devel@nongnu.org; Wed, 02 Jul 2014 13:16:32 -0400 Received: from cantor2.suse.de ([195.135.220.15]:56962 helo=mx2.suse.de) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1X2O8u-0007Gk-78; Wed, 02 Jul 2014 13:16:24 -0400 Received: from relay1.suse.de (charybdis-ext.suse.de [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id B8A2BAB13; Wed, 2 Jul 2014 17:16:23 +0000 (UTC) From: Alexander Graf To: qemu-ppc@nongnu.org Date: Wed, 2 Jul 2014 19:16:23 +0200 Message-Id: <1404321383-18542-1-git-send-email-agraf@suse.de> X-Mailer: git-send-email 1.7.12.4 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no timestamps) [generic] X-Received-From: 195.135.220.15 Cc: qemu-devel@nongnu.org Subject: [Qemu-devel] [PATCH for-2.1] PPC: Fix booke206 TLB with phys addrs > 32bit X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org We were truncating physical addresses to 32bit when using qemu-system-ppc with a booke206 TLB implementation. This patch fixes that and makes the full address space available. Signed-off-by: Alexander Graf --- target-ppc/mmu_helper.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/target-ppc/mmu_helper.c b/target-ppc/mmu_helper.c index 4d6b1e2..4a34a73 100644 --- a/target-ppc/mmu_helper.c +++ b/target-ppc/mmu_helper.c @@ -897,10 +897,10 @@ static hwaddr booke206_tlb_to_page_size(CPUPPCState *env, /* TLB check function for MAS based SoftTLBs */ static int ppcmas_tlb_check(CPUPPCState *env, ppcmas_tlb_t *tlb, - hwaddr *raddrp, - target_ulong address, uint32_t pid) + hwaddr *raddrp, target_ulong address, + uint32_t pid) { - target_ulong mask; + hwaddr mask; uint32_t tlb_pid; if (!msr_cm) {