From mboxrd@z Thu Jan 1 00:00:00 1970 From: Al Viro Subject: Re: [RFC] lustre treatment of dentry->d_name Date: Tue, 21 Oct 2014 05:02:10 +0100 Message-ID: <20141021040210.GR7996@ZenIV.linux.org.uk> References: <20141021011346.GP7996@ZenIV.linux.org.uk> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: QUOTED-PRINTABLE Cc: "linux-fsdevel@vger.kernel.org" , "Dilger, Andreas" , "Hammond, John" To: "Drokin, Oleg" Return-path: Received: from zeniv.linux.org.uk ([195.92.253.2]:56198 "EHLO ZenIV.linux.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750730AbaJUECM (ORCPT ); Tue, 21 Oct 2014 00:02:12 -0400 Content-Disposition: inline In-Reply-To: Sender: linux-fsdevel-owner@vger.kernel.org List-ID: On Tue, Oct 21, 2014 at 03:46:02AM +0000, Drokin, Oleg wrote: > > a) what protects ->d_name in ll_intent_file_open()? It copies > > ->d_name.name and ->d_name.len into local variables and proceeds to > > use those; what's to guarantee that dentry won't get hit with d_mov= e() > > halfway through that? None of the locks that would give an exclusi= on > > against d_move() appear to be held=E2=80=A6 >=20 > You are right. We hit something very similar not too long ago. > >=20 > > b) what stabilizes *dentryp->d_name in do_statahead_enter()? > Same as above. > All of that would go away once we get rid of the wrapper and unroll t= he > vfs ops. >=20 > Hopefully this makes at least some sense to you. OK... I'd gone and ripped some of that stuff out today; see if what's = in vfs.git#for-oleg makes sense... Another question: what's wrong with d_splice_alias() or d_materialise_u= nique()? I.e. why do we need ll_splice_alias()? I have patches in local queue (soon to show up in for-next) that merge d_splice_alias() and d_materialise_unique(), essentially teaching the former to deal with on= e case d_materialise_unique() can handle while d_splice_alias() couldn't. If you need something not covered by those, it would be interesting to find out if it would make sense to fold _that_ into d_splice_alias() as= well... -- To unsubscribe from this list: send the line "unsubscribe linux-fsdevel= " in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html