]> git.baikalelectronics.ru Git - kernel.git/commit
nbd: use set_capacity_and_notify
authorChristoph Hellwig <hch@lst.de>
Mon, 16 Nov 2020 14:57:01 +0000 (15:57 +0100)
committerJens Axboe <axboe@kernel.dk>
Mon, 16 Nov 2020 15:34:14 +0000 (08:34 -0700)
commit139dee3af60b5662a74b88c6af2e792f24a1d61b
tree580d924fb6bc06d1dd94d7fd6cc3d900bc7cd886
parentaa19d8a39dda2741c64f5155015ffc84d0b7e2d9
nbd: use set_capacity_and_notify

Use set_capacity_and_notify to update the disk and block device sizes and
send a RESIZE uevent to userspace.  Note that blktests relies on uevents
being sent also for updates that did not change the device size, so the
explicit kobject_uevent remains for that case.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Josef Bacik <josef@toxicpanda.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/block/nbd.c