}
struct lfsck_thread_args *lfsck_thread_args_init(struct lfsck_instance *lfsck,
- struct lfsck_component *com)
+ struct lfsck_component *com,
+ struct lfsck_start_param *lsp)
{
struct lfsck_thread_args *lta;
int rc;
if (com != NULL)
lta->lta_com = lfsck_component_get(com);
+ lta->lta_lsp = lsp;
+
return lta;
}
return rc1 != 0 ? rc1 : rc;
}
-int lfsck_prep(const struct lu_env *env, struct lfsck_instance *lfsck)
+int lfsck_prep(const struct lu_env *env, struct lfsck_instance *lfsck,
+ struct lfsck_start_param *lsp)
{
struct dt_object *obj = NULL;
struct lfsck_component *com;
if (lfsck->li_bookmark_ram.lb_param & LPF_DRYRUN)
com->lc_journal = 0;
- rc = com->lc_ops->lfsck_prep(env, com);
+ rc = com->lc_ops->lfsck_prep(env, com, lsp);
if (rc != 0)
GOTO(out, rc);
lfsck->li_args_oit = (flags << DT_OTABLE_IT_FLAGS_SHIFT) | valid;
thread_set_flags(thread, 0);
- lta = lfsck_thread_args_init(lfsck, NULL);
+ lta = lfsck_thread_args_init(lfsck, NULL, lsp);
if (IS_ERR(lta))
GOTO(out, rc = PTR_ERR(lta));
EXPORT_SYMBOL(lfsck_query);
int lfsck_register(const struct lu_env *env, struct dt_device *key,
- struct dt_device *next, lfsck_out_notify notify,
- void *notify_data, bool master)
+ struct dt_device *next, struct obd_device *obd,
+ lfsck_out_notify notify, void *notify_data, bool master)
{
struct lfsck_instance *lfsck;
struct dt_object *root = NULL;
lfsck->li_out_notify_data = notify_data;
lfsck->li_next = next;
lfsck->li_bottom = key;
+ lfsck->li_obd = obd;
rc = lfsck_tgt_descs_init(&lfsck->li_ost_descs);
if (rc != 0)