diff options
author | Li Nan <linan122@huawei.com> | 2022-06-23 09:41:00 +0200 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2022-06-23 15:48:05 +0200 |
commit | ca2a3343d69741dae4df2dbb954fb806d9a835de (patch) | |
tree | ad459b0d6cb0cb439563cc2d99809db507ed01bf /block/holder.c | |
parent | block: pop cached rq before potentially blocking rq_qos_throttle() (diff) | |
download | linux-ca2a3343d69741dae4df2dbb954fb806d9a835de.tar.xz linux-ca2a3343d69741dae4df2dbb954fb806d9a835de.zip |
block: remove WARN_ON() from bd_link_disk_holder
Since commit 83cbce957446("block: add error handling for device_add_disk /
add_disk"), bdev->bd_holder_dir can not be empty now, so remove WARN_ON()
from bd_link_disk_holder.
Signed-off-by: Li Nan <linan122@huawei.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Link: https://lore.kernel.org/r/20220623074100.2251301-1-linan122@huawei.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'block/holder.c')
-rw-r--r-- | block/holder.c | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/block/holder.c b/block/holder.c index 8d750281a1cd..5283bc804cc1 100644 --- a/block/holder.c +++ b/block/holder.c @@ -79,10 +79,6 @@ int bd_link_disk_holder(struct block_device *bdev, struct gendisk *disk) WARN_ON_ONCE(!bdev->bd_holder); - /* FIXME: remove the following once add_disk() handles errors */ - if (WARN_ON(!bdev->bd_holder_dir)) - goto out_unlock; - holder = bd_find_holder_disk(bdev, disk); if (holder) { holder->refcnt++; |