llog_cb_t cb, void *data, int startcat, int startidx)
{
return llog_cat_process_or_fork(env, cat_llh, cb, data, startcat,
- startidx, 0);
+ startidx, false);
}
EXPORT_SYMBOL(llog_cat_process);
rc = llog_cat_id2handle(env, cathandle, &loghandle, &lir->lid_id);
if (rc) {
- CERROR("%s: cannot find handle for llog "LPX64"\n",
+ CERROR("%s: cannot find handle for llog "LPX64"\n: %d",
loghandle->lgh_ctxt->loc_obd->obd_name,
- lir->lid_id.lgl_oid);
- if (rc == -ENOENT) {
+ lir->lid_id.lgl_oid, rc);
+ if (rc == -ENOENT || rc == -ESTALE) {
index = rec->lrh_index;
goto cat_cleanup;
}
RETURN(rc);
}
+EXPORT_SYMBOL(cat_cancel_cb);
/* helper to initialize catalog llog and process it to cancel */
int llog_cat_init_and_process(const struct lu_env *env,
RETURN(rc);
rc = llog_process(env, llh, cat_cancel_cb, NULL, NULL);
- RETURN(rc);
+ if (rc)
+ CERROR("%s: llog_process() with cat_cancel_cb failed: rc = "
+ "%d\n", llh->lgh_ctxt->loc_obd->obd_name, rc);
+ RETURN(0);
}
EXPORT_SYMBOL(llog_cat_init_and_process);