From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753799AbcFTJsD (ORCPT ); Mon, 20 Jun 2016 05:48:03 -0400 Received: from mx2.suse.de ([195.135.220.15]:51693 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751189AbcFTJry (ORCPT ); Mon, 20 Jun 2016 05:47:54 -0400 Date: Mon, 20 Jun 2016 11:46:09 +0200 From: David Sterba To: Deepa Dinamani Cc: linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, arnd@arndb.de, tglx@linutronix.de, torvalds@linux-foundation.org, tytso@mit.edu, viro@zeniv.linux.org.uk, y2038@lists.linaro.org, Chris Mason , Josef Bacik , David Sterba , linux-btrfs@vger.kernel.org Subject: Re: [PATCH v2 08/24] fs: btrfs: Use ktime_get_real_ts for root ctime Message-ID: <20160620094608.GL4915@twin.jikos.cz> Reply-To: dsterba@suse.cz Mail-Followup-To: dsterba@suse.cz, Deepa Dinamani , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, arnd@arndb.de, tglx@linutronix.de, torvalds@linux-foundation.org, tytso@mit.edu, viro@zeniv.linux.org.uk, y2038@lists.linaro.org, Chris Mason , Josef Bacik , David Sterba , linux-btrfs@vger.kernel.org References: <1466382443-11063-1-git-send-email-deepa.kernel@gmail.com> <1466382443-11063-9-git-send-email-deepa.kernel@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1466382443-11063-9-git-send-email-deepa.kernel@gmail.com> User-Agent: Mutt/1.5.23.1 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sun, Jun 19, 2016 at 05:27:07PM -0700, Deepa Dinamani wrote: > btrfs_root_item maintains the ctime for root updates. > This is not part of vfs_inode. > > Since current_time() uses struct inode* as an argument > as Linus suggested, this cannot be used to update root > times unless, we modify the signature to use inode. > > Since btrfs uses nanosecond time granularity, it can also > use ktime_get_real_ts directly to obtain timestamp for > the root. It is necessary to use the timespec time api > here because the same btrfs_set_stack_timespec_*() apis > are used for vfs inode times as well. These can be > transitioned to using timespec64 when btrfs internally > changes to use timespec64 as well. > > Signed-off-by: Deepa Dinamani > Cc: Chris Mason > Cc: Josef Bacik Acked-by: David Sterba