mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-24 11:29:10 +00:00
As was done in r155238 for i386 and in r155239 for amd64, clear the carry
flag for ia32 binary executed on amd64 host in get_mcontext(). PR: kern/92110 (one more time) Reported by: stas MFC after: 1 week
This commit is contained in:
parent
1c044382c3
commit
94c6c6ba67
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=206992
@ -141,9 +141,11 @@ ia32_get_mcontext(struct thread *td, struct ia32_mcontext *mcp, int flags)
|
||||
mcp->mc_esi = tp->tf_rsi;
|
||||
mcp->mc_ebp = tp->tf_rbp;
|
||||
mcp->mc_isp = tp->tf_rsp;
|
||||
mcp->mc_eflags = tp->tf_rflags;
|
||||
if (flags & GET_MC_CLEAR_RET) {
|
||||
mcp->mc_eax = 0;
|
||||
mcp->mc_edx = 0;
|
||||
mcp->mc_eflags &= ~PSL_C;
|
||||
} else {
|
||||
mcp->mc_eax = tp->tf_rax;
|
||||
mcp->mc_edx = tp->tf_rdx;
|
||||
@ -152,7 +154,6 @@ ia32_get_mcontext(struct thread *td, struct ia32_mcontext *mcp, int flags)
|
||||
mcp->mc_ecx = tp->tf_rcx;
|
||||
mcp->mc_eip = tp->tf_rip;
|
||||
mcp->mc_cs = tp->tf_cs;
|
||||
mcp->mc_eflags = tp->tf_rflags;
|
||||
mcp->mc_esp = tp->tf_rsp;
|
||||
mcp->mc_ss = tp->tf_ss;
|
||||
mcp->mc_len = sizeof(*mcp);
|
||||
|
Loading…
Reference in New Issue
Block a user