aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/block/drbd/drbd_bitmap.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/block/drbd/drbd_bitmap.c')
-rw-r--r--drivers/block/drbd/drbd_bitmap.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/drivers/block/drbd/drbd_bitmap.c b/drivers/block/drbd/drbd_bitmap.c
index e343817bc69e..ddd297708194 100644
--- a/drivers/block/drbd/drbd_bitmap.c
+++ b/drivers/block/drbd/drbd_bitmap.c
@@ -1191,6 +1191,22 @@ int drbd_bm_write_lazy(struct drbd_conf *mdev, unsigned upper_idx) __must_hold(l
1191} 1191}
1192 1192
1193/** 1193/**
1194 * drbd_bm_write_copy_pages() - Write the whole bitmap to its on disk location.
1195 * @mdev: DRBD device.
1196 *
1197 * Will only write pages that have changed since last IO.
1198 * In contrast to drbd_bm_write(), this will copy the bitmap pages
1199 * to temporary writeout pages. It is intended to trigger a full write-out
1200 * while still allowing the bitmap to change, for example if a resync or online
1201 * verify is aborted due to a failed peer disk, while local IO continues, or
1202 * pending resync acks are still being processed.
1203 */
1204int drbd_bm_write_copy_pages(struct drbd_conf *mdev) __must_hold(local)
1205{
1206 return bm_rw(mdev, WRITE, BM_AIO_COPY_PAGES, 0);
1207}
1208
1209/**
1194 * drbd_bm_write_hinted() - Write bitmap pages with "hint" marks, if they have changed. 1210 * drbd_bm_write_hinted() - Write bitmap pages with "hint" marks, if they have changed.
1195 * @mdev: DRBD device. 1211 * @mdev: DRBD device.
1196 */ 1212 */