Revision 36f69651 target-ppc/translate.c

b/target-ppc/translate.c
3069 3069
}
3070 3070

  
3071 3071
/* icbi */
3072
#define op_icbi() (*gen_op_icbi[ctx->mem_idx])()
3073
#if defined(TARGET_PPC64)
3074
#if defined(CONFIG_USER_ONLY)
3075
static GenOpFunc *gen_op_icbi[] = {
3076
    &gen_op_icbi_raw,
3077
    &gen_op_icbi_raw,
3078
    &gen_op_icbi_64_raw,
3079
    &gen_op_icbi_64_raw,
3080
};
3081
#else
3082
static GenOpFunc *gen_op_icbi[] = {
3083
    &gen_op_icbi_user,
3084
    &gen_op_icbi_user,
3085
    &gen_op_icbi_kernel,
3086
    &gen_op_icbi_kernel,
3087
    &gen_op_icbi_64_user,
3088
    &gen_op_icbi_64_user,
3089
    &gen_op_icbi_64_kernel,
3090
    &gen_op_icbi_64_kernel,
3091
};
3092
#endif
3093
#else
3094
#if defined(CONFIG_USER_ONLY)
3095
static GenOpFunc *gen_op_icbi[] = {
3096
    &gen_op_icbi_raw,
3097
    &gen_op_icbi_raw,
3098
};
3099
#else
3100
static GenOpFunc *gen_op_icbi[] = {
3101
    &gen_op_icbi_user,
3102
    &gen_op_icbi_user,
3103
    &gen_op_icbi_kernel,
3104
    &gen_op_icbi_kernel,
3105
};
3106
#endif
3107
#endif
3072 3108
GEN_HANDLER(icbi, 0x1F, 0x16, 0x1E, 0x03E00001, PPC_CACHE)
3073 3109
{
3074 3110
    /* NIP cannot be restored if the memory exception comes from an helper */
3075 3111
    gen_update_nip(ctx, ctx->nip - 4);
3076 3112
    gen_addr_reg_index(ctx);
3077
#if defined(TARGET_PPC64)
3078
    if (ctx->sf_mode)
3079
        gen_op_icbi_64();
3080
    else
3081
#endif
3082
        gen_op_icbi();
3113
    op_icbi();
3083 3114
    RET_STOP(ctx);
3084 3115
}
3085 3116

  

Also available in: Unified diff