]> xenbits.xensource.com Git - qemu-xen.git/commitdiff
target/openrisc: Fix mtspr shadow gprs
authorRichard Henderson <richard.henderson@linaro.org>
Wed, 27 Jun 2018 15:40:23 +0000 (08:40 -0700)
committerStafford Horne <shorne@gmail.com>
Mon, 2 Jul 2018 13:31:59 +0000 (22:31 +0900)
Missing break when this feature was added in 89e71e873d
("target/openrisc: implement shadow registers").  This was causing
strange issues as we get writes into the translation block jump cache
and other bits of state.

Fixes: 89e71e873d ("target/openrisc: implement shadow registers")
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Stafford Horne <shorne@gmail.com>
target/openrisc/sys_helper.c

index b2840643812fee117c89499a634e86ab5515618a..2f337363ec13ddd1ceffc23d83446a8c80db35bf 100644 (file)
@@ -98,6 +98,7 @@ void HELPER(mtspr)(CPUOpenRISCState *env,
     case TO_SPR(0, 1024) ... TO_SPR(0, 1024 + (16 * 32)): /* Shadow GPRs */
         idx = (spr - 1024);
         env->shadow_gpr[idx / 32][idx % 32] = rb;
+        break;
 
     case TO_SPR(1, 512) ... TO_SPR(1, 512+DTLB_SIZE-1): /* DTLBW0MR 0-127 */
         idx = spr - TO_SPR(1, 512);