fs: kernfs: Replace CURRENT_TIME by current_fs_time()
authorDeepa Dinamani <deepa.kernel@gmail.com>
Mon, 22 Feb 2016 15:17:53 +0000 (07:17 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 29 Mar 2016 17:11:44 +0000 (10:11 -0700)
commit3a3a5fece6f28c14d3d05c74fb7696412e53a067
tree9668de3af8008ff45cceda5c820711afead4bf1a
parent1b48b530dac3e600d92854d98a2a519243661f6c
fs: kernfs: Replace CURRENT_TIME by current_fs_time()

This is in preparation for the series that transitions
filesystem timestamps to use 64 bit time and hence make
them y2038 safe.

CURRENT_TIME macro will be deleted before merging the
aforementioned series.

Use current_fs_time() instead of CURRENT_TIME for inode
timestamps.

struct kernfs_node is associated with a sysfs file/ directory.
Truncate the values to appropriate time granularity when
writing to inode timestamps of the files.

ktime_get_real_ts() is used to obtain times for
struct kernfs_iattrs. Since these times are later assigned to
inode times using timespec_truncate() for all filesystem based
operations, we can save the supers list traversal time here by
using ktime_get_real_ts() directly.

Signed-off-by: Deepa Dinamani <deepa.kernel@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/kernfs/dir.c
fs/kernfs/inode.c
This page took 0.025579 seconds and 5 git commands to generate.