summaryrefslogtreecommitdiff
path: root/drivers/md/raid1.c
diff options
context:
space:
mode:
authorYu Kuai <yukuai3@huawei.com>2025-07-07 09:27:04 +0800
committerYu Kuai <yukuai3@huawei.com>2025-09-06 17:11:54 +0800
commitbb74b093c33cf20876e23ad8aa0d206b537ccb69 (patch)
treedaea36e9ef834c05231cef937f3e896843b53f56 /drivers/md/raid1.c
parent5ae58d1500e3fc16df3267fad810955c949afdb2 (diff)
md/md-bitmap: handle the case bitmap is not enabled before end_sync()
This case can be handled without knowing internal implementation. Prepare to introduce CONFIG_MD_BITMAP. Link: https://lore.kernel.org/linux-raid/20250707012711.376844-9-yukuai1@huaweicloud.com Signed-off-by: Yu Kuai <yukuai3@huawei.com> Reviewed-by: Xiao Ni <xni@redhat.com>
Diffstat (limited to 'drivers/md/raid1.c')
-rw-r--r--drivers/md/raid1.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/md/raid1.c b/drivers/md/raid1.c
index 1485c3ffe577..0864da7d9adc 100644
--- a/drivers/md/raid1.c
+++ b/drivers/md/raid1.c
@@ -2057,7 +2057,7 @@ static void abort_sync_write(struct mddev *mddev, struct r1bio *r1_bio)
/* make sure these bits don't get cleared. */
do {
- mddev->bitmap_ops->end_sync(mddev, s, &sync_blocks);
+ md_bitmap_end_sync(mddev, s, &sync_blocks);
s += sync_blocks;
sectors_to_go -= sync_blocks;
} while (sectors_to_go > 0);
@@ -2804,8 +2804,8 @@ static sector_t raid1_sync_request(struct mddev *mddev, sector_t sector_nr,
* We can find the current addess in mddev->curr_resync
*/
if (mddev->curr_resync < max_sector) /* aborted */
- mddev->bitmap_ops->end_sync(mddev, mddev->curr_resync,
- &sync_blocks);
+ md_bitmap_end_sync(mddev, mddev->curr_resync,
+ &sync_blocks);
else /* completed sync */
conf->fullsync = 0;