mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-18 23:52:14 -06:00
target/riscv: Enable xtheadsync under user mode
According to xtheadsync[1][2] documentation, it can be used in user mode and the behavior is same with other priviledges. [1]:https://github.com/T-head-Semi/thead-extension-spec/blob/master/xtheadsync/sync.adoc [2]:https://github.com/T-head-Semi/thead-extension-spec/blob/master/xtheadsync/sync_i.adoc Signed-off-by: LIU Zhiwei <zhiwei_liu@linux.alibaba.com> Acked-by: Alistair Francis <alistair.francis@wdc.com> Message-ID: <20240204055228.900-1-zhiwei_liu@linux.alibaba.com> Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
This commit is contained in:
parent
e2ff0dec15
commit
a65d51707d
1 changed files with 0 additions and 10 deletions
|
@ -992,7 +992,6 @@ static bool trans_th_sfence_vmas(DisasContext *ctx, arg_th_sfence_vmas *a)
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifndef CONFIG_USER_ONLY
|
|
||||||
static void gen_th_sync_local(DisasContext *ctx)
|
static void gen_th_sync_local(DisasContext *ctx)
|
||||||
{
|
{
|
||||||
/*
|
/*
|
||||||
|
@ -1003,14 +1002,12 @@ static void gen_th_sync_local(DisasContext *ctx)
|
||||||
tcg_gen_exit_tb(NULL, 0);
|
tcg_gen_exit_tb(NULL, 0);
|
||||||
ctx->base.is_jmp = DISAS_NORETURN;
|
ctx->base.is_jmp = DISAS_NORETURN;
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
static bool trans_th_sync(DisasContext *ctx, arg_th_sync *a)
|
static bool trans_th_sync(DisasContext *ctx, arg_th_sync *a)
|
||||||
{
|
{
|
||||||
(void) a;
|
(void) a;
|
||||||
REQUIRE_XTHEADSYNC(ctx);
|
REQUIRE_XTHEADSYNC(ctx);
|
||||||
|
|
||||||
#ifndef CONFIG_USER_ONLY
|
|
||||||
REQUIRE_PRIV_MSU(ctx);
|
REQUIRE_PRIV_MSU(ctx);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -1019,9 +1016,6 @@ static bool trans_th_sync(DisasContext *ctx, arg_th_sync *a)
|
||||||
gen_th_sync_local(ctx);
|
gen_th_sync_local(ctx);
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
#else
|
|
||||||
return false;
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static bool trans_th_sync_i(DisasContext *ctx, arg_th_sync_i *a)
|
static bool trans_th_sync_i(DisasContext *ctx, arg_th_sync_i *a)
|
||||||
|
@ -1029,7 +1023,6 @@ static bool trans_th_sync_i(DisasContext *ctx, arg_th_sync_i *a)
|
||||||
(void) a;
|
(void) a;
|
||||||
REQUIRE_XTHEADSYNC(ctx);
|
REQUIRE_XTHEADSYNC(ctx);
|
||||||
|
|
||||||
#ifndef CONFIG_USER_ONLY
|
|
||||||
REQUIRE_PRIV_MSU(ctx);
|
REQUIRE_PRIV_MSU(ctx);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -1038,9 +1031,6 @@ static bool trans_th_sync_i(DisasContext *ctx, arg_th_sync_i *a)
|
||||||
gen_th_sync_local(ctx);
|
gen_th_sync_local(ctx);
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
#else
|
|
||||||
return false;
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static bool trans_th_sync_is(DisasContext *ctx, arg_th_sync_is *a)
|
static bool trans_th_sync_is(DisasContext *ctx, arg_th_sync_is *a)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue