aboutsummaryrefslogtreecommitdiffstats
path: root/fs/dlm/lock.c
diff options
context:
space:
mode:
authorAlexander Aring <aahringo@redhat.com>2022-05-02 11:14:08 -0400
committerDavid Teigland <teigland@redhat.com>2022-05-02 11:22:15 -0500
commit0ccc106052715617015277b596bd1a591bbe4416 (patch)
tree843a8fff61428572744ae666047aed438d32aa95 /fs/dlm/lock.c
parent1689c169134f4b5a39156122d799b7dca76d8ddb (diff)
downloadlinux-0ccc106052715617015277b596bd1a591bbe4416.tar.gz
dlm: remove unnecessary error assign
This patch removes unnecessary error assigns to 0 at places we know that error is zero because it was checked on non-zero before. Signed-off-by: Alexander Aring <aahringo@redhat.com> Signed-off-by: David Teigland <teigland@redhat.com>
Diffstat (limited to 'fs/dlm/lock.c')
-rw-r--r--fs/dlm/lock.c3
1 files changed, 0 insertions, 3 deletions
diff --git a/fs/dlm/lock.c b/fs/dlm/lock.c
index d19cfa03c9bbb..97ca728dc1941 100644
--- a/fs/dlm/lock.c
+++ b/fs/dlm/lock.c
@@ -602,7 +602,6 @@ static int find_rsb_dir(struct dlm_ls *ls, char *name, int len,
*/
kref_get(&r->res_ref);
- error = 0;
goto out_unlock;
@@ -1091,7 +1090,6 @@ int dlm_master_lookup(struct dlm_ls *ls, int from_nodeid, char *name, int len,
if (result)
*result = DLM_LU_ADD;
*r_nodeid = from_nodeid;
- error = 0;
out_unlock:
spin_unlock(&ls->ls_rsbtbl[b].lock);
return error;
@@ -5747,7 +5745,6 @@ int dlm_recover_master_copy(struct dlm_ls *ls, struct dlm_rcom *rc)
attach_lkb(r, lkb);
add_lkb(r, lkb, rl->rl_status);
- error = 0;
ls->ls_recover_locks_in++;
if (!list_empty(&r->res_waitqueue) || !list_empty(&r->res_convertqueue))