From 66ee3eae7a29e5a71d7f0342646661e02e877bb3 Mon Sep 17 00:00:00 2001 From: yury Date: Tue, 29 Aug 2006 13:41:11 +0000 Subject: [PATCH] - fixed names of client flds in lmv and cmm; - using dht hash for fld (it still will call rrb). This is needed to not do changes in calling code later, when dht is ready; - fixed stupid typo in seq_dht_scan() which caused nasty recursion. --- lustre/cmm/cmm_device.c | 9 +++++---- lustre/fld/fld_request.c | 2 +- lustre/lmv/lmv_obd.c | 4 ++-- 3 files changed, 8 insertions(+), 7 deletions(-) diff --git a/lustre/cmm/cmm_device.c b/lustre/cmm/cmm_device.c index fabc806..f8e346d 100644 --- a/lustre/cmm/cmm_device.c +++ b/lustre/cmm/cmm_device.c @@ -189,9 +189,9 @@ static void cmm_device_shutdown(const struct lu_context *ctx, static int cmm_device_mount(const struct lu_context *ctx, struct cmm_device *m, struct lustre_cfg *cfg) { - struct lu_site *ls; const char *index = lustre_cfg_string(cfg, 2); - char *p; + struct lu_site *ls; + char *p, *name_str; int rc; LASSERT(index); @@ -207,8 +207,9 @@ static int cmm_device_mount(const struct lu_context *ctx, if (!ls->ls_client_fld) RETURN(-ENOMEM); - rc = fld_client_init(ls->ls_client_fld, "CMM_UUID", - LUSTRE_CLI_FLD_HASH_RRB); + name_str = lustre_cfg_string(cfg, 0); + rc = fld_client_init(ls->ls_client_fld, name_str, + LUSTRE_CLI_FLD_HASH_DHT); if (rc) { CERROR("can't init FLD, err %d\n", rc); } diff --git a/lustre/fld/fld_request.c b/lustre/fld/fld_request.c index 3027f14..82bf843 100644 --- a/lustre/fld/fld_request.c +++ b/lustre/fld/fld_request.c @@ -90,7 +90,7 @@ static struct fld_target * fld_dht_scan(struct lu_client_fld *fld, seqno_t seq) { /* XXX: here should be DHT scan code */ - return fld_dht_scan(fld, seq); + return fld_rrb_scan(fld, seq); } struct lu_fld_hash fld_hash[3] = { diff --git a/lustre/lmv/lmv_obd.c b/lustre/lmv/lmv_obd.c index 6531e7d..62bc94c 100644 --- a/lustre/lmv/lmv_obd.c +++ b/lustre/lmv/lmv_obd.c @@ -859,8 +859,8 @@ static int lmv_setup(struct obd_device *obd, struct lustre_cfg *lcfg) } } #endif - rc = fld_client_init(&lmv->lmv_fld, - "LMV_UUID", LUSTRE_CLI_FLD_HASH_RRB); + rc = fld_client_init(&lmv->lmv_fld, obd->obd_name, + LUSTRE_CLI_FLD_HASH_DHT); if (rc) { CERROR("can't init FLD, err %d\n", rc); -- 1.8.3.1