target-ppc: Make UCTRL a mirror of CTRL
authorAlexey Kardashevskiy <aik@ozlabs.ru>
Wed, 4 Jun 2014 12:50:39 +0000 (22:50 +1000)
committerAlexander Graf <agraf@suse.de>
Mon, 16 Jun 2014 11:24:42 +0000 (13:24 +0200)
This changes UCTRL SPR to read from its supermode copy.

This enables reading from UCTRL in user mode.

Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru>
Reviewed-by: Tom Musta <tommusta@gmail.com>
Signed-off-by: Alexander Graf <agraf@suse.de>
target-ppc/translate_init.c

index 04497e428c21aad228b08d913fe3caa3fecab278..8b83b28656a6f8b1e1175e283d48b7fba60c9274 100644 (file)
@@ -7308,8 +7308,8 @@ static void gen_spr_book3s_common(CPUPPCState *env)
                  SPR_NOACCESS, &spr_write_generic,
                  0x00000000);
     spr_register(env, SPR_UCTRL, "SPR_UCTRL",
-                 SPR_NOACCESS, SPR_NOACCESS,
-                 &spr_read_generic, SPR_NOACCESS,
+                 &spr_read_ureg, SPR_NOACCESS,
+                 &spr_read_ureg, SPR_NOACCESS,
                  0x00000000);
 }