diff options
author | Christoph Hellwig <hch@lst.de> | 2020-09-25 19:06:17 +0300 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2020-10-05 19:38:33 +0300 |
commit | 155bd9d1abd60497f3e84ef3251b40209f7f7900 (patch) | |
tree | 38300a8cf8b17645357c9905e4e6d78927a77f56 /drivers/block/drbd/drbd_actlog.c | |
parent | 76cffccd606acffde1b91e8b029b39b5fd1a3117 (diff) | |
download | linux-155bd9d1abd60497f3e84ef3251b40209f7f7900.tar.xz |
drbd: remove ->this_bdev
DRBD keeps a block device open just to get and set the capacity from
it. Switch to primarily using the disk capacity as intended by the
block layer, and sync it to the bdev using revalidate_disk_size.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'drivers/block/drbd/drbd_actlog.c')
-rw-r--r-- | drivers/block/drbd/drbd_actlog.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/block/drbd/drbd_actlog.c b/drivers/block/drbd/drbd_actlog.c index b41897dceb2b..7227fc7ab8ed 100644 --- a/drivers/block/drbd/drbd_actlog.c +++ b/drivers/block/drbd/drbd_actlog.c @@ -865,7 +865,7 @@ int __drbd_change_sync(struct drbd_device *device, sector_t sector, int size, if (!get_ldev(device)) return 0; /* no disk, no metadata, no bitmap to manipulate bits in */ - nr_sectors = drbd_get_capacity(device->this_bdev); + nr_sectors = get_capacity(device->vdisk); esector = sector + (size >> 9) - 1; if (!expect(sector < nr_sectors)) |