From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755786AbcBXPIn (ORCPT ); Wed, 24 Feb 2016 10:08:43 -0500 Received: from mout.kundenserver.de ([217.72.192.75]:64950 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751866AbcBXPIl (ORCPT ); Wed, 24 Feb 2016 10:08:41 -0500 From: Arnd Bergmann To: y2038@lists.linaro.org Cc: Trond Myklebust , Deepa Dinamani , Linux NFS Mailing List , Linux Network Devel Mailing List , Linux Kernel Mailing List , "David S. Miller" , "J. Bruce Fields" , Linux FS-devel Mailing List , Jeff Layton , Anna Schumaker Subject: Re: [Y2038] [PATCH 8/8] net: sunrpc: Replace CURRENT_TIME by current_fs_time() Date: Wed, 24 Feb 2016 16:08:23 +0100 Message-ID: <3612929.btSLWR6eWu@wuerfel> User-Agent: KMail/4.11.5 (Linux/3.16.0-10-generic; KDE/4.11.5; x86_64; ; ) In-Reply-To: References: <1456154274-30487-1-git-send-email-deepa.kernel@gmail.com> <1456154274-30487-9-git-send-email-deepa.kernel@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" X-Provags-ID: V03:K0:c8PJi1kBuEqUrMViBbKffbvJt+ypO5dgLRMyt8OzGOs6w3iApNt riTPRENw0BzKDvj2bWDPp+QGlH/Lbdd1PCzh4x5fZ1pssU9E94UIJ1+rXQxPzZ7qcsN3n6m DxSxRwKFVyH3xeFzHAS3D1f1sQstWWqx8+CoDrw1VvhuTR8azcn54UgAxCjO381JQCbC0hC /pevWUXHC9I1Hg1koRdYg== X-UI-Out-Filterresults: notjunk:1;V01:K0:2prZfCJ2iJM=:AmC0L1L17tSBsMKt15YOJG agyCybH8sAPxFwusb5KY7Zprh88M3uZ8pI8FLrcj7rn+iyjanmWaAFzYlZFZ0ckAzxTUVCUdu LIo8+3pPwmOjoEDqaREMkoBZgYT7qfQBUKF4mH5R/fkLZBqHlm1SJPBDsAp4BMBt0qKHCRqZq xiE7w3ZCGFnlWWXCbza02JsouEC8HkoMNwDxBJSqPAfsK+pPGZFgiaQTUm6O5pfJ6iDr3/wtY cMDFuPu7KnWG82z5+bTLuVXDpaeO507SRCBBmw78Tw48GhGjgMkHkIdiGZfcZkOhW0+9ykF15 P0xPhhX9LUwxwhF+AzWFUATOhZnSKkClNsRzqy3KyjA13ixVUD97HoL7SDslPgpuw/ew9Ntum BzLtHykGtBapkPYQ0rjyixVOCEFwINSsnrm4y54GP2ig9NZWaDpLyeQpS0PGV+t2+nyFlz/s6 AZQQPAfXr9g/2v+Ik7OPKzQyj8dwbylAjzWQhBdbZiwidYNq6GMHGnidEH9djbe9npvYIhPJ8 2maN3ZSvGO1lRYBn1kg/9Ys6eRFv2P2RMl1YO4jyCv7AmT/F0ty/Fdorl1JK/+7zl/j+CPT3R a5PYrZg8W5FXDahQrS6bTbtD1+h3RABoTDLk05jcejOW0R910h4QqUMIRAH/xjxkuW/cjhcyo 1OPnV6BxwcEo89FudrqOKGVDwl8yhjhF78UxmtfeKu2/IjE5NgrpCEh/bBlK+ulhHXaWV3n8/ RGU475i29oX6Ebyn Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Monday 22 February 2016 10:34:31 Trond Myklebust wrote: > > diff --git a/net/sunrpc/rpc_pipe.c b/net/sunrpc/rpc_pipe.c > > index 31789ef..bab3187 100644 > > --- a/net/sunrpc/rpc_pipe.c > > +++ b/net/sunrpc/rpc_pipe.c > > @@ -477,7 +477,9 @@ rpc_get_inode(struct super_block *sb, umode_t mode) > > return NULL; > > inode->i_ino = get_next_ino(); > > inode->i_mode = mode; > > - inode->i_atime = inode->i_mtime = inode->i_ctime = CURRENT_TIME; > > + inode->i_atime = current_fs_time(sb); > > + inode->i_mtime = inode->i_atime; > > + inode->i_ctime = inode->i_atime; > > switch (mode & S_IFMT) { > > case S_IFDIR: > > inode->i_fop = &simple_dir_operations; > > Why would we care? This is a pseudo-fs. There is no expectation w.r.t. > timestamp accuracy or resolution. As Deepa said, the primary goal is to unify the interface, so we have only one place function that handles setting the time in an inode, and we want to avoid CURRENT_TIME, as that is currently used in a couple of places for things other than inode timestamps that we don't want to convert to 64-bit times at the same time. current_fs_time() has a very small overhead compared to CURRENT_TIME, if you think it's worth avoiding that, we could introduce a current_pseudo_fs_time() function that does not take a superblock argument but is more tied to inode timestamps than CURRENT_TIME is. Arnd