|
@@ -2369,6 +2369,32 @@ SYSCALL_DEFINE3(rt_sigqueueinfo, pid_t, pid, int, sig,
|
|
return kill_proc_info(sig, &info, pid);
|
|
return kill_proc_info(sig, &info, pid);
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+long do_rt_tgsigqueueinfo(pid_t tgid, pid_t pid, int sig, siginfo_t *info)
|
|
|
|
+{
|
|
|
|
+ /* This is only valid for single tasks */
|
|
|
|
+ if (pid <= 0 || tgid <= 0)
|
|
|
|
+ return -EINVAL;
|
|
|
|
+
|
|
|
|
+ /* Not even root can pretend to send signals from the kernel.
|
|
|
|
+ Nor can they impersonate a kill(), which adds source info. */
|
|
|
|
+ if (info->si_code >= 0)
|
|
|
|
+ return -EPERM;
|
|
|
|
+ info->si_signo = sig;
|
|
|
|
+
|
|
|
|
+ return do_send_specific(tgid, pid, sig, info);
|
|
|
|
+}
|
|
|
|
+
|
|
|
|
+SYSCALL_DEFINE4(rt_tgsigqueueinfo, pid_t, tgid, pid_t, pid, int, sig,
|
|
|
|
+ siginfo_t __user *, uinfo)
|
|
|
|
+{
|
|
|
|
+ siginfo_t info;
|
|
|
|
+
|
|
|
|
+ if (copy_from_user(&info, uinfo, sizeof(siginfo_t)))
|
|
|
|
+ return -EFAULT;
|
|
|
|
+
|
|
|
|
+ return do_rt_tgsigqueueinfo(tgid, pid, sig, &info);
|
|
|
|
+}
|
|
|
|
+
|
|
int do_sigaction(int sig, struct k_sigaction *act, struct k_sigaction *oact)
|
|
int do_sigaction(int sig, struct k_sigaction *act, struct k_sigaction *oact)
|
|
{
|
|
{
|
|
struct task_struct *t = current;
|
|
struct task_struct *t = current;
|