Align stack pointer and backing store pointer to 16 byte boundary when

delivering signals.
This commit is contained in:
Doug Rabson 2001-04-24 15:55:47 +00:00
parent 1eaf877f2e
commit 2c7122ff0f
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=75913

View File

@ -814,6 +814,11 @@ sendsig(sig_t catcher, int sig, sigset_t *mask, u_long code)
sbs = (u_int64_t) p->p_sigstk.ss_sp;
sfp = (struct sigframe *)((caddr_t)p->p_sigstk.ss_sp +
p->p_sigstk.ss_size - rndfsize);
/*
* Align sp and bsp.
*/
sbs = (sbs + 15) & ~15;
sfp = (struct sigframe *)((u_int64_t)sfp & ~15);
#if defined(COMPAT_43) || defined(COMPAT_SUNOS)
p->p_sigstk.ss_flags |= SS_ONSTACK;
#endif