X-Git-Url: https://git.whamcloud.com/?a=blobdiff_plain;f=lustre%2Flov%2Flov_cl_internal.h;h=b8114514714deff4ffd1839c1b6dd171a51dbeae;hb=8d6d2914cf85be0508805cd5195163e1959652f4;hp=b28ff3569164700df8c8aa39fd766a0aec80bf76;hpb=b4a959eb61bc7e6a64261c704f3f3f5e220c2f02;p=fs%2Flustre-release.git diff --git a/lustre/lov/lov_cl_internal.h b/lustre/lov/lov_cl_internal.h index b28ff35..b811451 100644 --- a/lustre/lov/lov_cl_internal.h +++ b/lustre/lov/lov_cl_internal.h @@ -122,6 +122,7 @@ enum lov_layout_type { LLT_EMPTY, /** empty file without body (mknod + truncate) */ LLT_RELEASED, /** file with no objects (data in HSM) */ LLT_COMP, /** support composite layout */ + LLT_FOREIGN, /** foreign layout */ LLT_NR }; @@ -134,6 +135,8 @@ static inline char *llt2str(enum lov_layout_type llt) return "RELEASED"; case LLT_COMP: return "COMPOSITE"; + case LLT_FOREIGN: + return "FOREIGN"; case LLT_NR: LBUG(); } @@ -147,9 +150,10 @@ static inline char *llt2str(enum lov_layout_type llt) */ static inline __u32 lov_entry_type(struct lov_stripe_md_entry *lsme) { - if ((lov_pattern(lsme->lsme_pattern) == LOV_PATTERN_RAID0) || + if ((lov_pattern(lsme->lsme_pattern) & LOV_PATTERN_RAID0) || (lov_pattern(lsme->lsme_pattern) == LOV_PATTERN_MDT)) - return lov_pattern(lsme->lsme_pattern); + return lov_pattern(lsme->lsme_pattern & + ~LOV_PATTERN_OVERSTRIPING); return 0; } @@ -433,8 +437,6 @@ struct lov_lock { struct lov_page { struct cl_page_slice lps_cl; - /** layout_entry + stripe index, composed using lov_comp_index() */ - unsigned int lps_index; /* the layout gen when this page was created */ __u32 lps_layout_gen; }; @@ -502,7 +504,6 @@ struct lov_io_sub { * \see cl_env_get() */ __u16 sub_refcheck; - __u16 sub_reenter; }; /** @@ -623,9 +624,12 @@ int lov_page_init_empty (const struct lu_env *env, struct cl_object *obj, struct cl_page *page, pgoff_t index); int lov_page_init_composite(const struct lu_env *env, struct cl_object *obj, struct cl_page *page, pgoff_t index); +int lov_page_init_foreign(const struct lu_env *env, struct cl_object *obj, + struct cl_page *page, pgoff_t index); struct lu_object *lov_object_alloc (const struct lu_env *env, const struct lu_object_header *hdr, struct lu_device *dev); + struct lu_object *lovsub_object_alloc(const struct lu_env *env, const struct lu_object_header *hdr, struct lu_device *dev);