From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.8 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id CDF71C4361B for ; Tue, 15 Dec 2020 01:13:40 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 8BB0420857 for ; Tue, 15 Dec 2020 01:13:40 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728715AbgLOBNY (ORCPT ); Mon, 14 Dec 2020 20:13:24 -0500 Received: from mail106.syd.optusnet.com.au ([211.29.132.42]:41141 "EHLO mail106.syd.optusnet.com.au" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728613AbgLOBNY (ORCPT ); Mon, 14 Dec 2020 20:13:24 -0500 Received: from dread.disaster.area (pa49-179-6-140.pa.nsw.optusnet.com.au [49.179.6.140]) by mail106.syd.optusnet.com.au (Postfix) with ESMTPS id 502E87668A5; Tue, 15 Dec 2020 12:12:41 +1100 (AEDT) Received: from dave by dread.disaster.area with local (Exim 4.92.3) (envelope-from ) id 1koytM-0043LY-Pw; Tue, 15 Dec 2020 12:12:40 +1100 Date: Tue, 15 Dec 2020 12:12:40 +1100 From: Dave Chinner To: Yafang Shao Cc: "Darrick J. Wong" , Matthew Wilcox , Christoph Hellwig , Michal Hocko , Andrew Morton , David Howells , jlayton@redhat.com, linux-fsdevel@vger.kernel.org, linux-cachefs@redhat.com, linux-xfs@vger.kernel.org, Linux MM , Christoph Hellwig Subject: Re: [PATCH v12 3/4] xfs: refactor the usage around xfs_trans_context_{set,clear} Message-ID: <20201215011240.GJ632069@dread.disaster.area> References: <20201209131146.67289-1-laoar.shao@gmail.com> <20201209131146.67289-4-laoar.shao@gmail.com> <20201209195235.GN1943235@magnolia> <20201214210833.GE632069@dread.disaster.area> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Optus-CM-Score: 0 X-Optus-CM-Analysis: v=2.3 cv=YKPhNiOx c=1 sm=1 tr=0 cx=a_idp_d a=uDU3YIYVKEaHT0eX+MXYOQ==:117 a=uDU3YIYVKEaHT0eX+MXYOQ==:17 a=kj9zAlcOel0A:10 a=zTNgK-yGK50A:10 a=7-415B0cAAAA:8 a=yPCof4ZbAAAA:8 a=U7ryOahPNW6b4qIbDJ8A:9 a=CjuIK1q_8ugA:10 a=biEYGPWJfzWAr4FL6Ov7:22 Precedence: bulk List-ID: X-Mailing-List: linux-xfs@vger.kernel.org On Tue, Dec 15, 2020 at 08:42:08AM +0800, Yafang Shao wrote: > On Tue, Dec 15, 2020 at 5:08 AM Dave Chinner wrote: > > On Sun, Dec 13, 2020 at 05:09:02PM +0800, Yafang Shao wrote: > > > On Thu, Dec 10, 2020 at 3:52 AM Darrick J. Wong wrote: > > > > On Wed, Dec 09, 2020 at 09:11:45PM +0800, Yafang Shao wrote: > > static inline void > > xfs_trans_context_clear(struct xfs_trans *tp) > > { > > /* > > * If xfs_trans_context_swap() handed the NOFS context to a > > * new transaction we do not clear the context here. > > */ > > if (current->journal_info != tp) > > current->journal_info hasn't been used in patch #3, that will make > patch #3 a little more complex. > We have to do some workaround in patch #3. I will think about it. What I wrote is how the function should look at the end of the patch series. Do not add the current->journal_info parts of it until the patch that introduces the current->journal_info tracking. -Dave. -- Dave Chinner david@fromorbit.com