Commit 0bc6f19e authored by wang di's avatar wang di Committed by Greg Kroah-Hartman

staging: lustre: lmv: remove lmv_get_easize

Completely replace lmv_get_easize with lmv_mds_md_size.
With this change we can delete lmv_get_easize.
Signed-off-by: default avatarwang di <di.wang@intel.com>
Reviewed-on: http://review.whamcloud.com/7043
Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3531Reviewed-by: default avatarJohn L. Hammond <john.hammond@intel.com>
Reviewed-by: default avatarJinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: default avatarAndreas Dilger <andreas.dilger@intel.com>
Reviewed-by: default avatarOleg Drokin <oleg.drokin@intel.com>
Signed-off-by: default avatarJames Simmons <jsimmons@infradead.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent fad3a392
...@@ -55,13 +55,6 @@ int __lmv_fid_alloc(struct lmv_obd *lmv, struct lu_fid *fid, u32 mds); ...@@ -55,13 +55,6 @@ int __lmv_fid_alloc(struct lmv_obd *lmv, struct lu_fid *fid, u32 mds);
int lmv_fid_alloc(struct obd_export *exp, struct lu_fid *fid, int lmv_fid_alloc(struct obd_export *exp, struct lu_fid *fid,
struct md_op_data *op_data); struct md_op_data *op_data);
static inline int lmv_get_easize(struct lmv_obd *lmv)
{
return sizeof(struct lmv_stripe_md) +
lmv->desc.ld_tgt_count *
sizeof(struct lu_fid);
}
static inline struct lmv_tgt_desc * static inline struct lmv_tgt_desc *
lmv_get_target(struct lmv_obd *lmv, u32 mds) lmv_get_target(struct lmv_obd *lmv, u32 mds)
{ {
......
...@@ -558,7 +558,7 @@ int lmv_check_connect(struct obd_device *obd) ...@@ -558,7 +558,7 @@ int lmv_check_connect(struct obd_device *obd)
lmv_set_timeouts(obd); lmv_set_timeouts(obd);
class_export_put(lmv->exp); class_export_put(lmv->exp);
lmv->connected = 1; lmv->connected = 1;
easize = lmv_get_easize(lmv); easize = lmv_mds_md_size(lmv->desc.ld_tgt_count, LMV_MAGIC);
lmv_init_ea_size(obd->obd_self_export, easize, 0, 0, 0); lmv_init_ea_size(obd->obd_self_export, easize, 0, 0, 0);
mutex_unlock(&lmv->lmv_init_mutex); mutex_unlock(&lmv->lmv_init_mutex);
return 0; return 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment