aarch64: Fix the extension header write in getcontext and swapcontext

The extension header is two 32bit words and in the last header both
should be 0. There is plenty space in the __reserved area, but it's
better not to write more than we mean to.
This commit is contained in:
Szabolcs Nagy 2022-07-29 08:00:06 +01:00
parent dd31f42e39
commit 09c6c6073c
2 changed files with 4 additions and 4 deletions

View File

@ -86,8 +86,8 @@ ENTRY(__getcontext)
/* Write the termination context extension header. */
add x2, x2, #FPSIMD_CONTEXT_SIZE
str xzr, [x2, #oHEAD + oMAGIC]
str xzr, [x2, #oHEAD + oSIZE]
str wzr, [x2, #oHEAD + oMAGIC]
str wzr, [x2, #oHEAD + oSIZE]
/* Grab the signal mask */
/* rt_sigprocmask (SIG_BLOCK, NULL, &ucp->uc_sigmask, _NSIG8) */

View File

@ -75,8 +75,8 @@ ENTRY(__swapcontext)
/* Write the termination context extension header. */
add x2, x2, #FPSIMD_CONTEXT_SIZE
str xzr, [x2, #oHEAD + oMAGIC]
str xzr, [x2, #oHEAD + oSIZE]
str wzr, [x2, #oHEAD + oMAGIC]
str wzr, [x2, #oHEAD + oSIZE]
/* Preserve ucp. */
mov x21, x1