Re: sigprocmask.2: s/kernel_sigset_t/sigset_t/

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2/14/21 12:30 AM, Alejandro Colomar (man-pages) wrote:
> On 2/13/21 5:05 PM, Michael Kerrisk (man-pages) wrote:
>> Hi Alex,
>>
>> On 2/12/21 4:28 PM, Alejandro Colomar (man-pages) wrote:
>>> Hi Michael,
>>>
>>> AFAICT, the syscalls [rt_]sigprocmask use '[old_]sigset_t' (there's the
>>> '__user' modifier too), so 'kernel_' should be removed from the types,
>>> shouldn't it?
>>
>> Looks like you're right. Will you send a patch?
>>
>> Thanks,
>>
>> Michael
> 
> Hi Michael,
> 
> I was wrong!

D'oh! I should read the manual page!

Cheers,

Michael

> [[
>    C library/kernel differences
>        The kernel's definition of sigset_t differs  in  size  from
>        that  used by the C library.  In this manual page, the for‐
>        mer is referred to as kernel_sigset_t (it  is  nevertheless
>        named sigset_t in the kernel sources).
> 
>        The  glibc  wrapper function for sigprocmask() silently ig‐
>        nores attempts to block the two real-time signals that  are
>        used  internally by the NPTL threading implementation.  See
>        nptl(7) for details.
> 
>        The original Linux system  call  was  named  sigprocmask().
>        However,  with  the  addition of real-time signals in Linux
>        2.2,  the  fixed-size,  32-bit  sigset_t  (referred  to  as
>        old_kernel_sigset_t  in this manual page) type supported by
>        that system call was no longer  fit  for  purpose.   Conse‐
>        quently,  a new system call, rt_sigprocmask(), was added to
>        support an enlarged sigset_t  type  (referred  to  as  ker‐
>        nel_sigset_t  in  this  manual  page).  The new system call
>        takes a fourth argument, size_t sigsetsize, which specifies
>        the  size  in  bytes  of the signal sets in set and oldset.
>        This argument is currently required to have a fixed  archi‐
>        tecture specific value (equal to sizeof(kernel_sigset_t)).
> 
>        The  glibc  sigprocmask()  wrapper function hides these de‐
>        tails from us, transparently calling rt_sigprocmask()  when
>        the kernel provides it.
> ]]
> 
> 
> 


-- 
Michael Kerrisk
Linux man-pages maintainer; http://www.kernel.org/doc/man-pages/
Linux/UNIX System Programming Training: http://man7.org/training/



[Index of Archives]     [Kernel Documentation]     [Netdev]     [Linux Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux