1RT_SIGQUEUEINFO(2)         Linux Programmer's Manual        RT_SIGQUEUEINFO(2)
2
3
4

NAME

6       rt_sigqueueinfo, rt_tgsigqueueinfo - queue a signal and data
7

SYNOPSIS

9       int rt_sigqueueinfo(pid_t tgid, int sig, siginfo_t *info);
10
11       int rt_tgsigqueueinfo(pid_t tgid, pid_t tid, int sig,
12                             siginfo_t *info);
13
14       Note: There are no glibc wrappers for these system calls; see NOTES.
15

DESCRIPTION

17       The rt_sigqueueinfo() and rt_tgsigqueueinfo() system calls are the low-
18       level interfaces used to send a  signal  plus  data  to  a  process  or
19       thread.  The receiver of the signal can obtain the accompanying data by
20       establishing a signal handler with the sigaction(2) SA_SIGINFO flag.
21
22       These system calls are not intended for direct  application  use;  they
23       are   provided   to   allow   the  implementation  of  sigqueue(3)  and
24       pthread_sigqueue(3).
25
26       The rt_sigqueueinfo() system call sends the signal sig  to  the  thread
27       group  with  the  ID tgid.  (The term "thread group" is synonymous with
28       "process", and tid corresponds to the  traditional  UNIX  process  ID.)
29       The signal will be delivered to an arbitrary member of the thread group
30       (i.e., one of the threads that is not currently blocking the signal).
31
32       The info argument specifies the data to  accompany  the  signal.   This
33       argument  is  a  pointer to a structure of type siginfo_t, described in
34       sigaction(2) (and defined  by  including  <sigaction.h>).   The  caller
35       should set the following fields in this structure:
36
37       si_code
38              This  should be one of the SI_* codes in the Linux kernel source
39              file include/asm-generic/siginfo.h.  If the signal is being sent
40              to  any  process  other  than  the  caller itself, the following
41              restrictions apply:
42
43              *  The code can't be a value greater than or equal to zero.   In
44                 particular,  it can't be SI_USER, which is used by the kernel
45                 to indicate a signal sent by  kill(2),  and  nor  can  it  be
46                 SI_KERNEL,  which  is  used to indicate a signal generated by
47                 the kernel.
48
49              *  The code can't (since Linux 2.6.39)  be  SI_TKILL,  which  is
50                 used by the kernel to indicate a signal sent using tgkill(2).
51
52       si_pid This  should be set to a process ID, typically the process ID of
53              the sender.
54
55       si_uid This should be set to a user ID, typically the real user  ID  of
56              the sender.
57
58       si_value
59              This  field contains the user data to accompany the signal.  For
60              more information, see the description of the last (union sigval)
61              argument of sigqueue(3).
62
63       Internally,  the  kernel sets the si_signo field to the value specified
64       in sig, so that the receiver of the signal can also obtain  the  signal
65       number via that field.
66
67       The  rt_tgsigqueueinfo()  system  call  is  like rt_sigqueueinfo(), but
68       sends the signal and data to the single thread specified by the  combi‐
69       nation  of  tgid,  a  thread group ID, and tid, a thread in that thread
70       group.
71

RETURN VALUE

73       On success, these system calls return 0.  On error, they return -1  and
74       errno is set to indicate the error.
75

ERRORS

77       EAGAIN The limit of signals which may be queued has been reached.  (See
78              signal(7) for further information.)
79
80       EINVAL sig, tgid, or tid was invalid.
81
82       EPERM  The caller does not have permission to send the  signal  to  the
83              target.  For the required permissions, see kill(2).
84
85       EPERM  tgid specifies a process other than the caller and info->si_code
86              is invalid.
87
88       ESRCH  rt_sigqueueinfo(): No thread group matching tgid was found.
89
90       rt_tgsigqueinfo(): No thread matching tgid and tid was found.
91

VERSIONS

93       The rt_sigqueueinfo() system call was added to Linux  in  version  2.2.
94       The  rt_tgsigqueueinfo()  system  call  was  added  to Linux in version
95       2.6.31.
96

CONFORMING TO

98       These system calls are Linux-specific.
99

NOTES

101       Since these system calls are not intended for  application  use,  there
102       are  no  glibc  wrapper  functions; use syscall(2) in the unlikely case
103       that you want to call them directly.
104
105       As with kill(2), the null signal (0) can be used to check if the speci‐
106       fied process or thread exists.
107

SEE ALSO

109       kill(2), pidfd_send_signal(2), sigaction(2), sigprocmask(2), tgkill(2),
110       pthread_sigqueue(3), sigqueue(3), signal(7)
111

COLOPHON

113       This page is part of release 5.04 of the Linux  man-pages  project.   A
114       description  of  the project, information about reporting bugs, and the
115       latest    version    of    this    page,    can     be     found     at
116       https://www.kernel.org/doc/man-pages/.
117
118
119
120Linux                             2019-10-10                RT_SIGQUEUEINFO(2)
Impressum