/* Accessing ->real_parent is not SMP-safe, it could change from under us. However, we can use a stale value of ->real_parent under rcu_read_lock(), see release_task()->call_rcu(delayed_put_task_struct).  */
SYSCALL_DEFINE0(getppid)
/* Accessing ->real_parent is not SMP-safe, it could change from under us. However, we can use a stale value of ->real_parent under rcu_read_lock(), see release_task()->call_rcu(delayed_put_task_struct).  */
SYSCALL_DEFINE0(getppid)
{
	int pid;
	rcu_read_lock();
	pid = task_tgid_vnr(current->real_parent);
	rcu_read_unlock();
	return pid;
}