[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v2 1/2] monitor: Split mon_get_cpu fn to remove
From: |
Markus Armbruster |
Subject: |
Re: [Qemu-devel] [PATCH v2 1/2] monitor: Split mon_get_cpu fn to remove ENV_GET_CPU |
Date: |
Fri, 12 Jun 2015 08:07:10 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) |
Peter Crosthwaite <address@hidden> writes:
> The monitor currently has one helper, mon_get_cpu() which will return
> an env pointer. The target specific users of this API want an env, but
> all the target agnostic users really just want the cpu pointer. These
> users then need to use the target-specifically defined ENV_GET_CPU to
> navigate back up to the CPU from the ENV. Split the API for the two
> uses cases to remove all need for ENV_GET_CPU.
>
> Reviewed-by: Richard Henderson <address@hidden>
> Reviewed-by: Andreas Färber <address@hidden>
> Signed-off-by: Peter Crosthwaite <address@hidden>
> ---
> Changed since v1:
> s/mon_get_env/mon_get_cpu_env (Andreas review)
> Avoid C99 declaration (RH review)
CC x86_64-softmmu/monitor.o
/work/armbru/qemu/monitor.c: In function ‘memory_search’:
/work/armbru/qemu/monitor.c:1222:9: warning: passing argument 1 of
‘x86_env_get_cpu’ from incompatible pointer type [enabled by default]
} else if (cpu_memory_rw_debug(ENV_GET_CPU(mon_get_cpu()), addr,
^
In file included from /work/armbru/qemu/target-i386/cpu.h:982:0,
from /work/armbru/qemu/include/qemu-common.h:124,
from /work/armbru/qemu/include/hw/hw.h:5,
from /work/armbru/qemu/monitor.c:25:
/work/armbru/qemu/target-i386/cpu-qom.h:119:23: note: expected ‘struct
CPUX86State *’ but argument is of type ‘struct CPUState *’
static inline X86CPU *x86_env_get_cpu(CPUX86State *env)
^
- Re: [Qemu-devel] [PATCH v2 1/2] monitor: Split mon_get_cpu fn to remove ENV_GET_CPU,
Markus Armbruster <=