All of lore.kernel.org
 help / color / mirror / Atom feed
From: Peng Haitao <penght-BthXqXjhjHXQFUHtdCDX3A@public.gmane.org>
To: mtk.manpages-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org,
	Carlos O'Donell <carlos-v2tUB8YBRSi3e3T8WW9gsA@public.gmane.org>,
	Qian Lei <qianl.fnst-BthXqXjhjHXQFUHtdCDX3A@public.gmane.org>
Cc: Alexandre Oliva <aoliva-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>,
	linux-man <linux-man-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>
Subject: Re: [PATCH] iswblank.3: ATTRIBUTES: Note function that is thread safe with exceptions
Date: Wed, 11 Jun 2014 17:33:23 +0800	[thread overview]
Message-ID: <53982263.20405@cn.fujitsu.com> (raw)
In-Reply-To: <CAKgNAkh029iy5=7+N1RiA1_X9Zeiv_coci59bFN1y-oQmOJykA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>


On 06/11/2014 04:30 PM, Michael Kerrisk (man-pages) wrote:
...
> Practically speaking, I think this means:
> 
> 1. We'd create an attributes(7) man page that has much of the same
> information as in the glibc manual nodes listed above. If needed we
> can rewrite to avoid any licensing issues. On the other hand, if
> Alex(?) wants to make that text available under a suitable license
> (e.g., one of those at
> https://www.kernel.org/doc/man-pages/licenses.html). (Note, GFDL
> doesn't work for man-pages, as explained on that web page.)
> 
> 2. We redesign the ATTRIBUTES section that we use in man-pages. I
> think it would make sense to use something like the Solaris
> attributes(5) approach, where there is a table of safety information.
> That table would be supplemented by notes, as needed. Thus, we might
> have something like:
> 
>     ATTRIBUTES
> 
>         See attributes(7).
> 
>         +-----------+---------------+-----------+
>         | Interface | Attribute     | Value     |
>         +-----------+---------------+-----------+
>         | l64a()    | Thread-safety | MT-Unsafe |
>         +-----------+---------------+-----------+
> 
>         +-------------------+---------------+---------+
>        | Interface         | Attribute     | Value   |
>        +-------------------+---------------+---------+
>         | bindresvport()    | Thread-safety | MT-Safe |
>         +-------------------+---------------+---------+
> 
>         Before glibc 2.17, the bindresvport() function uses a static variable
>         that is not protected, so it is not thread-safe.
>         Since glibc 2.17, it protects the static variable with a lock,
>         and is thus MT-Safe.
> 
>         +----------------------------+---------------+----------------+
>         | Interface                  | Attribute     | Value          |
>         +----------------------------+---------------+----------------+
>         | atoi(), atol(), atoll()    | Thread-safety | MT-Safe locale |
>         +----------------------------+---------------+----------------+
> 
>         +--------------------------+---------------------+---------+
>         | Interface                | Attribute           | Value   |
>         +--------------------------+---------------------+---------+
>         | pthread_setcancelstate() | Async-cancel-safety | AC-Safe |
>         +--------------------------+---------------------+---------+
> 
> An alternative approach would be to have subsections under ATTRIBUES,
> with separate tables for Thread-safety, Async-signal-safety, and
> Async-cancel-safety. Something like this:
> 
>     ATTRIBUTES
> 
>             See attributes(7).
> 
>         Thread-safety
>             +-------------------+---------+
>             | Interface         | Value   |
>             +-------------------+---------+
>             | bindresvport()    | MT-Safe |
>             +-------------------+---------+
> 
>             Before glibc 2.17, the bindresvport() function uses a static
>             variable that is not protected, so it is not thread-safe.
>             Since glibc 2.17, it protects the static variable with a lock,
>             and is thus MT-Safe.
> 
>         Async-cancel-safety
> 
>             +--------------------------+---------+
>             | Interface                | Value   |
>             +--------------------------+---------+
>             | pthread_setcancelstate() | AC-Safe |
>             +--------------------------+---------+
> 
> Does one of those approaches eem okay? Haitao, Qian Lei, what do you
> think? (I appreciate that there's a lot of pages to be fixed to follow
> this new approach: I'd do that, though you could help if you want.)
> 

I select the first approach.
If the approach is decided,Qian and I will help to fix to follow the new approach.
Thanks.


-- 
Best Regards,
Peng

> Cheers,
> 
> Michael
> 
--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  parent reply	other threads:[~2014-06-11  9:33 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-02-10  6:20 [PATCH] iswblank.3: ATTRIBUTES: Note function that is thread safe with exceptions Peng Haitao
     [not found] ` <1392013239-31138-1-git-send-email-penght-BthXqXjhjHXQFUHtdCDX3A@public.gmane.org>
2014-02-10 10:06   ` Michael Kerrisk (man-pages)
2014-02-10 16:03   ` Carlos O'Donell
     [not found]     ` <CAE2sS1g5w0jZ04EovvQoW=Cta4ACdHWVus-5zo+vw1J7E1SnZg-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-02-12  1:34       ` Peng Haitao
     [not found]         ` <52FACFBB.6070607-BthXqXjhjHXQFUHtdCDX3A@public.gmane.org>
2014-02-12 15:31           ` Carlos O'Donell
     [not found]             ` <CAE2sS1ijg2ef1WcswN0o+wmJOcgLDoCEbYrcNJyOxhS-HCxuSg-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-02-13  4:07               ` Peng Haitao
     [not found]                 ` <52FC44E7.1030000-BthXqXjhjHXQFUHtdCDX3A@public.gmane.org>
2014-02-13  4:48                   ` Carlos O'Donell
     [not found]                     ` <CAE2sS1g6ONVgapgZXh2XZJNCr+=JDEezpmPCnxLY2MfEpNfA2w-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-02-22  9:18                       ` Michael Kerrisk (man-pages)
2014-02-23 10:16               ` Michael Kerrisk (man-pages)
     [not found]                 ` <CAKgNAkix8vTrKEV_vicpD2yH88NQmiSrMR9dgKoQ1u2NkqZexA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-02-25 17:28                   ` Carlos O'Donell
     [not found]                     ` <CAE2sS1gZJCZdEhY7hpF8=dP069JFTyxD-B-nY9va0OTFV8jN4w-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-04-16 10:24                       ` Peng Haitao
2014-06-11  8:30                       ` Michael Kerrisk (man-pages)
     [not found]                         ` <CAKgNAkh029iy5=7+N1RiA1_X9Zeiv_coci59bFN1y-oQmOJykA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-06-11  9:33                           ` Peng Haitao [this message]
2014-06-11 14:59                           ` Carlos O'Donell
     [not found]                             ` <CAE2sS1j4sLeczF_gR94+mZ89bi-C=RMMikE=_cOvu9id7v5sHw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-06-11 20:31                               ` Michael Kerrisk (man-pages)
     [not found]                                 ` <CAKgNAkj0b=-5EMqEWvxoq4_qfTH2wNOatkBmqVrXq5dOuQNHmw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-06-12 11:27                                   ` Michael Kerrisk (man-pages)
     [not found]                                     ` <CAKgNAki5UXmOTa=SW1GEYZTP1f5uMiTsrbkcYN+MuYZf6mA0qw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-06-12 12:16                                       ` Michael Kerrisk (man-pages)
     [not found]                                         ` <CAKgNAkgDFuwXDD=Rjn3KAutyuOAy_-71imhR5UGZOS9fcMSnew-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-06-12 14:02                                           ` Carlos O'Donell
2014-06-16  3:53                                           ` Michael Kerrisk (man-pages)
     [not found]                                             ` <539E6A32.7080605-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2014-06-16  7:49                                               ` Peng Haitao
     [not found]                                                 ` <539EA198.9090309-BthXqXjhjHXQFUHtdCDX3A@public.gmane.org>
2014-06-17  5:40                                                   ` Michael Kerrisk (man-pages)
     [not found]                                                 ` <539FD4D3.40 10406@gmail.com>
     [not found]                                                   ` <539FD4D3.4010406-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2014-06-17  5:47                                                     ` Michael Kerrisk (man-pages)
     [not found]                                                       ` <539FD660.7080503-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2014-06-17  8:24                                                         ` Peng Haitao
2014-02-25  5:35               ` Peng Haitao
     [not found]                 ` <530C2BA9.8070604-BthXqXjhjHXQFUHtdCDX3A@public.gmane.org>
2014-02-25 11:17                   ` walter harms

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=53982263.20405@cn.fujitsu.com \
    --to=penght-bthxqxjhjhxqfuhtdcdx3a@public.gmane.org \
    --cc=aoliva-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org \
    --cc=carlos-v2tUB8YBRSi3e3T8WW9gsA@public.gmane.org \
    --cc=linux-man-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=mtk.manpages-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
    --cc=qianl.fnst-BthXqXjhjHXQFUHtdCDX3A@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.