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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id A6C82EB64DD for ; Thu, 6 Jul 2023 02:00:40 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233049AbjGFCAj (ORCPT ); Wed, 5 Jul 2023 22:00:39 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54632 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232692AbjGFCAh (ORCPT ); Wed, 5 Jul 2023 22:00:37 -0400 X-Greylist: delayed 378 seconds by postgrey-1.37 at lindbergh.monkeyblade.net; Wed, 05 Jul 2023 19:00:31 PDT Received: from mail.parknet.co.jp (mail.parknet.co.jp [210.171.160.6]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id B99981BDF; Wed, 5 Jul 2023 19:00:31 -0700 (PDT) Received: from ibmpc.myhome.or.jp (server.parknet.ne.jp [210.171.168.39]) by mail.parknet.co.jp (Postfix) with ESMTPSA id D02902055F9C; Thu, 6 Jul 2023 10:54:11 +0900 (JST) Received: from devron.myhome.or.jp (foobar@devron.myhome.or.jp [192.168.0.3]) by ibmpc.myhome.or.jp (8.17.2/8.17.2/Debian-1) with ESMTPS id 3661sAmO013519 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NOT); Thu, 6 Jul 2023 10:54:11 +0900 Received: from devron.myhome.or.jp (foobar@localhost [127.0.0.1]) by devron.myhome.or.jp (8.17.2/8.17.2/Debian-1) with ESMTPS id 3661sAor045796 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NOT); Thu, 6 Jul 2023 10:54:10 +0900 Received: (from hirofumi@localhost) by devron.myhome.or.jp (8.17.2/8.17.2/Submit) id 3661s99N045795; Thu, 6 Jul 2023 10:54:09 +0900 From: OGAWA Hirofumi To: Jeff Layton Cc: Christian Brauner , Al Viro , Jan Kara , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v2 44/92] fat: convert to ctime accessor functions In-Reply-To: <20230705190309.579783-42-jlayton@kernel.org> (Jeff Layton's message of "Wed, 5 Jul 2023 15:01:09 -0400") References: <20230705185755.579053-1-jlayton@kernel.org> <20230705190309.579783-1-jlayton@kernel.org> <20230705190309.579783-42-jlayton@kernel.org> Date: Thu, 06 Jul 2023 10:54:09 +0900 Message-ID: <87zg49yfcu.fsf@mail.parknet.co.jp> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Jeff Layton writes: > @@ -1407,8 +1407,9 @@ static int fat_read_root(struct inode *inode) > MSDOS_I(inode)->mmu_private = inode->i_size; > > fat_save_attrs(inode, ATTR_DIR); > - inode->i_mtime.tv_sec = inode->i_atime.tv_sec = inode->i_ctime.tv_sec = 0; > - inode->i_mtime.tv_nsec = inode->i_atime.tv_nsec = inode->i_ctime.tv_nsec = 0; > + inode->i_mtime.tv_sec = inode->i_atime.tv_sec = inode_set_ctime(inode, > + 0, 0).tv_sec; > + inode->i_mtime.tv_nsec = inode->i_atime.tv_nsec = 0; Maybe, this should simply be inode->i_mtime = inode->i_atime = inode_set_ctime(inode, 0, 0); ? Thanks. -- OGAWA Hirofumi