From 5acd57936c3224fd86e838201e528e0169373e9b Mon Sep 17 00:00:00 2001 From: Tejun Heo Date: Tue, 6 Sep 2005 15:17:36 -0700 Subject: [PATCH] [PATCH] fs: remove redundant timespec_equal test in update_atime() In update_atime(), timespec_equal() test is done twice in succession and the second is always false. This patch removes the second test. Signed-off-by: Tejun Heo Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- fs/inode.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/fs/inode.c b/fs/inode.c index e57f1724db..71df1b1e8f 100644 --- a/fs/inode.c +++ b/fs/inode.c @@ -1195,9 +1195,6 @@ void update_atime(struct inode *inode) if (!timespec_equal(&inode->i_atime, &now)) { inode->i_atime = now; mark_inode_dirty_sync(inode); - } else { - if (!timespec_equal(&inode->i_atime, &now)) - inode->i_atime = now; } } -- 2.39.5