From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751911AbcBLJhG (ORCPT ); Fri, 12 Feb 2016 04:37:06 -0500 Received: from mail-pf0-f172.google.com ([209.85.192.172]:36364 "EHLO mail-pf0-f172.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751320AbcBLJg7 (ORCPT ); Fri, 12 Feb 2016 04:36:59 -0500 From: Deepa Dinamani To: linux-fsdevel@vger.kernel.org, y2038@lists.linaro.org Cc: Arnd Bergmann , Dave Chinner , "Theodore Ts'o" , linux-kernel@vger.kernel.org Subject: [RFC v2a 07/12] fs: btrfs: Use vfs_time data type for btrfs_update_time() Date: Fri, 12 Feb 2016 01:36:01 -0800 Message-Id: <1455269766-2994-8-git-send-email-deepa.kernel@gmail.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1455269766-2994-1-git-send-email-deepa.kernel@gmail.com> References: <20160212092153.GA2368@deepa-ubuntu> <1455269766-2994-1-git-send-email-deepa.kernel@gmail.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The VFS inode timestamps are not y2038 safe as they use struct timespec. These will be changed to use struct timespec64 instead and that is y2038 safe. But, since the above data type conversion will break the end file systems, use vfs_time aliases here to access inode times. This is set as a vfs callback function for inode operations. This accepts inode timestamp as an argument. And, needs to switch to 64 bit time representation along with vfs. Signed-off-by: Deepa Dinamani --- fs/btrfs/inode.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c index 59c0e22..6f0417b 100644 --- a/fs/btrfs/inode.c +++ b/fs/btrfs/inode.c @@ -5942,7 +5942,7 @@ static int btrfs_dirty_inode(struct inode *inode) * This is a copy of file_update_time. We need this so we can return error on * ENOSPC for updating the inode in the case of file write and mmap writes. */ -static int btrfs_update_time(struct inode *inode, struct timespec *now, +static int btrfs_update_time(struct inode *inode, struct vfs_time *now, int flags) { struct btrfs_root *root = BTRFS_I(inode)->root; -- 1.9.1