Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1423587AbbFEPhq (ORCPT ); Fri, 5 Jun 2015 11:37:46 -0400 Received: from mail-wg0-f44.google.com ([74.125.82.44]:36659 "EHLO mail-wg0-f44.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755077AbbFEPho (ORCPT ); Fri, 5 Jun 2015 11:37:44 -0400 Date: Fri, 5 Jun 2015 17:37:29 +0200 From: Miklos Szeredi To: Al Viro Cc: 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 Message-ID: <20150605150939.GA2174@tucsk> References: <1433424586-7771-1-git-send-email-miklos@szeredi.hu> <1433424586-7771-3-git-send-email-miklos@szeredi.hu> <20150605000715.GP7232@ZenIV.linux.org.uk> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20150605000715.GP7232@ZenIV.linux.org.uk> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1597 Lines: 45 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... Thanks, Miklos -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/