x86:ensure that getcontext will return 0.
The setcontext method did not alway set the return value to 0 after restoring the desired context. Specially When calling setcontext with the _UC_IGNSIGM and the _UC_IGNFPU flags the return value would be non zero. Change-Id: Iec7f8d6a680950aa53e3c88c86e03f65005e66b2
This commit is contained in:
parent
372247712a
commit
69b8ce6ab2
1 changed files with 1 additions and 0 deletions
|
@ -108,6 +108,7 @@ ENTRY(setcontext)
|
||||||
mov SI(%edx), %esi /* Restore ESI */
|
mov SI(%edx), %esi /* Restore ESI */
|
||||||
mov BP(%edx), %ebp /* Restore EBP */
|
mov BP(%edx), %ebp /* Restore EBP */
|
||||||
mov SP(%edx), %esp /* Restore stack pointer */
|
mov SP(%edx), %esp /* Restore stack pointer */
|
||||||
|
xor %eax, %eax /* Return 0 */
|
||||||
jmp *PC(%edx) /* Return to RTA */
|
jmp *PC(%edx) /* Return to RTA */
|
||||||
|
|
||||||
/* void ctx_start((void *func)(int arg1, ..., argn), arg1, ..., argn,
|
/* void ctx_start((void *func)(int arg1, ..., argn), arg1, ..., argn,
|
||||||
|
|
Loading…
Reference in a new issue