[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <tencent_8AD1777367243C273694968636624A487409@qq.com>
Date: Sat, 26 Oct 2024 12:50:31 +0800
From: Edward Adam Davis <eadavis@...com>
To: syzbot+820dc3b465c69f766a57@...kaller.appspotmail.com
Cc: linux-kernel@...r.kernel.org,
syzkaller-bugs@...glegroups.com
Subject: Re: [syzbot] [bcachefs?] INFO: task hung in bch2_journal_reclaim_thread (2)
avoid race conditions when journal's reclaim and flush acquire reclaim_lock
#syz test
diff --git a/fs/bcachefs/journal_reclaim.c b/fs/bcachefs/journal_reclaim.c
index ace291f175dd..58a745c72aac 100644
--- a/fs/bcachefs/journal_reclaim.c
+++ b/fs/bcachefs/journal_reclaim.c
@@ -731,7 +731,7 @@ static int bch2_journal_reclaim_thread(void *arg)
j->last_flushed = jiffies;
- while (!ret && !kthread_should_stop()) {
+ while (!j->flush_in_progress && !ret && !kthread_should_stop()) {
bool kicked = j->reclaim_kicked;
j->reclaim_kicked = false;
Powered by blists - more mailing lists