From: Arshad Hussain Date: Mon, 5 Aug 2019 20:18:44 +0000 (+0530) Subject: LU-6142 ptlrpc: Fix style issues for llog_net.c X-Git-Tag: 2.12.90~103 X-Git-Url: https://git.whamcloud.com/?a=commitdiff_plain;h=refs%2Fchanges%2F23%2F35823%2F2;p=fs%2Flustre-release.git LU-6142 ptlrpc: Fix style issues for llog_net.c This patch fixes issues reported by checkpatch for file lustre/ptlrpc/llog_net.c Test-Parameters: trivial Signed-off-by: Arshad Hussain Change-Id: Ieee60565e5332a1546999e6c8edaffc833074271 Reviewed-on: https://review.whamcloud.com/35823 Tested-by: jenkins Tested-by: Maloo Reviewed-by: James Simmons Reviewed-by: Shaun Tancheff Reviewed-by: Petros Koutoupis Reviewed-by: Oleg Drokin --- diff --git a/lustre/ptlrpc/llog_net.c b/lustre/ptlrpc/llog_net.c index 9036491..2e9b6a8 100644 --- a/lustre/ptlrpc/llog_net.c +++ b/lustre/ptlrpc/llog_net.c @@ -48,20 +48,21 @@ int llog_initiator_connect(struct llog_ctxt *ctxt) { - struct obd_import *new_imp; - ENTRY; + struct obd_import *new_imp; - LASSERT(ctxt); - new_imp = ctxt->loc_obd->u.cli.cl_import; - LASSERTF(ctxt->loc_imp == NULL || ctxt->loc_imp == new_imp, - "%p - %p\n", ctxt->loc_imp, new_imp); + ENTRY; + + LASSERT(ctxt); + new_imp = ctxt->loc_obd->u.cli.cl_import; + LASSERTF(!ctxt->loc_imp || ctxt->loc_imp == new_imp, + "%p - %p\n", ctxt->loc_imp, new_imp); mutex_lock(&ctxt->loc_mutex); - if (ctxt->loc_imp != new_imp) { - if (ctxt->loc_imp) - class_import_put(ctxt->loc_imp); - ctxt->loc_imp = class_import_get(new_imp); - } + if (ctxt->loc_imp != new_imp) { + if (ctxt->loc_imp) + class_import_put(ctxt->loc_imp); + ctxt->loc_imp = class_import_get(new_imp); + } mutex_unlock(&ctxt->loc_mutex); - RETURN(0); + RETURN(0); } EXPORT_SYMBOL(llog_initiator_connect);