From: ebiederm@xmission.com (Eric W. Biederman)
To: Miklos Szeredi <miklos@szeredi.hu>
Cc: Al Viro <viro@ZenIV.linux.org.uk>,
linux-unionfs@vger.kernel.org, linux-fsdevel@vger.kernel.org,
linux-kernel@vger.kernel.org, sa-dev@rainbow.by,
andre.roth@roche.com
Subject: Re: [PATCH 2/2] ovl: allow distributed fs as lower layer
Date: Sat, 06 Jun 2015 20:02:56 -0500 [thread overview]
Message-ID: <877frgwcsf.fsf@x220.int.ebiederm.org> (raw)
In-Reply-To: <20150605150939.GA2174@tucsk> (Miklos Szeredi's message of "Fri, 5 Jun 2015 17:37:29 +0200")
Miklos Szeredi <miklos@szeredi.hu> writes:
> On Fri, Jun 05, 2015 at 01:07:15AM +0100, Al Viro wrote:
>
>> Umm... Cosmetical point is that this
>>
>> > +static bool ovl_remote(struct dentry *root)
>> > +{
>> > + const struct dentry_operations *dop = root->d_op;
>> > +
>> > + return dop && (dop->d_revalidate || dop->d_weak_revalidate);
>> > +}
>>
>> is better done as
>> root->d_flags & (DCACHE_OP_REVALIDATE | DCACHE_OP_WEAK_REVALIDATE)
>
> Okay.
>
>>
>> More interesting question is whether anything in the system relies on
>> existing behaviour that follows ->d_revalidate() returning 0.
>
> Hmm, d_invalidate() almost always follows ->d_revalidate(). Almost, becuase RCU
> lookup can get aborted at that point. We can easily stick d_invalidate() in
> there for the non-RCU case.
>
> Regular lookup also almost always follows ->d_revalidate(). Except if
> allocation of new dentry fails. So relying on this would be buggy (which is not
> to say nobody does it).
>
>> Have you tried to mount e.g. procfs as underlying layer and torture it for a
>> while?
>
> I did try now. Nothing bad happened during the test (parallel stat(1) of the
> whole overlayed proc tree).
>
> My laptop froze while trying to write this mail. But it's 8 years old and when
> the fan starts to make noises and the weather is hot, it does this sometimes. I
> don't think that has anything to do with overlayfs, but will do more
> testing...
A nasty corner case to be aware of (and I think this is part of what Al
was warning about). /proc/sys/net is different depending upon which
current->nsproxy->net_ns.
Eric
next prev parent reply other threads:[~2015-06-07 1:08 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-06-04 13:29 [PATCH 0/2] ovl: support NFS as lower layer Miklos Szeredi
2015-06-04 13:29 ` [PATCH 1/2] ovl: don't traverse automount points Miklos Szeredi
2015-06-04 13:29 ` [PATCH 2/2] ovl: allow distributed fs as lower layer Miklos Szeredi
2015-06-05 0:07 ` Al Viro
2015-06-05 15:37 ` Miklos Szeredi
2015-06-07 1:02 ` Eric W. Biederman [this message]
2015-06-09 12:44 ` Miklos Szeredi
2015-06-09 12:54 ` Eric W. Biederman
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=877frgwcsf.fsf@x220.int.ebiederm.org \
--to=ebiederm@xmission.com \
--cc=andre.roth@roche.com \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-unionfs@vger.kernel.org \
--cc=miklos@szeredi.hu \
--cc=sa-dev@rainbow.by \
--cc=viro@ZenIV.linux.org.uk \
/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