X-Git-Url: https://git.whamcloud.com/?p=fs%2Flustre-release.git;a=blobdiff_plain;f=lustre%2Fmdt%2Fmdt_lproc.c;h=534b268d229b0347426e0ec53bd76a32b77841b9;hp=24932d92e7268cb51723676013a1fac32c3e6439;hb=be69837105edc20cfade1f25e8f3fb5c39b2e216;hpb=4960810b94d808965cae9258fb4f7583618a75e9 diff --git a/lustre/mdt/mdt_lproc.c b/lustre/mdt/mdt_lproc.c index 24932d9..534b268 100644 --- a/lustre/mdt/mdt_lproc.c +++ b/lustre/mdt/mdt_lproc.c @@ -112,6 +112,8 @@ int mdt_procfs_init(struct mdt_device *mdt, const char *name) "clear", lprocfs_nid_stats_clear_read, lprocfs_nid_stats_clear_write, obd, NULL); rc = lprocfs_alloc_md_stats(obd, LPROC_MDT_LAST); + if (rc == 0) + mdt_stats_counter_init(obd->md_stats); RETURN(rc); } @@ -813,8 +815,8 @@ void lprocfs_mdt_init_vars(struct lprocfs_static_vars *lvars) void mdt_counter_incr(struct obd_export *exp, int opcode) { - if (exp->exp_obd && exp->exp_obd->obd_stats) - lprocfs_counter_incr(exp->exp_obd->obd_stats, opcode); + if (exp->exp_obd && exp->exp_obd->md_stats) + lprocfs_counter_incr(exp->exp_obd->md_stats, opcode); if (exp->exp_nid_stats && exp->exp_nid_stats->nid_stats != NULL) lprocfs_counter_incr(exp->exp_nid_stats->nid_stats, opcode);