int mdd_attr_set(const struct lu_env *env, struct md_object *obj,
const struct md_attr *ma);
int mdd_attr_set_internal(const struct lu_env *env,
- struct mdd_object *obj,
- struct lu_attr *attr,
- struct thandle *handle,
- int needacl);
+ struct mdd_object *obj,
+ const struct lu_attr *attr,
+ struct thandle *handle,
+ int needacl);
int mdd_attr_check_set_internal(const struct lu_env *env,
struct mdd_object *obj,
struct lu_attr *attr,
struct md_attr *ma, struct thandle *th);
int mdd_object_initialize(const struct lu_env *env, const struct lu_fid *pfid,
const struct lu_name *lname, struct mdd_object *child,
- struct lu_attr *attr, struct thandle *handle,
+ const struct lu_attr *attr, struct thandle *handle,
const struct md_op_spec *spec);
int mdd_link_sanity_check(const struct lu_env *env, struct mdd_object *tgt_obj,
const struct lu_name *lname, struct mdd_object *src_obj);
int is_dir, struct thandle *handle);
int mdd_acl_set(const struct lu_env *env, struct mdd_object *obj,
const struct lu_buf *buf, int fl);
-int __mdd_acl_init(const struct lu_env *env, struct mdd_object *obj,
- struct lu_buf *buf, __u32 *mode, struct thandle *handle);
+int __mdd_fix_mode_acl(const struct lu_env *env, struct lu_buf *buf,
+ __u32 *mode);
int __mdd_permission_internal(const struct lu_env *env, struct mdd_object *obj,
struct lu_attr *la, int mask, int role);
int mdd_permission(const struct lu_env *env,
struct thandle *handle)
{
struct dt_object *next = mdd_object_child(o);
- struct lu_ucred *uc = lu_ucred(env);
- __u32 saved;
int rc;
- /*
- * LU-974 enforce client umask in creation.
- * TODO: CMD needs to handle this for remote object.
- */
- if (likely(uc != NULL))
- saved = xchg(¤t->fs->umask, uc->uc_umask & S_IRWXUGO);
-
rc = next->do_ops->do_create(env, next, attr, hint, dof, handle);
- /* restore previous umask value */
- if (likely(uc != NULL))
- current->fs->umask = saved;
-
return rc;
}