From mboxrd@z Thu Jan 1 00:00:00 1970 From: Christoph Hellwig Subject: Re: [PATCH 13/18] fs: split locking of inode writeback and LRU lists Date: Fri, 8 Oct 2010 04:18:16 -0400 Message-ID: <20101008081816.GA17577@infradead.org> References: <1286515292-15882-1-git-send-email-david@fromorbit.com> <1286515292-15882-14-git-send-email-david@fromorbit.com> <20101008074243.GB24089@infradead.org> <20101008080018.GV4681@dastard> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Christoph Hellwig , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org To: Dave Chinner Return-path: Received: from canuck.infradead.org ([134.117.69.58]:32879 "EHLO canuck.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755612Ab0JHISR (ORCPT ); Fri, 8 Oct 2010 04:18:17 -0400 Content-Disposition: inline In-Reply-To: <20101008080018.GV4681@dastard> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: On Fri, Oct 08, 2010 at 07:00:18PM +1100, Dave Chinner wrote: > > > > > > - if (inode->i_state & (I_NEW | I_WILL_FREE)) { > > > + if (inode->i_state & (I_NEW | I_WILL_FREE | I_FREEING)) { > > > requeue_io(inode); > > > continue; > > > } > > > > What does this have to do with the rest of the patch? > > That's because there's now a window between setting I_FREEING and taking > the inode off the writeback list which means that we can see inodes > in that state here. Generally it means that the code setting > I_FREEING is spinning waiting for the wb->b_lock that this thread > currently holds so it can be removed from the list.. Hence the requeue > to move the inode out of the way and keep processing inodes for > writeback. That needs some documentation both in the changelog and in the code I think.