From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752605AbdFVPnk (ORCPT ); Thu, 22 Jun 2017 11:43:40 -0400 Received: from imap.thunk.org ([74.207.234.97]:60568 "EHLO imap.thunk.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751185AbdFVPnj (ORCPT ); Thu, 22 Jun 2017 11:43:39 -0400 Date: Thu, 22 Jun 2017 11:43:36 -0400 From: "Theodore Ts'o" To: Tahsin Erdogan Cc: Andreas Dilger , "Darrick J . Wong" , Jan Kara , linux-ext4@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 26/32] ext4: cleanup transaction restarts during inode deletion Message-ID: <20170622154336.5ry5lzhw3yv27u4q@thunk.org> Mail-Followup-To: Theodore Ts'o , Tahsin Erdogan , Andreas Dilger , "Darrick J . Wong" , Jan Kara , linux-ext4@vger.kernel.org, linux-kernel@vger.kernel.org References: <20170622014939.3592-1-tahsin@google.com> <20170622014939.3592-3-tahsin@google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170622014939.3592-3-tahsin@google.com> User-Agent: NeoMutt/20170113 (1.7.2) X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: tytso@thunk.org X-SA-Exim-Scanned: No (on imap.thunk.org); SAEximRunCond expanded to false Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jun 21, 2017 at 06:49:33PM -0700, Tahsin Erdogan wrote: > During inode deletion, journal credits that will be needed are hard to > determine, that is why we have journal extend/restart calls in several > places. Whenever a transaction is restarted, filesystem must be in a > consistent state because there is no atomicity guarantee beyond a > restart call. > > Add ext4_xattr_ensure_credits() helper function which takes care of > journal extend/restart logic. It also handles getting jbd2 write access > and dirty metadata calls. This function is called at every iteration of > handling an ea_inode reference. > > Signed-off-by: Tahsin Erdogan Applied, thanks. - Ted