From: Edgar E. Iglesias Date: Mon, 11 Jan 2010 14:23:58 +0000 (+0100) Subject: ppc-40x: Correct decoding of zone protection bits. X-Git-Tag: TizenStudio_2.0_p2.3~5982 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=d854784184b5315431e9da78f69571d4b9189d0a;p=sdk%2Femulator%2Fqemu.git ppc-40x: Correct decoding of zone protection bits. The 40x MMU has 15 zones in the ZPR register. Signed-off-by: Edgar E. Iglesias --- diff --git a/target-ppc/helper.c b/target-ppc/helper.c index b233d4f..f9b5589 100644 --- a/target-ppc/helper.c +++ b/target-ppc/helper.c @@ -1155,7 +1155,7 @@ static int mmu40x_get_physical_address (CPUState *env, mmu_ctx_t *ctx, env->spr[SPR_40x_PID], 0, i) < 0) continue; zsel = (tlb->attr >> 4) & 0xF; - zpr = (env->spr[SPR_40x_ZPR] >> (28 - (2 * zsel))) & 0x3; + zpr = (env->spr[SPR_40x_ZPR] >> (30 - (2 * zsel))) & 0x3; LOG_SWTLB("%s: TLB %d zsel %d zpr %d rw %d attr %08x\n", __func__, i, zsel, zpr, rw, tlb->attr); /* Check execute enable bit */