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 Received: from lists.sourceforge.net (lists.sourceforge.net [216.105.38.7]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 1672DC04A94 for ; Tue, 8 Aug 2023 09:27:06 +0000 (UTC) Received: from [127.0.0.1] (helo=sfs-ml-4.v29.lw.sourceforge.com) by sfs-ml-4.v29.lw.sourceforge.com with esmtp (Exim 4.95) (envelope-from ) id 1qTIzY-00021P-Q8; Tue, 08 Aug 2023 09:27:05 +0000 Received: from [172.30.20.202] (helo=mx.sourceforge.net) by sfs-ml-4.v29.lw.sourceforge.com with esmtps (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.95) (envelope-from ) id 1qTIzX-00021J-SZ for linux-f2fs-devel@lists.sourceforge.net; Tue, 08 Aug 2023 09:27:04 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sourceforge.net; s=x; h=In-Reply-To:Content-Type:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=b3NxAQUEhhiHtmalxt25UQpIEh3A8DobG2qOMrP77WQ=; b=JD9/8vb4nVbSCoefCsw/mg0RDm xZ03we9lCfqvcEeRrns+bw1yyeKXcoQbPOgy/9rm3uba5v2n6xi+wrkZrp5avau4zVbaTFvWsmjD9 34oaH1dC9PIQDHNMiJwSZFxel7gqrNOF96CKai+RbKKF660U7WQMhgf/aUaMHAT4/Gww=; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sf.net; s=x ; h=In-Reply-To:Content-Type:MIME-Version:References:Message-ID:Subject:Cc:To :From:Date:Sender:Reply-To:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=b3NxAQUEhhiHtmalxt25UQpIEh3A8DobG2qOMrP77WQ=; b=BejmbNTRgd3Bdc3MirCg4Wl5tt CFLP8YVzpBxbAf4/wq5z5vGoK+hfcrpjjjWW102gwzYYC57ZC04Dy6SrADVjNHWW+AUudKoS2v637 ghLLeJjDhQ9tQYa0d/BFmTnqU2z+XGQR+y+6Qj3sSm5TMpgTNpE2UAkPwby0HPhPGCTw=; Received: from smtp-out2.suse.de ([195.135.220.29]) by sfi-mx-2.v28.lw.sourceforge.com with esmtps (TLS1.2:ECDHE-RSA-AES128-GCM-SHA256:128) (Exim 4.95) id 1qTIzU-0001jR-4m for linux-f2fs-devel@lists.sourceforge.net; Tue, 08 Aug 2023 09:27:04 +0000 Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id C51A520316; Tue, 8 Aug 2023 09:26:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1691486813; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=b3NxAQUEhhiHtmalxt25UQpIEh3A8DobG2qOMrP77WQ=; b=AoaZr4oK+uPjgRe+H1N/P4OqdxMzaLQwACpyg7af2LxycPofpRJURn7+dS209wAPqvb2Pa pyguefJyN0BETiXosk+qeiLcs65x2b42r4Xs2kf58Hhxb2lmpsj3DMEMMNaki6d405++FY 0hRnLs55sh8fmVIdow8NkLHWnHGd+BI= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1691486813; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=b3NxAQUEhhiHtmalxt25UQpIEh3A8DobG2qOMrP77WQ=; b=fxL/rpYwL46zGUX+wz6hOBohbpcZSktGMd5XhY0mnCjlb5Vurz5pFf3PTuD19V4sOSJ9Wo YCByPZ22Ze/c5AAQ== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 9677713451; Tue, 8 Aug 2023 09:26:53 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id rxmpJF0K0mRqGAAAMHmgww (envelope-from ); Tue, 08 Aug 2023 09:26:53 +0000 Received: by quack3.suse.cz (Postfix, from userid 1000) id 1DB1BA0769; Tue, 8 Aug 2023 11:26:53 +0200 (CEST) Date: Tue, 8 Aug 2023 11:26:53 +0200 From: Jan Kara To: Jeff Layton Message-ID: <20230808092653.ma6d72b4xwa3jk3f@quack3> References: <20230807-mgctime-v7-0-d1dec143a704@kernel.org> <20230807-mgctime-v7-4-d1dec143a704@kernel.org> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20230807-mgctime-v7-4-d1dec143a704@kernel.org> X-Headers-End: 1qTIzU-0001jR-4m Subject: Re: [f2fs-dev] [PATCH v7 04/13] btrfs: have it use inode_update_timestamps X-BeenThere: linux-f2fs-devel@lists.sourceforge.net X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Latchesar Ionkov , Martin Brandenburg , Konstantin Komarov , linux-xfs@vger.kernel.org, "Darrick J. Wong" , Dominique Martinet , Christian Schoenebeck , ecryptfs@vger.kernel.org, linux-unionfs@vger.kernel.org, David Howells , Chris Mason , Andreas Dilger , Hans de Goede , Marc Dionne , codalist@coda.cs.cmu.edu, linux-afs@lists.infradead.org, linux-mtd@lists.infradead.org, Mike Marshall , Paulo Alcantara , linux-cifs@vger.kernel.org, Eric Van Hensbergen , Andreas Gruenbacher , Miklos Szeredi , Richard Weinberger , Mark Fasheh , Hugh Dickins , Benjamin Coddington , Tyler Hicks , cluster-devel@redhat.com, coda@cs.cmu.edu, linux-mm@kvack.org, Ilya Dryomov , Iurii Zaikin , Namjae Jeon , Trond Myklebust , Shyam Prasad N , Amir Goldstein , Kees Cook , ocfs2-devel@lists.linux.dev, Josef Bacik , Tom Talpey , Tejun Heo , Yue Hu , Alexander Viro , Ronnie Sahlberg , David Sterba , Jaegeuk Kim , ceph-devel@vger.kernel.org, Xiubo Li , Gao Xiang , OGAWA Hirofumi , Jan Harkes , Christian Brauner , linux-ext4@vger.kernel.org, Theodore Ts'o , Joseph Qi , Greg Kroah-Hartman , v9fs@lists.linux.dev, ntfs3@lists.linux.dev, samba-technical@lists.samba.org, linux-kernel@vger.kernel.org, linux-f2fs-devel@lists.sourceforge.net, Steve French , Sergey Senozhatsky , Luis Chamberlain , Jeffle Xu , devel@lists.orangefs.org, Anna Schumaker , Jan Kara , Bob Peterson , linux-fsdevel@vger.kernel.org, Andrew Morton , Sungjong Seo , linux-erofs@lists.ozlabs.org, linux-nfs@vger.kernel.org, linux-btrfs@vger.kernel.org, Joel Becker Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: linux-f2fs-devel-bounces@lists.sourceforge.net On Mon 07-08-23 15:38:35, Jeff Layton wrote: > In later patches, we're going to drop the "now" argument from the > update_time operation. Have btrfs_update_time use the new > inode_update_timestamps helper to fetch a new timestamp and update it > properly. > > Signed-off-by: Jeff Layton Nice cleanup! Feel free to add: Reviewed-by: Jan Kara Honza > --- > fs/btrfs/inode.c | 9 +-------- > 1 file changed, 1 insertion(+), 8 deletions(-) > > diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c > index 29a20f828dda..d52e7d64570a 100644 > --- a/fs/btrfs/inode.c > +++ b/fs/btrfs/inode.c > @@ -6068,14 +6068,7 @@ static int btrfs_update_time(struct inode *inode, struct timespec64 *now, > if (btrfs_root_readonly(root)) > return -EROFS; > > - if (flags & S_VERSION) > - dirty |= inode_maybe_inc_iversion(inode, dirty); > - if (flags & S_CTIME) > - inode_set_ctime_to_ts(inode, *now); > - if (flags & S_MTIME) > - inode->i_mtime = *now; > - if (flags & S_ATIME) > - inode->i_atime = *now; > + dirty = inode_update_timestamps(inode, flags); > return dirty ? btrfs_dirty_inode(BTRFS_I(inode)) : 0; > } > > > -- > 2.41.0 > -- Jan Kara SUSE Labs, CR _______________________________________________ Linux-f2fs-devel mailing list Linux-f2fs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel