diff options
author | Guoqing Jiang <guoqing.jiang@cloud.ionos.com> | 2019-12-23 12:48:53 +0300 |
---|---|---|
committer | Song Liu <songliubraving@fb.com> | 2020-01-13 22:44:09 +0300 |
commit | 404659cf1e2570dad3cd117fa3bd71f06ecfd142 (patch) | |
tree | f6ebfebe6852702b15a1e00a4d70eec5aa37ec41 /drivers/md/md-bitmap.c | |
parent | d2c9ad41249ac862d3a3a4d5d56e6b1cd79d8a17 (diff) | |
download | linux-404659cf1e2570dad3cd117fa3bd71f06ecfd142.tar.xz |
md: rename wb stuffs
Previously, wb_info_pool and wb_list stuffs are introduced
to address potential data inconsistence issue for write
behind device.
Now rename them to serial related name, since the same
mechanism will be used to address reorder overlap write
issue for raid1.
Signed-off-by: Guoqing Jiang <guoqing.jiang@cloud.ionos.com>
Signed-off-by: Song Liu <songliubraving@fb.com>
Diffstat (limited to 'drivers/md/md-bitmap.c')
-rw-r--r-- | drivers/md/md-bitmap.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/drivers/md/md-bitmap.c b/drivers/md/md-bitmap.c index 9860062bdc1e..212e75dfebb7 100644 --- a/drivers/md/md-bitmap.c +++ b/drivers/md/md-bitmap.c @@ -1789,8 +1789,8 @@ void md_bitmap_destroy(struct mddev *mddev) return; md_bitmap_wait_behind_writes(mddev); - mempool_destroy(mddev->wb_info_pool); - mddev->wb_info_pool = NULL; + mempool_destroy(mddev->serial_info_pool); + mddev->serial_info_pool = NULL; mutex_lock(&mddev->bitmap_info.mutex); spin_lock(&mddev->lock); @@ -1907,7 +1907,7 @@ int md_bitmap_load(struct mddev *mddev) goto out; rdev_for_each(rdev, mddev) - mddev_create_wb_pool(mddev, rdev, true); + mddev_create_serial_pool(mddev, rdev, true); if (mddev_is_clustered(mddev)) md_cluster_ops->load_bitmaps(mddev, mddev->bitmap_info.nodes); @@ -2474,16 +2474,16 @@ backlog_store(struct mddev *mddev, const char *buf, size_t len) if (backlog > COUNTER_MAX) return -EINVAL; mddev->bitmap_info.max_write_behind = backlog; - if (!backlog && mddev->wb_info_pool) { - /* wb_info_pool is not needed if backlog is zero */ - mempool_destroy(mddev->wb_info_pool); - mddev->wb_info_pool = NULL; - } else if (backlog && !mddev->wb_info_pool) { - /* wb_info_pool is needed since backlog is not zero */ + if (!backlog && mddev->serial_info_pool) { + /* serial_info_pool is not needed if backlog is zero */ + mempool_destroy(mddev->serial_info_pool); + mddev->serial_info_pool = NULL; + } else if (backlog && !mddev->serial_info_pool) { + /* serial_info_pool is needed since backlog is not zero */ struct md_rdev *rdev; rdev_for_each(rdev, mddev) - mddev_create_wb_pool(mddev, rdev, false); + mddev_create_serial_pool(mddev, rdev, false); } if (old_mwb != backlog) md_bitmap_update_sb(mddev->bitmap); |