X-Git-Url: https://git.whamcloud.com/?p=fs%2Flustre-release.git;a=blobdiff_plain;f=lustre%2Fofd%2Fofd_objects.c;h=4c7697292db79f586c85b705c65420f4b0028435;hp=e98e72bd226004c3290c97c38dcc115cd483aa10;hb=97a10cf9797bbed02fb131f6a205b6a0ceeb0525;hpb=312e06c24f3a7f8ef7ea43ecd10f04d80c623f14 diff --git a/lustre/ofd/ofd_objects.c b/lustre/ofd/ofd_objects.c index e98e72b..4c76972 100644 --- a/lustre/ofd/ofd_objects.c +++ b/lustre/ofd/ofd_objects.c @@ -664,10 +664,6 @@ int ofd_attr_set(const struct lu_env *env, struct ofd_object *fo, if (!ofd_object_exists(fo)) GOTO(out, rc = -ENOENT); - if (la->la_valid & (LA_ATIME | LA_MTIME | LA_CTIME)) - tgt_fmd_update(info->fti_exp, &fo->ofo_header.loh_fid, - info->fti_xid); - /* VBR: version recovery check */ rc = ofd_version_get_check(info, fo); if (rc) @@ -700,6 +696,11 @@ int ofd_attr_set(const struct lu_env *env, struct ofd_object *fo, if (!ofd_object_exists(fo)) GOTO(unlock, rc = -ENOENT); + /* serialize vs ofd_commitrw_write() */ + if (la->la_valid & (LA_ATIME | LA_MTIME | LA_CTIME)) + tgt_fmd_update(info->fti_exp, &fo->ofo_header.loh_fid, + info->fti_xid); + rc = dt_attr_set(env, ofd_object_child(fo), la, th); if (rc) GOTO(unlock, rc);