Skip to content

Commit 3a88edc

Browse files
author
Andreas Gruenbacher
committed
gfs2: Withdraw immediately in gfs2_trans_add_meta
We can now withdraw while the log is locked. Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com>
1 parent bbbf152 commit 3a88edc

1 file changed

Lines changed: 1 addition & 4 deletions

File tree

fs/gfs2/trans.c

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -255,7 +255,6 @@ void gfs2_trans_add_meta(struct gfs2_glock *gl, struct buffer_head *bh)
255255
struct gfs2_bufdata *bd;
256256
struct gfs2_meta_header *mh;
257257
struct gfs2_trans *tr = current->journal_info;
258-
bool withdraw = false;
259258

260259
lock_buffer(bh);
261260
if (buffer_pinned(bh)) {
@@ -296,7 +295,7 @@ void gfs2_trans_add_meta(struct gfs2_glock *gl, struct buffer_head *bh)
296295
}
297296
if (unlikely(sb->s_writers.frozen == SB_FREEZE_COMPLETE)) {
298297
fs_info(sdp, "GFS2:adding buf while frozen\n");
299-
withdraw = true;
298+
gfs2_withdraw(sdp);
300299
goto out_unlock;
301300
}
302301
gfs2_pin(sdp, bd->bd_bh);
@@ -306,8 +305,6 @@ void gfs2_trans_add_meta(struct gfs2_glock *gl, struct buffer_head *bh)
306305
tr->tr_num_buf_new++;
307306
out_unlock:
308307
gfs2_log_unlock(sdp);
309-
if (withdraw)
310-
gfs2_assert_withdraw(sdp, 0);
311308
out:
312309
unlock_buffer(bh);
313310
}

0 commit comments

Comments
 (0)