RETURN(0);
if (!is_only_remote_trans(th)) {
- if (o->opo_new)
- /* no need in logging for new objects being created */
- RETURN(0);
-
/*
* track all UID/GID changes via llog
*/
if (is_only_remote_trans(th)) {
rc = __osp_attr_set(env, dt, attr, th);
- if (rc == 0 && o->opo_new)
- o->opo_new = 0;
-
RETURN(rc);
}
if (!(attr->la_valid & (LA_UID | LA_GID)))
RETURN(0);
- /* new object, the very first ->attr_set()
- * initializing attributes needs no logging
- * all subsequent one are subject to the
- * logging and synchronization with OST */
- if (o->opo_new) {
- o->opo_new = 0;
- RETURN(0);
- }
-
rc = osp_sync_add(env, o, MDS_SETATTR64_REC, th, attr);
/* XXX: send new uid/gid to OST ASAP? */
oxe = osp_oac_xattr_find_or_add(o, name, buf->lb_len);
if (oxe == NULL) {
- CWARN("%s: Fail to add xattr (%s) to cache for "DFID,
+ CWARN("%s: cannot cache xattr '%s' of "DFID"\n",
dt->do_lu.lo_dev->ld_obd->obd_name,
name, PFID(lu_object_fid(&dt->do_lu)));
osp_oac_xattr_put(oxe);
oxe = tmp;
if (tmp == NULL) {
- CWARN("%s: Fail to update xattr (%s) to cache for "DFID,
+ CWARN("%s: cannot update cached xattr '%s' of "DFID"\n",
dt->do_lu.lo_dev->ld_obd->obd_name,
name, PFID(lu_object_fid(&dt->do_lu)));
spin_lock(&o->opo_lock);
}
}
- /* new object, the very first ->attr_set()
- * initializing attributes needs no logging */
- o->opo_new = 1;
-
/* Only need update last_used oid file, seq file will only be update
* during seq rollover */
osp_objid_buf_prep(&osi->osi_lb, &osi->osi_off,
* \retval 0 for success
* \retval negative error number on failure
*/
-int osp_orphan_it_next(const struct lu_env *env, struct dt_it *di)
+static int osp_orphan_it_next(const struct lu_env *env, struct dt_it *di)
{
struct osp_it *it = (struct osp_it *)di;
struct lu_idxpage *idxpage;
{
}
-struct dt_key *osp_orphan_it_key(const struct lu_env *env,
- const struct dt_it *di)
+static struct dt_key *osp_orphan_it_key(const struct lu_env *env,
+ const struct dt_it *di)
{
struct osp_it *it = (struct osp_it *)di;
struct lu_orphan_ent *ent = (struct lu_orphan_ent *)it->ooi_ent;
return NULL;
}
-int osp_orphan_it_key_size(const struct lu_env *env, const struct dt_it *di)
+static int osp_orphan_it_key_size(const struct lu_env *env,
+ const struct dt_it *di)
{
return sizeof(struct lu_fid);
}
-int osp_orphan_it_rec(const struct lu_env *env, const struct dt_it *di,
- struct dt_rec *rec, __u32 attr)
+static int osp_orphan_it_rec(const struct lu_env *env, const struct dt_it *di,
+ struct dt_rec *rec, __u32 attr)
{
struct osp_it *it = (struct osp_it *)di;
struct lu_orphan_ent *ent = (struct lu_orphan_ent *)it->ooi_ent;
return 0;
}
-struct dt_object_operations osp_obj_ops = {
+static struct dt_object_operations osp_obj_ops = {
.do_declare_attr_get = osp_declare_attr_get,
.do_attr_get = osp_attr_get,
.do_declare_attr_set = osp_declare_attr_set,