The siginfo structure contains user pointers with tags and the complete details need to be delivered to the user of rt_sigtimedwait() syscall.
Make use of copy_siginfo_to_user_with_ptr() interface while copying siginfo_t to user memory.
Signed-off-by: Amit Daniel Kachhap amit.kachhap@arm.com --- kernel/signal.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/kernel/signal.c b/kernel/signal.c index 3efb33031d36..7139f9cf0151 100644 --- a/kernel/signal.c +++ b/kernel/signal.c @@ -3684,7 +3684,7 @@ SYSCALL_DEFINE4(rt_sigtimedwait, const sigset_t __user *, uthese, ret = do_sigtimedwait(&these, &info, uts ? &ts : NULL);
if (ret > 0 && uinfo) { - if (copy_siginfo_to_user(uinfo, &info)) + if (copy_siginfo_to_user_with_ptr(uinfo, &info)) ret = -EFAULT; }