Whamcloud - gitweb
LU-2675 osc: remove obsolete llog handling 74/11774/4
authorJohn L. Hammond <john.hammond@intel.com>
Fri, 5 Sep 2014 15:48:05 +0000 (10:48 -0500)
committerAndreas Dilger <andreas.dilger@intel.com>
Sat, 25 Oct 2014 00:17:54 +0000 (00:17 +0000)
In osc_disconnect() LLOG_SIZE_REPL_CTXT was never setup so remove the
code to sync and put the content. In osc_precleanup() remove the no-op
call to obd_llog_finish().

Signed-off-by: John L. Hammond <john.hammond@intel.com>
Change-Id: I41ce7effbd017862aa216d4a09c15694ec11d597
Reviewed-on: http://review.whamcloud.com/11774
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
lustre/osc/osc_request.c

index 06c458c..e1b4b49 100644 (file)
@@ -38,7 +38,6 @@
 
 #include <libcfs/libcfs.h>
 
-
 #include <lustre_dlm.h>
 #include <lustre_net.h>
 #include <lustre/lustre_user.h>
 #include <lustre_ha.h>
 #include <lprocfs_status.h>
 #include <lustre_ioctl.h>
-#include <lustre_log.h>
 #include <lustre_debug.h>
 #include <lustre_param.h>
 #include <lustre_fid.h>
+#include <obd_class.h>
 #include "osc_internal.h"
 #include "osc_cl_internal.h"
 
@@ -2935,22 +2934,8 @@ static int osc_reconnect(const struct lu_env *env,
 
 static int osc_disconnect(struct obd_export *exp)
 {
-        struct obd_device *obd = class_exp2obd(exp);
-        struct llog_ctxt  *ctxt;
-        int rc;
-
-        ctxt = llog_get_context(obd, LLOG_SIZE_REPL_CTXT);
-        if (ctxt) {
-                if (obd->u.cli.cl_conn_count == 1) {
-                        /* Flush any remaining cancel messages out to the
-                         * target */
-                       llog_sync(ctxt, exp, 0);
-                }
-                llog_ctxt_put(ctxt);
-        } else {
-                CDEBUG(D_HA, "No LLOG_SIZE_REPL_CTXT found in obd %p\n",
-                       obd);
-        }
+       struct obd_device *obd = class_exp2obd(exp);
+       int rc;
 
         rc = client_disconnect_export(exp);
         /**
@@ -3211,9 +3196,6 @@ static int osc_precleanup(struct obd_device *obd, enum obd_cleanup_stage stage)
                 obd_cleanup_client_import(obd);
                 ptlrpc_lprocfs_unregister_obd(obd);
                 lprocfs_obd_cleanup(obd);
-                rc = obd_llog_finish(obd, 0);
-                if (rc != 0)
-                        CERROR("failed to cleanup llogging subsystems\n");
                 break;
                 }
         }