mirror of
https://git.FreeBSD.org/src.git
synced 2025-01-17 15:27:36 +00:00
Align upcall stack top to odd times of 8. GCC accounts return address
in callee function for stack alignment.
This commit is contained in:
parent
c5262d75ed
commit
74bbb26b51
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=117985
@ -292,6 +292,7 @@ cpu_set_upcall_kse(struct thread *td, struct kse_upcall *ku)
|
||||
*/
|
||||
td->td_frame->tf_rsp =
|
||||
((register_t)ku->ku_stack.ss_sp + ku->ku_stack.ss_size) & ~0x0f;
|
||||
td->td_frame->tf_rsp -= 8;
|
||||
td->td_frame->tf_rip = (register_t)ku->ku_func;
|
||||
|
||||
/*
|
||||
|
Loading…
Reference in New Issue
Block a user