openbmc/build/tmp/deploy/sdk/witherspoon-2019-08-08/sysroots/armv6-openbmc-linux-gnueabi/usr/src/debug/glibc/2.29-r0/git/sysdeps/unix/sysv/linux/arch-fork.h
static inline pid_t arch_fork(void* ctid)
{
    const int flags = CLONE_CHILD_SETTID | CLONE_CHILD_CLEARTID | SIGCHLD;
    long int ret;
#ifdef __ASSUME_CLONE_BACKWARDS
#ifdef INLINE_CLONE_SYSCALL
    ret = INLINE_CLONE_SYSCALL(flags, 0, NULL, 0, ctid);
#else
    ret = INLINE_SYSCALL_CALL(clone, flags, 0, NULL, 0, ctid);
#endif
#elif defined(__ASSUME_CLONE_BACKWARDS2)
    ret = INLINE_SYSCALL_CALL(clone, 0, flags, NULL, ctid, 0);
#elif defined(__ASSUME_CLONE_BACKWARDS3)
    ret = INLINE_SYSCALL_CALL(clone, flags, 0, 0, NULL, ctid, 0);
#elif defined(__ASSUME_CLONE2)
    ret = INLINE_SYSCALL_CALL(clone2, flags, 0, 0, NULL, ctid, 0);
#elif defined(__ASSUME_CLONE_DEFAULT)
    ret = INLINE_SYSCALL_CALL(clone, flags, 0, NULL, ctid, 0);
#else
#error "Undefined clone variant"
#endif
    return ret;
}
/* Call the clone syscall with fork semantic.  The CTID address is used
   to store the child thread ID at its locationm, to erase it in child memory
   when the child exits, and do a wakeup on the futex at that address.

   The architecture with non-default kernel abi semantic should correctlly
   override it with one of the supported calling convention (check generic
   kernel-features.h for the clone abi variants).  */
Call the clone syscall with fork semantic.  The CTID address is used
to store the child thread ID at its locationm, to erase it in child memory
when the child exits, and do a wakeup on the futex at that address.

The architecture with non-default kernel abi semantic should correctlly
override it with one of the supported calling convention (check generic
kernel-features.h for the clone abi variants).
Call the clone syscall with fork semantic . The CTID address is used to store the child thread ID at its locationm to erase it in child memory when the child exits and do a wakeup on the futex at that address . The architecture with non - default kernel abi semantic should correctlly override it with one of the supported calling convention ( check generic kernel - features . h for the clone abi variants ) .
static inline pid_t arch_fork(void* ctid)
{
    const int flags = CLONE_CHILD_SETTID | CLONE_CHILD_CLEARTID | SIGCHLD;
    long int ret;
#ifdef __ASSUME_CLONE_BACKWARDS
#ifdef INLINE_CLONE_SYSCALL
    ret = INLINE_CLONE_SYSCALL(flags, 0, NULL, 0, ctid);
#else
    ret = INLINE_SYSCALL_CALL(clone, flags, 0, NULL, 0, ctid);
#endif
#elif defined(__ASSUME_CLONE_BACKWARDS2)
    ret = INLINE_SYSCALL_CALL(clone, 0, flags, NULL, ctid, 0);
#elif defined(__ASSUME_CLONE_BACKWARDS3)
    ret = INLINE_SYSCALL_CALL(clone, flags, 0, 0, NULL, ctid, 0);
#elif defined(__ASSUME_CLONE2)
    ret = INLINE_SYSCALL_CALL(clone2, flags, 0, 0, NULL, ctid, 0);
#elif defined(__ASSUME_CLONE_DEFAULT)
    ret = INLINE_SYSCALL_CALL(clone, flags, 0, NULL, ctid, 0);
#else
#error "Undefined clone variant"
#endif
    return ret;
}
static inline pid_t arch_fork ( void * ctid ) { const int flags = CLONE_CHILD_SETTID | CLONE_CHILD_CLEARTID | SIGCHLD ; long int ret ; #ifdef __ASSUME_CLONE_BACKWARDS #ifdef INLINE_CLONE_SYSCALL ret = INLINE_CLONE_SYSCALL ( flags , 0 , NULL , 0 , ctid ) ; #else ret = INLINE_SYSCALL_CALL ( clone , flags , 0 , NULL , 0 , ctid ) ; #endif #elif defined ( __ASSUME_CLONE_BACKWARDS2 ) ret = INLINE_SYSCALL_CALL ( clone , 0 , flags , NULL , ctid , 0 ) ; #elif defined ( __ASSUME_CLONE_BACKWARDS3 ) ret = INLINE_SYSCALL_CALL ( clone , flags , 0 , 0 , NULL , ctid , 0 ) ; #elif defined ( __ASSUME_CLONE2 ) ret = INLINE_SYSCALL_CALL ( clone2 , flags , 0 , 0 , NULL , ctid , 0 ) ; #elif defined ( __ASSUME_CLONE_DEFAULT ) ret = INLINE_SYSCALL_CALL ( clone , flags , 0 , NULL , ctid , 0 ) ; #else #error  "Undefined clone variant" #endif return ret ; }
Call the clone syscall with fork semantic.
Call the clone syscall with fork semantic .