mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-07 17:53:56 -06:00
cpu: Introduce cpu_set_cpustate_pointers
Consolidate some boilerplate from foo_cpu_initfn. 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>
This commit is contained in:
parent
677c4d69ac
commit
7506ed902e
22 changed files with 37 additions and 48 deletions
|
@ -221,11 +221,10 @@ static void mb_cpu_realizefn(DeviceState *dev, Error **errp)
|
|||
|
||||
static void mb_cpu_initfn(Object *obj)
|
||||
{
|
||||
CPUState *cs = CPU(obj);
|
||||
MicroBlazeCPU *cpu = MICROBLAZE_CPU(obj);
|
||||
CPUMBState *env = &cpu->env;
|
||||
|
||||
cs->env_ptr = env;
|
||||
cpu_set_cpustate_pointers(cpu);
|
||||
|
||||
set_float_rounding_mode(float_round_nearest_even, &env->fp_status);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue