diff options
author | Richard Henderson | 2019-03-23 02:48:56 +0100 |
---|---|---|
committer | Richard Henderson | 2019-06-10 16:03:42 +0200 |
commit | 5ee2b02e926ba12946c2ce3fc6ed9913e7c94859 (patch) | |
tree | 3bdb5211d2f992587f142a358e023fd83fb4d32b /target/openrisc/exception_helper.c | |
parent | target/nios2: Use env_cpu, env_archcpu (diff) | |
download | qemu-5ee2b02e926ba12946c2ce3fc6ed9913e7c94859.tar.gz qemu-5ee2b02e926ba12946c2ce3fc6ed9913e7c94859.tar.xz qemu-5ee2b02e926ba12946c2ce3fc6ed9913e7c94859.zip |
target/openrisc: Use env_cpu, env_archcpu
Cleanup in the boilerplate that each target must define.
Replace openrisc_env_get_cpu with env_archcpu. The combination
CPU(openrisc_env_get_cpu) should have used ENV_GET_CPU to begin;
use env_cpu now.
Reviewed-by: Alistair Francis <alistair.francis@wdc.com>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Diffstat (limited to 'target/openrisc/exception_helper.c')
-rw-r--r-- | target/openrisc/exception_helper.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/target/openrisc/exception_helper.c b/target/openrisc/exception_helper.c index 0797cc9d38..d02a1cf0aa 100644 --- a/target/openrisc/exception_helper.c +++ b/target/openrisc/exception_helper.c @@ -25,15 +25,14 @@ void HELPER(exception)(CPUOpenRISCState *env, uint32_t excp) { - OpenRISCCPU *cpu = openrisc_env_get_cpu(env); + OpenRISCCPU *cpu = env_archcpu(env); raise_exception(cpu, excp); } static void QEMU_NORETURN do_range(CPUOpenRISCState *env, uintptr_t pc) { - OpenRISCCPU *cpu = openrisc_env_get_cpu(env); - CPUState *cs = CPU(cpu); + CPUState *cs = env_cpu(env); cs->exception_index = EXCP_RANGE; cpu_loop_exit_restore(cs, pc); |