clone_x86_32: use correct 4th syscall arg
PATCH 1/1 clone_x86_32: use correct 4th syscall arg
The 4th arg to syscall is esi, not edi. Wasn't too big a deal since we yanked it out of regs->edi at process_32.c:sys_eclone(), but it gets totally b0rked when ia32 regs fixup happens to use the 32-bit abi in x86-64.
Signed-off-by Serge Hallyn <serge-r/[email protected]>
--- clone_x86_32.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
clone_x86_32.c +1 -1
@@ -66,7 +66,7 @@ int eclone(int (*fn)(void *), void *fn_arg, int clone_flags_low,"b" (clone_flags_low),/* flags -> 1st (ebx) */ "c" (&my_args),/* clone_args -> 2nd (ecx) */ "d" (sizeof (my_args)),/* args_size -> 3rd (edx) */ -"D" (pids)/* pids -> 4th (edi) */ +"S" (pids)/* pids -> 4th (esi) */ );if (retval <0 ) {
Signature · 1 line
1.6.3.3