From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from zeniv.linux.org.uk ([195.92.253.2]:54384 "EHLO ZenIV.linux.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2389854AbeHASDR (ORCPT ); Wed, 1 Aug 2018 14:03:17 -0400 Date: Wed, 1 Aug 2018 17:16:48 +0100 From: Al Viro To: Kirill Tkhai Cc: "linux-fsdevel@vger.kernel.org" , LKML Subject: Re: Commit "new primitive: discard_new_inode()" introduces a problem Message-ID: <20180801161648.GP30522@ZenIV.linux.org.uk> References: <64a0f022-a32d-d4ee-7464-5c5ce0ebd222@virtuozzo.com> <20180801151937.GN30522@ZenIV.linux.org.uk> <96e3c195-aaca-9214-0dcd-5c2b970a72ae@virtuozzo.com> <20180801161151.GO30522@ZenIV.linux.org.uk> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180801161151.GO30522@ZenIV.linux.org.uk> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: On Wed, Aug 01, 2018 at 05:11:51PM +0100, Al Viro wrote: > On Wed, Aug 01, 2018 at 06:43:56PM +0300, Kirill Tkhai wrote: > > #git status > > HEAD detached at 22dc9a168272 > > Wait a sec - just that commit? With discard_new_inode() not even > used anywhere? Then any of those -ENOMEM is disguised ERR_PTR(-ESTALE) > from find_inode()/find_inode_fast(), i.e. an inode found by > iget5_locked() (your /etc is on ext4) with I_CREATING still set. iget_locked(), that is. > And that is set only by insert_inode_locked()/insert_inode_locked4(), > and only until unlock_new_inode(). > > Could you slap WARN_ON(1) before these return ERR_PTR(-ESTALE) in > find_inode{,_fast}() and see if that's what's getting triggered?