qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 23/28] target/m68k: Use cpu_*_mmuidx_ra instead of MMU_MODE{0


From: Laurent Vivier
Subject: Re: [PATCH 23/28] target/m68k: Use cpu_*_mmuidx_ra instead of MMU_MODE{0,1}_SUFFIX
Date: Thu, 12 Dec 2019 09:53:50 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.2.2

Le 12/12/2019 à 05:00, Richard Henderson a écrit :
> The generated *_user functions are unused.  The *_kernel functions
> have a couple of users in op_helper.c; use *_mmuidx_ra instead,
> with MMU_KERNEL_IDX.
> 
> Cc: Laurent Vivier <address@hidden>
> Signed-off-by: Richard Henderson <address@hidden>
> ---
>  target/m68k/cpu.h       | 2 --
>  target/m68k/op_helper.c | 5 +++++
>  2 files changed, 5 insertions(+), 2 deletions(-)
> 
> diff --git a/target/m68k/cpu.h b/target/m68k/cpu.h
> index 20de3c379a..89af14e899 100644
> --- a/target/m68k/cpu.h
> +++ b/target/m68k/cpu.h
> @@ -516,8 +516,6 @@ enum {
>  #define cpu_list m68k_cpu_list
>  
>  /* MMU modes definitions */
> -#define MMU_MODE0_SUFFIX _kernel
> -#define MMU_MODE1_SUFFIX _user
>  #define MMU_KERNEL_IDX 0
>  #define MMU_USER_IDX 1
>  static inline int cpu_mmu_index (CPUM68KState *env, bool ifetch)
> diff --git a/target/m68k/op_helper.c b/target/m68k/op_helper.c
> index bc4f845e3f..96a4951c21 100644
> --- a/target/m68k/op_helper.c
> +++ b/target/m68k/op_helper.c
> @@ -36,6 +36,11 @@ static inline void do_interrupt_m68k_hardirq(CPUM68KState 
> *env)
>  
>  #else
>  
> +#define cpu_lduw_kernel(e, p)    cpu_lduw_mmuidx_ra(e, p, MMU_KERNEL_IDX, 0)
> +#define cpu_ldl_kernel(e, p)     cpu_ldl_mmuidx_ra(e, p, MMU_KERNEL_IDX, 0)
> +#define cpu_stw_kernel(e, p, v)  cpu_stw_mmuidx_ra(e, p, v, MMU_KERNEL_IDX, 
> 0)
> +#define cpu_stl_kernel(e, p, v)  cpu_stl_mmuidx_ra(e, p, v, MMU_KERNEL_IDX, 
> 0)
> +
>  static void cf_rte(CPUM68KState *env)
>  {
>      uint32_t sp;
> 

Reviewed-by: Laurent Vivier <address@hidden>



reply via email to

[Prev in Thread] Current Thread [Next in Thread]