[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Pine.LNX.4.64.0705211313090.24209@alien.or.mcafeemobile.com>
Date: Mon, 21 May 2007 13:16:40 -0700 (PDT)
From: Davide Libenzi <davidel@...ilserver.org>
To: Oleg Nesterov <oleg@...sign.ru>
cc: "Davi E. M. Arnaut" <davi@...ent.com.br>,
Andrew Morton <akpm@...ux-foundation.org>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: + signalfd-retrieve-multiple-signals-with-one-read-call.patch
added to -mm tree
On Mon, 21 May 2007, Oleg Nesterov wrote:
> > + schedule();
> > + locked = signalfd_lock(ctx, &lk);
> > + if (unlikely(!locked)) {
> > + /*
> > + * Let the caller read zero byte, ala socket
> > + * recv() when the peer disconnect. This test
> > + * must be done before doing a dequeue_signal(),
> > + * because if the sighand has been orphaned,
> > + * the dequeue_signal() call is going to crash.
> > + */
>
> Imho, the comment is a bit confusing. dequeue_signal() needs ->siglock
> even if signalfd_ctx is not orphaned.
The comment looks clear to me. It states:
1) The policy of returning 0 when the sighand has been detached
2) That we _must_not_ call dequeue_signal() in case signalfd_lock() fails
#ACK on the code mod below.
- Davide
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists