Received: from eggs.gnu.org ([2001:4830:134:3::10]:47458) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bShIW-0001lg-4Y for qemu-devel@nongnu.org; Thu, 28 Jul 2016 05:08:09 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bShIR-0002gf-OY for qemu-devel@nongnu.org; Thu, 28 Jul 2016 05:08:06 -0400 Received: from mailapp01.imgtec.com ([195.59.15.196]:60453) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bShIR-0002ga-IF for qemu-devel@nongnu.org; Thu, 28 Jul 2016 05:08:03 -0400 From: Leon Alrae Date: Thu, 28 Jul 2016 10:07:28 +0100 Message-ID: <1469696848-9870-1-git-send-email-leon.alrae@imgtec.com> MIME-Version: 1.0 Content-Type: text/plain Subject: [Qemu-devel] [PATCH] target-mips: fix EntryHi.EHINV being cleared on TLB exception List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: aurelien@aurel32.net While implementing TLB invalidation feature we forgot to modify part of code responsible for updating EntryHi during TLB exception. Consequently EntryHi.EHINV is unexpectedly cleared on the exception. Signed-off-by: Leon Alrae --- target-mips/helper.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/target-mips/helper.c b/target-mips/helper.c index 9fbca26..c864b15 100644 --- a/target-mips/helper.c +++ b/target-mips/helper.c @@ -396,6 +396,7 @@ static void raise_mmu_exception(CPUMIPSState *env, target_ulong address, env->CP0_Context = (env->CP0_Context & ~0x007fffff) | ((address >> 9) & 0x007ffff0); env->CP0_EntryHi = (env->CP0_EntryHi & env->CP0_EntryHi_ASID_mask) | + (env->CP0_EntryHi & (1 << CP0EnHi_EHINV)) | (address & (TARGET_PAGE_MASK << 1)); #if defined(TARGET_MIPS64) env->CP0_EntryHi &= env->SEGMask; -- 1.7.1