Whamcloud - gitweb
LU-4755 ptlrpc: enlarge OST_MAXREQSIZE for 4MB RPC
[fs/lustre-release.git] / lustre / lod / lod_internal.h
index af1457c..22d248c 100644 (file)
@@ -158,7 +158,8 @@ struct lod_device {
        spinlock_t            lod_connects_lock;
        int                   lod_connects;
        unsigned int          lod_recovery_completed:1,
-                             lod_initialized:1;
+                             lod_initialized:1,
+                             lod_lmv_failout:1;
 
        /* lov settings descriptor storing static information */
        struct lov_desc       lod_desc;
@@ -278,11 +279,12 @@ struct lod_thread_info {
        struct lu_attr    lti_attr;
        struct lod_it     lti_it;
        struct ldlm_res_id lti_res_id;
-
-       /* used to hold lu_dirent, NAME_MAX + sizeof(struct lu_dirent) */
-       char              lti_key[NAME_MAX + sizeof(struct lu_dirent)];
-
+       /* used to hold lu_dirent, sizeof(struct lu_dirent) + NAME_MAX */
+       char              lti_key[sizeof(struct lu_dirent) + NAME_MAX];
        struct dt_object_format lti_format;
+       struct lu_name    lti_name;
+       struct lu_buf     lti_linkea_buf;
+       struct dt_insert_rec lti_dt_rec;
 };
 
 extern const struct lu_device_operations lod_lu_ops;
@@ -358,6 +360,17 @@ static inline struct lod_thread_info *lod_env_info(const struct lu_env *env)
        return info;
 }
 
+static inline struct lu_name *
+lod_name_get(const struct lu_env *env, const void *area, int len)
+{
+       struct lu_name *lname;
+
+       lname = &lod_env_info(env)->lti_name;
+       lname->ln_name = area;
+       lname->ln_namelen = len;
+       return lname;
+}
+
 #define lod_foreach_ost(__dev, index)  \
        if ((__dev)->lod_osts_size > 0) \
                cfs_foreach_bit((__dev)->lod_ost_bitmap, (index))
@@ -446,6 +459,8 @@ int lod_procfs_init(struct lod_device *lod);
 void lod_procfs_fini(struct lod_device *lod);
 
 /* lod_object.c */
+int lod_load_lmv_shards(const struct lu_env *env, struct lod_object *lo,
+                       struct lu_buf *buf, bool resize);
 int lod_object_set_pool(struct lod_object *o, char *pool);
 int lod_declare_striped_object(const struct lu_env *env, struct dt_object *dt,
                               struct lu_attr *attr,