lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed,  8 Jun 2016 22:04:56 -0700
From:	Deepa Dinamani <deepa.kernel@...il.com>
To:	linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org
Cc:	Arnd Bergmann <arnd@...db.de>,
	Thomas Gleixner <tglx@...utronix.de>,
	Al Viro <viro@...iv.linux.org.uk>,
	Linus Torvalds <torvalds@...ux-foundation.org>,
	y2038@...ts.linaro.org, Ilya Dryomov <idryomov@...il.com>,
	Sage Weil <sage@...hat.com>, Alex Elder <elder@...nel.org>,
	ceph-devel@...r.kernel.org
Subject: [PATCH 12/21] block: rbd: Replace non inode CURRENT_TIME with current_fs_time()

CURRENT_TIME macro is not appropriate for filesystems as it
doesn't use the right granularity for filesystem timestamps.
Use current_fs_time() instead.

This is also in preparation for the patch that transitions
vfs timestamps to use 64 bit time and hence make them
y2038 safe. As part of the effort current_fs_time() will be
extended to do range checks. Hence, it is necessary for all
file system timestamps to use current_fs_time().

Signed-off-by: Deepa Dinamani <deepa.kernel@...il.com>
Cc: Ilya Dryomov <idryomov@...il.com>
Cc: Sage Weil <sage@...hat.com>
Cc: Alex Elder <elder@...nel.org>
Cc: ceph-devel@...r.kernel.org
---
 drivers/block/rbd.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/block/rbd.c b/drivers/block/rbd.c
index 81666a5..4dcafe4 100644
--- a/drivers/block/rbd.c
+++ b/drivers/block/rbd.c
@@ -1888,7 +1888,7 @@ static void rbd_osd_req_format_write(struct rbd_obj_request *obj_request)
 {
 	struct ceph_osd_request *osd_req = obj_request->osd_req;
 
-	osd_req->r_mtime = CURRENT_TIME;
+	osd_req->r_mtime = current_fs_time(osd_req->r_inode->i_sb);
 	osd_req->r_data_offset = obj_request->offset;
 }
 
-- 
1.9.1

Powered by blists - more mailing lists