diff options
author | Paolo Bonzini <pbonzini@redhat.com> | 2016-10-31 10:36:08 +0100 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2016-10-31 15:00:25 +0100 |
commit | 14e6fe12a705c065fecdfd2a97199728123d4d9a (patch) | |
tree | c78875a95ca8fa9f6bac7dc95a1415f5dbfb7cfc /hw/ppc/ppce500_spin.c | |
parent | 12e9700d7a926aeb7f97a5d3c368bbe6745be884 (diff) | |
download | qemu-14e6fe12a705c065fecdfd2a97199728123d4d9a.zip qemu-14e6fe12a705c065fecdfd2a97199728123d4d9a.tar.gz qemu-14e6fe12a705c065fecdfd2a97199728123d4d9a.tar.bz2 |
*_run_on_cpu: introduce run_on_cpu_data type
This changes the *_run_on_cpu APIs (and helpers) to pass data in a
run_on_cpu_data type instead of a plain void *. This is because we
sometimes want to pass a target address (target_ulong) and this fails on
32 bit hosts emulating 64 bit guests.
Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
Message-Id: <20161027151030.20863-24-alex.bennee@linaro.org>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'hw/ppc/ppce500_spin.c')
-rw-r--r-- | hw/ppc/ppce500_spin.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/hw/ppc/ppce500_spin.c b/hw/ppc/ppce500_spin.c index 8e16f65..cf958a9 100644 --- a/hw/ppc/ppce500_spin.c +++ b/hw/ppc/ppce500_spin.c @@ -84,11 +84,11 @@ static void mmubooke_create_initial_mapping(CPUPPCState *env, env->tlb_dirty = true; } -static void spin_kick(CPUState *cs, void *data) +static void spin_kick(CPUState *cs, run_on_cpu_data data) { PowerPCCPU *cpu = POWERPC_CPU(cs); CPUPPCState *env = &cpu->env; - SpinInfo *curspin = data; + SpinInfo *curspin = data.host_ptr; hwaddr map_size = 64 * 1024 * 1024; hwaddr map_start; @@ -147,7 +147,7 @@ static void spin_write(void *opaque, hwaddr addr, uint64_t value, if (!(ldq_p(&curspin->addr) & 1)) { /* run CPU */ - run_on_cpu(cpu, spin_kick, curspin); + run_on_cpu(cpu, spin_kick, RUN_ON_CPU_HOST_PTR(curspin)); } } |