On 05/08/2014 09:09 AM, Paolo Bonzini wrote:
> diff --git a/include/exec/cpu_ldst.h b/include/exec/cpu_ldst.h
> index a6b7884..e5550e7 100644
> --- a/include/exec/cpu_ldst.h
> +++ b/include/exec/cpu_ldst.h
> @@ -28,8 +28,373 @@
>  #ifndef CPU_LDST_H
>  #define CPU_LDST_H
>  
> -#if !defined(CONFIG_USER_ONLY)
> -#include "exec/softmmu_exec.h"
> +#if defined(CONFIG_USER_ONLY)
> +/* All direct uses of g2h and h2g need to go away for usermode softmmu.  */
> +#define g2h(x) ((void *)((unsigned long)(target_ulong)(x) + GUEST_BASE))

As an extremely minor nit, I'd prefer CONFIG_SOFTMMU be the conditional checked
here, so that, as the comment notes, one day we can have CONFIG_SOFTMMU and
CONFIG_USER_ONLY defined at the same time.


r~

Reply via email to