switch (lustre_msg_get_opc(msg)) {
case MDS_CONNECT:
case MDS_DISCONNECT:
- case MDS_SET_INFO:
case OBD_PING:
case SEC_CTX_INIT:
case SEC_CTX_INIT_CONT:
case MDS_SYNC:
case MDS_GETXATTR:
case MDS_SETXATTR:
+ case MDS_SET_INFO:
case MDS_GET_INFO:
case MDS_QUOTACHECK:
case MDS_QUOTACTL:
obd = class_name2obd(dev);
LASSERT(obd != NULL);
- cfs_spin_lock_init(&m->mdt_transno_lock);
-
m->mdt_max_mdsize = MAX_MD_SIZE;
m->mdt_max_cookiesize = sizeof(struct llog_cookie);
m->mdt_som_conf = 0;
m->mdt_nosquash_strlen = 0;
cfs_init_rwsem(&m->mdt_squash_sem);
- cfs_spin_lock_init(&m->mdt_client_bitmap_lock);
-
OBD_ALLOC_PTR(mite);
if (mite == NULL)
GOTO(err_lmi, rc = -ENOMEM);
memcpy(lcd->lcd_uuid, cluuid, sizeof lcd->lcd_uuid);
lexp->exp_mdt_data.med_lcd = lcd;
rc = mdt_client_new(env, mdt);
- if (rc != 0) {
- OBD_FREE_PTR(lcd);
- lexp->exp_mdt_data.med_lcd = NULL;
- } else {
+ if (rc == 0)
mdt_export_stats_init(obd, lexp, localdata);
- }
- } else
+ } else {
rc = -ENOMEM;
+ }
}
out:
if (obd_uuid_equals(&exp->exp_client_uuid, &exp->exp_obd->obd_uuid))
RETURN(0);
+ lut_client_free(exp);
RETURN(rc);
}
*/
int mdt_hsm_copytool_send(struct obd_export *exp)
{
- struct lnl_hdr *lh;
+ struct kuc_hdr *lh;
struct hsm_action_list *hal;
struct hsm_action_item *hai;
int rc, len;
if (lh == NULL)
RETURN(-ENOMEM);
- lh->lnl_magic = LNL_MAGIC;
- lh->lnl_transport = LNL_TRANSPORT_HSM;
- lh->lnl_msgtype = HMT_ACTION_LIST;
- lh->lnl_msglen = len;
+ lh->kuc_magic = KUC_MAGIC;
+ lh->kuc_transport = KUC_TRANSPORT_HSM;
+ lh->kuc_msgtype = HMT_ACTION_LIST;
+ lh->kuc_msglen = len;
hal = (struct hsm_action_list *)(lh + 1);
hal->hal_version = HAL_VERSION;
/* Uses the ldlm reverse import; this rpc will be seen by
the ldlm_callback_handler */
- rc = target_set_info_rpc(exp->exp_imp_reverse, LDLM_SET_INFO,
- sizeof(KEY_HSM_COPYTOOL_SEND),
- KEY_HSM_COPYTOOL_SEND,
- len, lh, NULL);
+ rc = do_set_info_async(exp->exp_imp_reverse,
+ LDLM_SET_INFO, LUSTRE_OBD_VERSION,
+ sizeof(KEY_HSM_COPYTOOL_SEND),
+ KEY_HSM_COPYTOOL_SEND,
+ len, lh, NULL);
OBD_FREE(lh, len);