[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <AANLkTi=3vXEW3r4Z9v=QF_Dj2WL6m8S7ATDQvSy7mPbg@mail.gmail.com>
Date: Mon, 28 Mar 2011 13:27:31 -0700
From: Roland Dreier <roland@...nel.org>
To: Oleg Nesterov <oleg@...hat.com>
Cc: Linus Torvalds <torvalds@...ux-foundation.org>,
linux-kernel@...r.kernel.org, Julien Tinnes <jln@...gle.com>,
Klaus Dittrich <kladit@...or.de>
Subject: Re: [PATCH] Allow rt_sigqueueinfo and rt_tgsigqueueinfo to use
si_code == SI_ASYNCIO
On Mon, Mar 28, 2011 at 10:42 AM, Oleg Nesterov <oleg@...hat.com> wrote:
> I am starting to think that "plan B" was better.
>
> if (info.si_code >= 0 || info.si_code == SI_TKILL)
> return -EPERM;
Indeed. Grepping further in glibc finds sysdeps/unix/sysv/linux/aio_sigqueue.c:
/* We must pass the information about the data in a siginfo_t
value. */
info.si_signo = timer->event.sigev_signo;
info.si_code = SI_TIMER;
info.si_pid = timer->creator_pid;
info.si_uid = getuid ();
info.si_value = timer->event.sigev_value;
INLINE_SYSCALL (rt_sigqueueinfo, 3, info.si_pid, info.si_signo, &info);
and sysdeps/unix/sysv/linux/gai_sigqueue.c:
/* We must pass the information about the data in a siginfo_t value. */
info.si_signo = sig;
info.si_code = SI_ASYNCNL;
info.si_pid = caller_pid;
info.si_uid = __getuid ();
info.si_value = val;
return INLINE_SYSCALL (rt_sigqueueinfo, 3, info.si_pid,
sig, __ptrvalue (&info));
where SI_ASYNCNL is -60, which the kernel doesn't know about.
Updated patch coming in a minute.
Thanks,
Roland
--
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