diff options
author | Christoph Hellwig <hch@lst.de> | 2021-03-08 08:45:48 +0100 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2021-03-29 07:02:56 -0600 |
commit | 4bae7afdd789baedbc0b82a4b9ef51501dd7d4fe (patch) | |
tree | 69bb210da35eae37113c710dd3ad46cfd0858aaa /drivers | |
parent | f8d62edfe2563fc86d12b80b07407dc095cdf0d2 (diff) | |
download | linux-stable-4bae7afdd789baedbc0b82a4b9ef51501dd7d4fe.tar.gz linux-stable-4bae7afdd789baedbc0b82a4b9ef51501dd7d4fe.tar.bz2 linux-stable-4bae7afdd789baedbc0b82a4b9ef51501dd7d4fe.zip |
paride/pd: remove ->revalidate_disk
->revalidate_disk is only called during add_disk for pd, but at that
point the driver has already set the capacity to the one returned from
Identify a little earlier, so this additional update is entirely
superflous.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Link: https://lore.kernel.org/r/20210308074550.422714-2-hch@lst.de
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/block/paride/pd.c | 11 |
1 files changed, 0 insertions, 11 deletions
diff --git a/drivers/block/paride/pd.c b/drivers/block/paride/pd.c index 897acda20ac8..828a45ffe0e7 100644 --- a/drivers/block/paride/pd.c +++ b/drivers/block/paride/pd.c @@ -859,16 +859,6 @@ static unsigned int pd_check_events(struct gendisk *p, unsigned int clearing) return r ? DISK_EVENT_MEDIA_CHANGE : 0; } -static int pd_revalidate(struct gendisk *p) -{ - struct pd_unit *disk = p->private_data; - if (pd_special_command(disk, pd_identify) == 0) - set_capacity(p, disk->capacity); - else - set_capacity(p, 0); - return 0; -} - static const struct block_device_operations pd_fops = { .owner = THIS_MODULE, .open = pd_open, @@ -877,7 +867,6 @@ static const struct block_device_operations pd_fops = { .compat_ioctl = pd_ioctl, .getgeo = pd_getgeo, .check_events = pd_check_events, - .revalidate_disk= pd_revalidate }; /* probing */ |