Skip to content

Commit c632021

Browse files
Christoph Hellwigaxboe
authored andcommitted
block: move blkdev_{get,put} _no_open prototypes out of blkdev.h
These are only to be used by block internal code. Remove the comment as we grew more users due to reworking block device node opening. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Christian Brauner <brauner@kernel.org> Acked-by: Tejun Heo <tj@kernel.org> Link: https://lore.kernel.org/r/20250423053810.1683309-2-hch@lst.de Signed-off-by: Jens Axboe <axboe@kernel.dk>
1 parent 7b720c7 commit c632021

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

block/blk.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,9 @@ static inline void blk_wait_io(struct completion *done)
9494
wait_for_completion_io(done);
9595
}
9696

97+
struct block_device *blkdev_get_no_open(dev_t dev);
98+
void blkdev_put_no_open(struct block_device *bdev);
99+
97100
#define BIO_INLINE_VECS 4
98101
struct bio_vec *bvec_alloc(mempool_t *pool, unsigned short *nr_vecs,
99102
gfp_t gfp_mask);

include/linux/blkdev.h

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1671,10 +1671,6 @@ int bd_prepare_to_claim(struct block_device *bdev, void *holder,
16711671
const struct blk_holder_ops *hops);
16721672
void bd_abort_claiming(struct block_device *bdev, void *holder);
16731673

1674-
/* just for blk-cgroup, don't use elsewhere */
1675-
struct block_device *blkdev_get_no_open(dev_t dev);
1676-
void blkdev_put_no_open(struct block_device *bdev);
1677-
16781674
struct block_device *I_BDEV(struct inode *inode);
16791675
struct block_device *file_bdev(struct file *bdev_file);
16801676
bool disk_live(struct gendisk *disk);

0 commit comments

Comments
 (0)