提交 5c49574f 编写于 作者: A Al Viro

new helper: restore_altstack()

to be used by rt_sigreturn instances
Signed-off-by: NAl Viro <viro@zeniv.linux.org.uk>
上级 031b6566
......@@ -385,4 +385,6 @@ int unhandled_signal(struct task_struct *tsk, int sig);
void signals_init(void);
int restore_altstack(const stack_t __user *);
#endif /* _LINUX_SIGNAL_H */
......@@ -3103,6 +3103,13 @@ do_sigaltstack (const stack_t __user *uss, stack_t __user *uoss, unsigned long s
return error;
}
int restore_altstack(const stack_t __user *uss)
{
int err = do_sigaltstack(uss, NULL, current_user_stack_pointer());
/* squash all but EFAULT for now */
return err == -EFAULT ? err : 0;
}
#ifdef __ARCH_WANT_SYS_SIGPENDING
/**
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册