From: Thomas Gleixner <tglx@linutronix.de>
To: Oleg Nesterov <oleg@redhat.com>
Cc: Alexander Shishkin <virtuoso@slind.org>,
Alexander Viro <viro@zeniv.linux.org.uk>,
Greg Kroah-Hartman <gregkh@suse.de>,
Feng Tang <feng.tang@intel.com>, Michael Tokarev <mjt@tls.msk.ru>,
Marcelo Tosatti <mtosatti@redhat.com>,
John Stultz <johnstul@us.ibm.com>,
Chris Friesen <chris.friesen@genband.com>,
Kay Sievers <kay.sievers@vrfy.org>,
"Kirill A. Shutemov" <kirill@shutemov.name>,
Artem Bityutskiy <dedekind1@gmail.com>,
Davide Libenzi <davidel@xmailserver.org>,
Michael Kerrisk <mtk.manpages@gmail.com>,
linux-api@vger.kernel.org,
Andrew Morton <akpm@linux-foundation.org>,
linux-kernel@vger.kernel.org
Subject: Re: timerfd-add-tfd_notify_clock_set-to-watch-for-clock-changes.patch added to -mm tree
Date: Fri, 11 Mar 2011 17:23:36 +0100 (CET) [thread overview]
Message-ID: <alpine.LFD.2.00.1103111722521.2787@localhost6.localdomain6> (raw)
In-Reply-To: <20110311135023.GA23552@redhat.com>
On Fri, 11 Mar 2011, Oleg Nesterov wrote:
> > @@ -218,10 +266,12 @@ SYSCALL_DEFINE4(timerfd_settime, int, uf
> > * it to the new values.
> > */
> > for (;;) {
> > + spin_lock(¬ifiers_lock);
> > spin_lock_irq(&ctx->wqh.lock);
> > - if (hrtimer_try_to_cancel(&ctx->tmr) >= 0)
> > + if (!list_empty(¬ifiers_list) || hrtimer_try_to_cancel(&ctx->tmr) >= 0)
> > break;
>
> Confused. Why do we check the global notifiers_list?
>
> IOW. Suppose that this list is not empty and timerfd_settime() is called
> without TFD_NOTIFY_CLOCK_SET. Now we are going to reprogramm the timer
> without stopping it?
>
> And. What if timerfd_settime(TFD_NOTIFY_CLOCK_SET, utmr => NULL) is called
> twice? timerfd_setup() blindly does list_add(), and we corrupt the list, no?
And why is this hack in -mm at all ?
Thanks,
tglx
prev parent reply other threads:[~2011-03-11 16:24 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-03-11 13:50 Oleg Nesterov
2011-03-11 15:08 ` Alexander Shishkin
2011-03-11 16:23 ` Thomas Gleixner [this message]
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=alpine.LFD.2.00.1103111722521.2787@localhost6.localdomain6 \
--to=tglx@linutronix.de \
--cc=akpm@linux-foundation.org \
--cc=chris.friesen@genband.com \
--cc=davidel@xmailserver.org \
--cc=dedekind1@gmail.com \
--cc=feng.tang@intel.com \
--cc=gregkh@suse.de \
--cc=johnstul@us.ibm.com \
--cc=kay.sievers@vrfy.org \
--cc=kirill@shutemov.name \
--cc=linux-api@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mjt@tls.msk.ru \
--cc=mtk.manpages@gmail.com \
--cc=mtosatti@redhat.com \
--cc=oleg@redhat.com \
--cc=viro@zeniv.linux.org.uk \
--cc=virtuoso@slind.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®