Skip to content

Commit

Permalink
linux-user/loongarch64: Fix setup_extcontext alloc wrong fpu_context …
Browse files Browse the repository at this point in the history
…size

See:
 https://github.com/torvalds/linux/blob/master/arch/loongarch/kernel/signal.c

The alloc size is sizeof(struct target_fpu_context).

Signed-off-by: Song Gao <gaosong@loongson.cn>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-Id: <20231101030816.2353416-3-gaosong@loongson.cn>
  • Loading branch information
gaosong-loongson committed Nov 3, 2023
1 parent 91ffd93 commit 420756c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion linux-user/loongarch64/signal.c
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ static abi_ptr setup_extcontext(struct extctx_layout *extctx, abi_ptr sp)
/* For qemu, there is no lazy fp context switch, so fp always present. */
extctx->flags = SC_USED_FP;
sp = extframe_alloc(extctx, &extctx->fpu,
sizeof(struct target_rt_sigframe), FPU_CTX_ALIGN, sp);
sizeof(struct target_fpu_context), FPU_CTX_ALIGN, sp);

return sp;
}
Expand Down

0 comments on commit 420756c

Please sign in to comment.