projects
/
linux-block.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8221894
)
gfs2: Lock imbalance on error path in gfs2_recover_one
author
Andreas Gruenbacher
<agruenba@redhat.com>
Fri, 5 Feb 2021 17:11:28 +0000
(18:11 +0100)
committer
Andreas Gruenbacher
<agruenba@redhat.com>
Fri, 5 Feb 2021 17:18:57 +0000
(18:18 +0100)
In gfs2_recover_one, fix a sd_log_flush_lock imbalance when a recovery
pass fails.
Fixes:
c9ebc4b73799
("gfs2: allow journal replay to hold sd_log_flush_lock")
Cc: stable@vger.kernel.org # v5.7+
Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com>
fs/gfs2/recovery.c
patch
|
blob
|
blame
|
history
diff --git
a/fs/gfs2/recovery.c
b/fs/gfs2/recovery.c
index cff8b9a6612cbe7e74e7d50b05ee72105ae34882..282173774005539ad5dbbda14d95b69bb9a4eeb9 100644
(file)
--- a/
fs/gfs2/recovery.c
+++ b/
fs/gfs2/recovery.c
@@
-512,8
+512,10
@@
void gfs2_recover_func(struct work_struct *work)
error = foreach_descriptor(jd, head.lh_tail,
head.lh_blkno, pass);
lops_after_scan(jd, error, pass);
- if (error)
+ if (error) {
+ up_read(&sdp->sd_log_flush_lock);
goto fail_gunlock_thaw;
+ }
}
recover_local_statfs(jd, &head);