diff options
author | Andreas Gruenbacher <agruenba@redhat.com> | 2024-08-22 19:33:51 +0200 |
---|---|---|
committer | Andreas Gruenbacher <agruenba@redhat.com> | 2024-11-05 12:39:28 +0100 |
commit | b4100457d02d90149129ba2230130954a03fdf0b (patch) | |
tree | 74494bea8871e0dce03d79b58a4ce6462937a5bb /fs/gfs2/glock.c | |
parent | a94dafe87d5fdded799fc25b82b123fb93959421 (diff) |
gfs2: Minor delete_work_func cleanup
Move those definitions into the the scope in which they are used.
Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com>
Diffstat (limited to 'fs/gfs2/glock.c')
-rw-r--r-- | fs/gfs2/glock.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/fs/gfs2/glock.c b/fs/gfs2/glock.c index c095ff2efe1d..9ec305b8d4d4 100644 --- a/fs/gfs2/glock.c +++ b/fs/gfs2/glock.c @@ -1028,8 +1028,6 @@ static void delete_work_func(struct work_struct *work) struct delayed_work *dwork = to_delayed_work(work); struct gfs2_glock *gl = container_of(dwork, struct gfs2_glock, gl_delete); struct gfs2_sbd *sdp = gl->gl_name.ln_sbd; - struct inode *inode; - u64 no_addr = gl->gl_name.ln_number; if (test_and_clear_bit(GLF_TRY_TO_EVICT, &gl->gl_flags)) { /* @@ -1059,6 +1057,9 @@ static void delete_work_func(struct work_struct *work) } if (test_and_clear_bit(GLF_VERIFY_DELETE, &gl->gl_flags)) { + u64 no_addr = gl->gl_name.ln_number; + struct inode *inode; + inode = gfs2_lookup_by_inum(sdp, no_addr, gl->gl_no_formal_ino, GFS2_BLKST_UNLINKED); if (IS_ERR(inode)) { |