Whamcloud - gitweb
LU-7950 osp: Remove assigned but not used variable 24/21024/4
authorArshad Hussain <arshad.hussain@seagate.com>
Fri, 24 Jun 2016 10:15:08 +0000 (15:45 +0530)
committerOleg Drokin <oleg.drokin@intel.com>
Tue, 13 Sep 2016 20:03:41 +0000 (20:03 +0000)
This patch removes import variable which were assigned but
were not used within function
1. lwp_device_fini() under lustre/osp/lwp_dev.c
2. osp_device_fini() under lustre/osp/osp_dev.c

Signed-off-by: Arshad Hussain <arshad.hussain@seagate.com>
Change-Id: If37bc78060aaf97127802c0fcbf50bc5483977fc
Reviewed-on: http://review.whamcloud.com/21024
Tested-by: Jenkins
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
lustre/osp/lwp_dev.c
lustre/osp/osp_dev.c

index 568bbfd..b28f32c 100644 (file)
@@ -361,7 +361,6 @@ static struct lu_device *lwp_device_fini(const struct lu_env *env,
        struct lwp_device       *m = lu2lwp_dev(ludev);
        struct ptlrpc_thread    *thread = &m->lpd_notify_thread;
        struct l_wait_info       lwi = { 0 };
        struct lwp_device       *m = lu2lwp_dev(ludev);
        struct ptlrpc_thread    *thread = &m->lpd_notify_thread;
        struct l_wait_info       lwi = { 0 };
-       struct obd_import       *imp;
        int                      rc;
        ENTRY;
 
        int                      rc;
        ENTRY;
 
@@ -372,8 +371,6 @@ static struct lu_device *lwp_device_fini(const struct lu_env *env,
        if (m->lpd_exp != NULL)
                class_disconnect(m->lpd_exp);
 
        if (m->lpd_exp != NULL)
                class_disconnect(m->lpd_exp);
 
-       imp = m->lpd_obd->u.cli.cl_import;
-
        LASSERT(m->lpd_obd);
        ptlrpc_lprocfs_unregister_obd(m->lpd_obd);
        lprocfs_obd_cleanup(m->lpd_obd);
        LASSERT(m->lpd_obd);
        ptlrpc_lprocfs_unregister_obd(m->lpd_obd);
        lprocfs_obd_cleanup(m->lpd_obd);
index ed68c79..f20d8c6 100644 (file)
@@ -1323,7 +1323,6 @@ static struct lu_device *osp_device_fini(const struct lu_env *env,
                                         struct lu_device *ld)
 {
        struct osp_device *osp = lu2osp_dev(ld);
                                         struct lu_device *ld)
 {
        struct osp_device *osp = lu2osp_dev(ld);
-       struct obd_import *imp;
        int                rc;
 
        ENTRY;
        int                rc;
 
        ENTRY;
@@ -1336,8 +1335,6 @@ static struct lu_device *osp_device_fini(const struct lu_env *env,
        if (osp->opd_storage_exp)
                obd_disconnect(osp->opd_storage_exp);
 
        if (osp->opd_storage_exp)
                obd_disconnect(osp->opd_storage_exp);
 
-       imp = osp->opd_obd->u.cli.cl_import;
-
        if (osp->opd_symlink)
                lprocfs_remove(&osp->opd_symlink);
 
        if (osp->opd_symlink)
                lprocfs_remove(&osp->opd_symlink);