Skip to content

Commit b410045

Browse files
author
Andreas Gruenbacher
committed
gfs2: Minor delete_work_func cleanup
Move those definitions into the the scope in which they are used. Signed-off-by: Andreas Gruenbacher <[email protected]>
1 parent a94dafe commit b410045

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

fs/gfs2/glock.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1028,8 +1028,6 @@ static void delete_work_func(struct work_struct *work)
10281028
struct delayed_work *dwork = to_delayed_work(work);
10291029
struct gfs2_glock *gl = container_of(dwork, struct gfs2_glock, gl_delete);
10301030
struct gfs2_sbd *sdp = gl->gl_name.ln_sbd;
1031-
struct inode *inode;
1032-
u64 no_addr = gl->gl_name.ln_number;
10331031

10341032
if (test_and_clear_bit(GLF_TRY_TO_EVICT, &gl->gl_flags)) {
10351033
/*
@@ -1059,6 +1057,9 @@ static void delete_work_func(struct work_struct *work)
10591057
}
10601058

10611059
if (test_and_clear_bit(GLF_VERIFY_DELETE, &gl->gl_flags)) {
1060+
u64 no_addr = gl->gl_name.ln_number;
1061+
struct inode *inode;
1062+
10621063
inode = gfs2_lookup_by_inum(sdp, no_addr, gl->gl_no_formal_ino,
10631064
GFS2_BLKST_UNLINKED);
10641065
if (IS_ERR(inode)) {

0 commit comments

Comments
 (0)