From c302d1774f5ed81193edec2d561456721cebd38f Mon Sep 17 00:00:00 2001 From: Oleg Drokin Date: Sun, 29 Jan 2012 19:27:20 -0500 Subject: [PATCH] LU-1042 ost: revert negative timestamp initialization This reverts commit 414251797ed178eec5d431e1f5aa4a889d2b159f from "LU-221 don't use a/c/m time for newly allocated objects", because it caused 1.8 clients to think that these files had a time in the distant past. Signed-off-by: Andreas Dilger Signed-off-by: Oleg Drokin --- lustre/obdfilter/filter.c | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/lustre/obdfilter/filter.c b/lustre/obdfilter/filter.c index 24f224a..d4b6631 100644 --- a/lustre/obdfilter/filter.c +++ b/lustre/obdfilter/filter.c @@ -3804,7 +3804,6 @@ static int filter_precreate(struct obd_device *obd, struct obdo *oa, struct dentry *dchild = NULL, *dparent = NULL; struct filter_obd *filter; struct obd_statfs *osfs; - struct iattr iattr; int err = 0, rc = 0, recreate_obj = 0, i; cfs_time_t enough_time = cfs_time_shift(DISK_TIMEOUT/2); __u64 os_ffree; @@ -3968,19 +3967,6 @@ static int filter_precreate(struct obd_device *obd, struct obdo *oa, dchild->d_inode->i_ino); set_last_id: - /* Set a/c/m time to a insane large negative value at creation - * time so that any timestamp arriving from the client will - * always be newer and update the inode. - * See LU-221 for details */ - iattr.ia_valid = ATTR_ATIME | ATTR_MTIME | ATTR_CTIME; - LTIME_S(iattr.ia_atime) = INT_MIN + 24 * 3600; - LTIME_S(iattr.ia_mtime) = INT_MIN + 24 * 3600; - LTIME_S(iattr.ia_ctime) = INT_MIN + 24 * 3600; - err = fsfilt_setattr(obd, dchild, handle, &iattr, 0); - if (err) - CERROR("unable to initialize a/c/m time of newly" - "created inode\n"); - if (!recreate_obj) { filter_set_last_id(filter, next_id, group); err = filter_update_last_objid(obd, group, 0); -- 1.8.3.1