From: Bobi Jam Date: Thu, 28 Apr 2016 16:53:09 +0000 (+0800) Subject: LU-6696 llog: improve error handling X-Git-Tag: 2.8.56~66 X-Git-Url: https://git.whamcloud.com/gitweb?a=commitdiff_plain;h=53d2f414d75ac1302b53017376ca2f1fda1f3d17;p=fs%2Flustre-release.git LU-6696 llog: improve error handling Handle error return value of llog_cat_process() in osp_sync_thread(). Signed-off-by: Bobi Jam Change-Id: I9b8e00dcc90e8d7d55648ce1b3a18af0a74c542b Reviewed-on: http://review.whamcloud.com/19856 Reviewed-by: Andreas Dilger Tested-by: Jenkins Tested-by: Maloo Reviewed-by: Mike Pershin --- diff --git a/lustre/osp/osp_sync.c b/lustre/osp/osp_sync.c index 2fcc9e5..c44ab5b 100644 --- a/lustre/osp/osp_sync.c +++ b/lustre/osp/osp_sync.c @@ -1195,6 +1195,11 @@ static int osp_sync_thread(void *_arg) } rc = llog_cat_process(&env, llh, osp_sync_process_queues, d, 0, 0); + if (rc < 0) { + CERROR("%s: llog process with osp_sync_process_queues " + "failed: %d\n", d->opd_obd->obd_name, rc); + GOTO(close, rc); + } LASSERTF(rc == 0 || rc == LLOG_PROC_BREAK, "%u changes, %u in progress, %u in flight: %d\n", atomic_read(&d->opd_syn_changes), @@ -1227,6 +1232,7 @@ static int osp_sync_thread(void *_arg) } +close: llog_cat_close(&env, llh); rc = llog_cleanup(&env, ctxt); if (rc)