Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp2306905ybz; Thu, 23 Apr 2020 15:38:57 -0700 (PDT) X-Google-Smtp-Source: APiQypKNnOh1aM29zYyS/wM+wmOahgkD95WFq8TBEKg11kgr5CG3zsXSfRe7Wtnka4VfvjQzYdm0 X-Received: by 2002:aa7:c497:: with SMTP id m23mr4641476edq.155.1587681537618; Thu, 23 Apr 2020 15:38:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1587681537; cv=none; d=google.com; s=arc-20160816; b=r9c+EMiHc4bcAZPVMdLk4gzjzSBFw2PRj5pG3TNeiJbu9Ri/cUWbF+EBrqzBm4U7Xs lQVBreZgEoDurbpvySKe40ex8A6IKyItC5Tq7HG/ND8JBGth6P+qxlbTlXoLIih7jXF+ XNtVQCbzi5DlWDTmK3KvwsIn0qEiMjpt4i7x8bWG4dhOEvxeqXDfG1JBQ8NWSclNK7lP KfCywnNpm3JlkU5F6irFFSlHkk2E+NhEo62g6RWcvKn7w5onfQWS6fDX+RzeEAqta8dl eptEgLz/zN1YCkL5Z2l/facYIqyVJZC92rdLkzs7wL/Myn6INn2FRJYQPirvM48xwqPS w3Kg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=O4NAeGLKMpCmRiOoeXhh4PGqLv6REv1ig1/boLyYDsg=; b=TQS361LdjnOt4+oO1O8onVZBZcqhW4LIlAWMnTx9oy5MxbZaunuFa6g+gptKSlO+Lw fL+jTmR+JZPBKo7XtFsUfoTdbst5QbCp9rSRMhgJTwslyRoGHhuqYDnjDPo2uCLEDur6 H1sO6TN8E0ceU47vDWUow7U2bxm4+xseaQQ1CfjcSbnM17+4ipKEX6nBrekoxmO+zsFu BngYAAHHSNx7beVEoK++A1YIZG2GBq3PvDFCiJQOkr7CsUzJprsQCmfcAn7NbcnY3abN wB8beYT4vkXzuZKC/7TiYMUDFMmfnil7hbIaw2moLxp3qcQdHwDlEexnGVuu8ZlA6lW7 PVzw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id o59si1893670eda.39.2020.04.23.15.38.20; Thu, 23 Apr 2020 15:38:57 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727021AbgDWWh0 (ORCPT + 99 others); Thu, 23 Apr 2020 18:37:26 -0400 Received: from mail105.syd.optusnet.com.au ([211.29.132.249]:53306 "EHLO mail105.syd.optusnet.com.au" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726057AbgDWWh0 (ORCPT ); Thu, 23 Apr 2020 18:37:26 -0400 Received: from dread.disaster.area (pa49-180-0-232.pa.nsw.optusnet.com.au [49.180.0.232]) by mail105.syd.optusnet.com.au (Postfix) with ESMTPS id E924B3A2FF9; Fri, 24 Apr 2020 08:37:22 +1000 (AEST) Received: from dave by dread.disaster.area with local (Exim 4.92.3) (envelope-from ) id 1jRkTB-0006mp-8o; Fri, 24 Apr 2020 08:37:21 +1000 Date: Fri, 24 Apr 2020 08:37:21 +1000 From: Dave Chinner To: ira.weiny@intel.com Cc: linux-kernel@vger.kernel.org, linux-xfs@vger.kernel.org, "Darrick J. Wong" , Al Viro , Jan Kara , Dan Williams , Christoph Hellwig , "Theodore Y. Ts'o" , Jeff Moyer , linux-ext4@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-api@vger.kernel.org Subject: Re: [PATCH V10 08/11] fs/xfs: Combine xfs_diflags_to_linux() and xfs_diflags_to_iflags() Message-ID: <20200423223721.GW27860@dread.disaster.area> References: <20200422212102.3757660-1-ira.weiny@intel.com> <20200422212102.3757660-9-ira.weiny@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200422212102.3757660-9-ira.weiny@intel.com> User-Agent: Mutt/1.10.1 (2018-07-13) X-Optus-CM-Score: 0 X-Optus-CM-Analysis: v=2.3 cv=W5xGqiek c=1 sm=1 tr=0 a=XYjVcjsg+1UI/cdbgX7I7g==:117 a=XYjVcjsg+1UI/cdbgX7I7g==:17 a=kj9zAlcOel0A:10 a=cl8xLZFz6L8A:10 a=QyXUC8HyAAAA:8 a=yPCof4ZbAAAA:8 a=20KFwNOVAAAA:8 a=7-415B0cAAAA:8 a=bYJC6cjInicVMxXmsOoA:9 a=CjuIK1q_8ugA:10 a=biEYGPWJfzWAr4FL6Ov7:22 Sender: linux-ext4-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org On Wed, Apr 22, 2020 at 02:20:59PM -0700, ira.weiny@intel.com wrote: > From: Ira Weiny > > The functionality in xfs_diflags_to_linux() and xfs_diflags_to_iflags() are > nearly identical. The only difference is that *_to_linux() is called after > inode setup and disallows changing the DAX flag. > > Combining them can be done with a flag which indicates if this is the initial > setup to allow the DAX flag to be properly set only at init time. > > So remove xfs_diflags_to_linux() and call the modified xfs_diflags_to_iflags() > directly. > > While we are here simplify xfs_diflags_to_iflags() to take struct xfs_inode and > use xfs_ip2xflags() to ensure future diflags are included correctly. > > Reviewed-by: Darrick J. Wong > Signed-off-by: Ira Weiny Looks good. Reviewed-by: Dave Chinner -- Dave Chinner david@fromorbit.com