sim-se: Use CONFIG_CLONE_BACKWARDS for Arm

Linxu on Arm users the CLONE_BACKWARDS argument order for the clone
syscall.

Change-Id: I48deb4f03140c9d4ef7a89e3e33813e76777f999
Signed-off-by: Andreas Sandberg <andreas.sandberg@arm.com>
Cc: Giacomo Travaglini <giacomo.travaglini@arm.com>
Cc: Javier Setoain <javier.setoain@arm.com>
Cc: Brandon Potter <Brandon.Potter@amd.com>
Reviewed-on: https://gem5-review.googlesource.com/c/15416
Reviewed-by: Brandon Potter <Brandon.Potter@amd.com>
Reviewed-by: Jason Lowe-Power <jason@lowepower.com>
Maintainer: Brandon Potter <Brandon.Potter@amd.com>
This commit is contained in:
Andreas Sandberg
2019-01-09 14:31:52 +00:00
parent 5e420343d3
commit 384951540c

View File

@@ -1273,9 +1273,9 @@ cloneFunc(SyscallDesc *desc, int callnum, Process *p, ThreadContext *tc)
TheISA::IntReg newStack = p->getSyscallArg(tc, index);
Addr ptidPtr = p->getSyscallArg(tc, index);
#if THE_ISA == RISCV_ISA
#if THE_ISA == RISCV_ISA or THE_ISA == ARM_ISA
/**
* Linux kernel 4.15 sets CLONE_BACKWARDS flag for RISC-V.
* Linux sets CLONE_BACKWARDS flag for RISC-V and Arm.
* The flag defines the list of clone() arguments in the following
* order: flags -> newStack -> ptidPtr -> tlsPtr -> ctidPtr
*/