mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-25 11:01:52 -06:00
target/microblaze: mbar: Trap sleeps from user-space
Trap mbar-sleeps from user-space. Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Reported-by: Richard Henderson <richard.henderson@linaro.org> Signed-off-by: Edgar E. Iglesias <edgar.iglesias@xilinx.com>
This commit is contained in:
parent
d449561b13
commit
b4919e7dd3
1 changed files with 5 additions and 0 deletions
|
@ -1250,6 +1250,11 @@ static void dec_br(DisasContext *dc)
|
|||
|
||||
LOG_DIS("sleep\n");
|
||||
|
||||
if (trap_userspace(dc, true)) {
|
||||
/* Sleep is a privileged instruction. */
|
||||
return;
|
||||
}
|
||||
|
||||
t_sync_flags(dc);
|
||||
tcg_gen_st_i32(tmp_1, cpu_env,
|
||||
-offsetof(MicroBlazeCPU, env)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue