On 6/16/21 3:11 AM, Richard Henderson wrote:
> Split out setup_sigreturn so that we can continue to
> initialize the words on the stack, as documented.
> However, use the off-stack trampoline.
> 
> Cc: Edgar E. Iglesias <edgar.igles...@gmail.com>
> Signed-off-by: Richard Henderson <richard.hender...@linaro.org>
> ---
>  linux-user/cris/target_signal.h |  2 ++
>  linux-user/cris/signal.c        | 29 +++++++++++++++++++++--------
>  2 files changed, 23 insertions(+), 8 deletions(-)

> +void setup_sigtramp(abi_ulong sigtramp_page)
> +{
> +    uint16_t *tramp = lock_user(VERIFY_WRITE, sigtramp_page, 4 * 2, 0);

3 * 2?

> +    assert(tramp != NULL);
> +
> +    default_sigreturn = sigtramp_page;
> +    setup_sigreturn(tramp);
> +
> +    unlock_user(tramp, sigtramp_page, 4 * 2);

Ditto.

> +}
> 


Reply via email to