Skip to content
Commit e598a72f authored by Balbir Singh's avatar Balbir Singh Committed by Jens Axboe
Browse files

block/genhd: Notify udev about capacity change



Allow block/genhd to notify user space (via udev) about disk size changes
using a new helper set_capacity_revalidate_and_notify(), which is a wrapper
on top of set_capacity(). set_capacity_revalidate_and_notify() will only
notify via udev if the current capacity or the target capacity is not zero
and iff the capacity changes.

Suggested-by: default avatarChristoph Hellwig <hch@lst.de>
Signed-off-by: default avatarSomeswarudu Sangaraju <ssomesh@amazon.com>
Signed-off-by: default avatarBalbir Singh <sblbir@amazon.com>
Reviewed-by: default avatarBob Liu <bob.liu@oracle.com>
Reviewed-by: default avatarChristoph Hellwig <hch@lst.de>
Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
parent de6a78b6
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment