All of lore.kernel.org
 help / color / mirror / Atom feed
From: Al Viro <viro@ZenIV.linux.org.uk>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: linux-fsdevel <linux-fsdevel@vger.kernel.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 17/17] RCU'd vfsmounts
Date: Thu, 3 Oct 2013 22:14:48 +0100	[thread overview]
Message-ID: <20131003211448.GN13318@ZenIV.linux.org.uk> (raw)
In-Reply-To: <CA+55aFybjMDwdfV2uoGL=8U4c1tytjMwk4sU187e6ha2xQ=3+Q@mail.gmail.com>

On Thu, Oct 03, 2013 at 01:52:45PM -0700, Linus Torvalds wrote:

> Yeah, I think we should be guaranteed that, because the
> synchronize_rcu() will guarantee that all other CPU's go through an
> idle period. So the "read A" on CPU2 cannot possibly see a 1 _unless_
> it happens so early that synchronize_rcu() definitely sees it (ie it's
> a "preexisting reader" by definition), in which case synchronize_rcu()
> will be waiting for a subsequent idle period, in which case the B=0 on
> CPU2 is not only guaranteed to happen but also be visible out, so the
> "read B" on CPU1 will see 0. And that's true even if CPU2 doesn't have
> an explicit memory barrier, because the "RCU idle" state implies that
> it has gone through a barrier.
> 
> So I don't see how they could possibly see ones. Modulo terminal bugs
> in synchronize_barrier() (which can be very slow, but for umount I
> wouldn't worry). Or modulo my brain being fried.

There's one more place similar to that - kern_unmount().  There we also
go from "longterm vfsmount, mntput() doesn't need to bother checking"
to NULL ->mnt_ns.  We can, of course, slap synchronize_rcu() there as
well, but that might make pid_ns and ipc_ns destruction slow...

  reply	other threads:[~2013-10-03 21:14 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-10-03  6:20 [PATCH 17/17] RCU'd vfsmounts Al Viro
     [not found] ` <CA+55aFzeDP6J4ekdn4-85yoXzX3xmEp_qc3npvqepJM+MFn=6Q@mail.gmail.com>
     [not found]   ` <20131003105130.GE13318@ZenIV.linux.org.uk>
     [not found]     ` <CA+55aFzh+n_2fs=aWcT_5gnLC_pWSHqQPJeQ+fg=+Xw7ib9=dQ@mail.gmail.com>
     [not found]       ` <20131003174439.GG13318@ZenIV.linux.org.uk>
2013-10-03 19:06         ` Linus Torvalds
2013-10-03 19:43           ` Al Viro
2013-10-03 20:19             ` Linus Torvalds
2013-10-03 20:41               ` Al Viro
2013-10-03 20:52                 ` Linus Torvalds
2013-10-03 21:14                   ` Al Viro [this message]
2013-10-04  2:53                     ` Al Viro
2013-10-04  8:37                       ` Christoph Hellwig
2013-10-04 12:58                         ` Al Viro
2013-10-04 14:00                           ` Christoph Hellwig
2013-10-03 23:28                   ` Josh Triplett
2013-10-03 23:51                     ` Linus Torvalds
2013-10-04  0:41                       ` Josh Triplett
2013-10-04  0:45                         ` Linus Torvalds
2013-10-04  6:41                           ` Ingo Molnar
2013-10-04  5:29                     ` Paul E. McKenney
2013-10-04  6:03                       ` Josh Triplett
2013-10-04  6:15                         ` Paul E. McKenney
2013-10-04  7:04                           ` Josh Triplett

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=20131003211448.GN13318@ZenIV.linux.org.uk \
    --to=viro@zeniv.linux.org.uk \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@linux-foundation.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.