[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250721171557.34587-11-yukuai@kernel.org>
Date: Tue, 22 Jul 2025 01:15:56 +0800
From: Yu Kuai <yukuai@...nel.org>
To: corbet@....net,
agk@...hat.co,
snitzer@...nel.org,
mpatocka@...hat.com,
hch@....de,
song@...nel.org,
hare@...e.de
Cc: linux-doc@...r.kernel.org,
linux-kernel@...r.kernel.org,
dm-devel@...ts.linux.dev,
linux-raid@...r.kernel.org,
yukuai3@...wei.com,
yangerkun@...wei.com,
yi.zhang@...wei.com,
johnny.chenyi@...wei.com
Subject: [PATCH v4 10/11] md/md-bitmap: make method bitmap_ops->daemon_work optional
From: Yu Kuai <yukuai3@...wei.com>
daemon_work() will be called by daemon thread, on the one hand, daemon
thread doesn't have strict wake-up time; on the other hand, too much
work are put to daemon thread, like handle sync IO, handle failed
or specail normal IO, handle recovery, and so on. Hence daemon thread
may be too busy to clear dirty bits in time.
Make bitmap_ops->daemon_work() optional and following patches will use
separate async work to clear dirty bits for the new bitmap.
Signed-off-by: Yu Kuai <yukuai3@...wei.com>
Reviewed-by: Christoph Hellwig <hch@....de>
Reviewed-by: Hannes Reinecke <hare@...e.de>
---
drivers/md/md.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/md/md.c b/drivers/md/md.c
index ab4799e2a0bd..fcb0dfcf1e84 100644
--- a/drivers/md/md.c
+++ b/drivers/md/md.c
@@ -9887,7 +9887,7 @@ static void unregister_sync_thread(struct mddev *mddev)
*/
void md_check_recovery(struct mddev *mddev)
{
- if (md_bitmap_enabled(mddev, false))
+ if (md_bitmap_enabled(mddev, false) && mddev->bitmap_ops->daemon_work)
mddev->bitmap_ops->daemon_work(mddev);
if (signal_pending(current)) {
--
2.43.0
Powered by blists - more mailing lists