Whamcloud - gitweb
b=15625
[fs/lustre-release.git] / lustre / include / md_object.h
index c4ebbb0..bc67759 100644 (file)
@@ -47,20 +47,15 @@ struct md_device_operations;
 struct md_object;
 
 
-typedef enum {
+enum {
         UCRED_INVALID   = -1,
         UCRED_INIT      = 0,
         UCRED_OLD       = 1,
-        UCRED_NEW       = 2,
-} ucred_t;
-
-#define SQUASH_NONE     0x00
-#define SQUASH_UID      0x01
-#define SQUASH_GID      0x02
+        UCRED_NEW       = 2
+};
 
 struct md_ucred {
-        ucred_t                 mu_valid;
-        __u32                   mu_squash;
+        __u32               mu_valid;
         __u32                   mu_o_uid;
         __u32                   mu_o_gid;
         __u32                   mu_o_fsuid;
@@ -73,7 +68,7 @@ struct md_ucred {
         __u32                   mu_cap;
         __u32                   mu_umask;
        struct group_info      *mu_ginfo;
-       struct mdt_identity    *mu_identity;
+       struct md_identity *mu_identity;
 };
 
 #define MD_CAPAINFO_MAX 5
@@ -101,7 +96,8 @@ enum ma_valid {
         MA_COOKIE    = (1 << 2),
         MA_FLAGS     = (1 << 3),
         MA_LMV       = (1 << 4),
-        MA_ACL_DEF   = (1 << 5)
+        MA_ACL_DEF   = (1 << 5),
+        MA_LOV_DEF   = (1 << 6)
 };
 
 typedef enum {
@@ -190,10 +186,10 @@ struct md_object_operations {
 
         int (*moo_xattr_set)(const struct lu_env *env, struct md_object *obj,
                              const struct lu_buf *buf, const char *name,
-                             int fl);
+                             int fl, const struct lu_attr *la);
 
         int (*moo_xattr_del)(const struct lu_env *env, struct md_object *obj,
-                             const char *name);
+                             const char *name, const struct lu_attr *la);
 
         int (*moo_readpage)(const struct lu_env *env, struct md_object *obj,
                             const struct lu_rdpg *rdpg);
@@ -305,6 +301,7 @@ enum md_upcall_event {
         /*sync the md layer*/
         MD_LOV_SYNC = (1 << 0),
         MD_NO_TRANS = (1 << 1), /* Just for split, no need trans, for replay */
+        MD_LOV_CONFIG = (1 << 2)
 };
 
 struct md_upcall {
@@ -455,20 +452,22 @@ static inline int mo_xattr_get(const struct lu_env *env,
 
 static inline int mo_xattr_del(const struct lu_env *env,
                                struct md_object *m,
-                               const char *name)
+                               const char *name,
+                               const struct lu_attr *la)
 {
         LASSERT(m->mo_ops->moo_xattr_del);
-        return m->mo_ops->moo_xattr_del(env, m, name);
+        return m->mo_ops->moo_xattr_del(env, m, name, la);
 }
 
 static inline int mo_xattr_set(const struct lu_env *env,
                                struct md_object *m,
                                const struct lu_buf *buf,
                                const char *name,
-                               int flags)
+                               int flags,
+                               const struct lu_attr *la)
 {
         LASSERT(m->mo_ops->moo_xattr_set);
-        return m->mo_ops->moo_xattr_set(env, m, buf, name, flags);
+        return m->mo_ops->moo_xattr_set(env, m, buf, name, flags, la);
 }
 
 static inline int mo_xattr_list(const struct lu_env *env,