signal: Introduce copy_siginfo_from_user and use it's return value
In preparation for using a smaller version of siginfo in the kernel introduce copy_siginfo_from_user and use it when siginfo is copied from userspace. Make the pattern for using copy_siginfo_from_user and copy_siginfo_from_user32 to capture the return value and return that value on error. This is a necessary prerequisite for using a smaller siginfo in the kernel than the kernel exports to userspace. Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
This commit is contained in:
@@ -22,6 +22,7 @@ static inline void clear_siginfo(struct siginfo *info)
|
||||
}
|
||||
|
||||
int copy_siginfo_to_user(struct siginfo __user *to, const struct siginfo *from);
|
||||
int copy_siginfo_from_user(struct siginfo *to, const struct siginfo __user *from);
|
||||
|
||||
enum siginfo_layout {
|
||||
SIL_KILL,
|
||||
|
Reference in New Issue
Block a user