aboutsummaryrefslogtreecommitdiff
path: root/target/ppc/ppc-qmp-cmds.c
diff options
context:
space:
mode:
Diffstat (limited to 'target/ppc/ppc-qmp-cmds.c')
-rw-r--r--target/ppc/ppc-qmp-cmds.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/target/ppc/ppc-qmp-cmds.c b/target/ppc/ppc-qmp-cmds.c
index ee0b99fce7..a25d86a8d1 100644
--- a/target/ppc/ppc-qmp-cmds.c
+++ b/target/ppc/ppc-qmp-cmds.c
@@ -137,8 +137,7 @@ static int ppc_cpu_get_reg_num(const char *numstr, int maxnum, int *pregnum)
int target_get_monitor_def(CPUState *cs, const char *name, uint64_t *pval)
{
int i, regnum;
- PowerPCCPU *cpu = POWERPC_CPU(cs);
- CPUPPCState *env = &cpu->env;
+ CPUPPCState *env = cpu_env(cs);
/* General purpose registers */
if ((qemu_tolower(name[0]) == 'r') &&