Round TF_SIZE up to the stack alignment (16-bytes).
The kernel adjusts the stack by TF_SIZE and the RISC-V ABI requires that it remain 16-byte aligned. Reported by: CHERI, jrtc27 Reviewed by: mhorne Obtained from: CheriBSD Sponsored by: DARPA Differential Revision: https://reviews.freebsd.org/D26328
This commit is contained in:
parent
29e1fceb73
commit
46b974a9db
@ -87,7 +87,7 @@ ASSYM(TD_FRAME, offsetof(struct thread, td_frame));
|
||||
ASSYM(TD_MD, offsetof(struct thread, td_md));
|
||||
ASSYM(TD_LOCK, offsetof(struct thread, td_lock));
|
||||
|
||||
ASSYM(TF_SIZE, sizeof(struct trapframe));
|
||||
ASSYM(TF_SIZE, roundup2(sizeof(struct trapframe), STACKALIGNBYTES + 1));
|
||||
ASSYM(TF_RA, offsetof(struct trapframe, tf_ra));
|
||||
ASSYM(TF_SP, offsetof(struct trapframe, tf_sp));
|
||||
ASSYM(TF_GP, offsetof(struct trapframe, tf_gp));
|
||||
|
Loading…
Reference in New Issue
Block a user