From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757167AbcIGMlc (ORCPT ); Wed, 7 Sep 2016 08:41:32 -0400 Received: from mail-pf0-f178.google.com ([209.85.192.178]:36179 "EHLO mail-pf0-f178.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757108AbcIGMl1 (ORCPT ); Wed, 7 Sep 2016 08:41:27 -0400 From: Geliang Tang To: "Theodore Ts'o" , Jan Kara , Eric Ren Cc: Geliang Tang , linux-ext4@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] Re: [PATCH] jbd2: add jbd2_journal_init() helper Date: Wed, 7 Sep 2016 20:41:12 +0800 Message-Id: X-Mailer: git-send-email 2.7.4 In-Reply-To: <20160906151554.GK28922@quack2.suse.cz> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Sep 06, 2016 at 05:15:54PM +0200, Jan Kara wrote: > On Sat 03-09-16 17:33:39, Eric Ren wrote: > > Hi Geliang, > > > > On 08/31/2016 08:23 PM, Geliang Tang wrote: > > >There are some repetitive code in jbd2_journal_init_dev() and > > >jbd2_journal_init_inode(). So this patch extracts the common code into > > >jbd2_journal_init() helper to simplify the code. And fix the coding > > >style warnings reported by checkpatch.pl by the way. > > journal_init_common() is already there for the same purpose, right? > > Do we really need another helper? > > Agreed, just move the common code into journal_init_common(). Also the > __getblk() in jbd2_journal_init_dev() should be getblk_unmovable() so that > would be a good preparatory fix to remove the need of the gfp argument. > Thanks for your review. I updated the patch as you suggested. -Geliang Geliang Tang (1): jbd2: move more common code into journal_init_common() fs/jbd2/journal.c | 136 +++++++++++++++++++++--------------------------------- 1 file changed, 53 insertions(+), 83 deletions(-) -- 2.7.4