Lines Matching refs:bdev
26 int __blkdev_issue_discard(struct block_device *bdev, sector_t sector, in __blkdev_issue_discard() argument
30 struct request_queue *q = bdev_get_queue(bdev); in __blkdev_issue_discard()
50 bs_mask = (bdev_logical_block_size(bdev) >> 9) - 1; in __blkdev_issue_discard()
56 alignment = (bdev_discard_alignment(bdev) >> 9) % granularity; in __blkdev_issue_discard()
89 bio_set_dev(bio, bdev); in __blkdev_issue_discard()
129 int blkdev_issue_discard(struct block_device *bdev, sector_t sector, in blkdev_issue_discard() argument
137 ret = __blkdev_issue_discard(bdev, sector, nr_sects, gfp_mask, flags, in blkdev_issue_discard()
163 static int __blkdev_issue_write_same(struct block_device *bdev, sector_t sector, in __blkdev_issue_write_same() argument
167 struct request_queue *q = bdev_get_queue(bdev); in __blkdev_issue_write_same()
175 bs_mask = (bdev_logical_block_size(bdev) >> 9) - 1; in __blkdev_issue_write_same()
179 if (!bdev_write_same(bdev)) in __blkdev_issue_write_same()
188 bio_set_dev(bio, bdev); in __blkdev_issue_write_same()
192 bio->bi_io_vec->bv_len = bdev_logical_block_size(bdev); in __blkdev_issue_write_same()
221 int blkdev_issue_write_same(struct block_device *bdev, sector_t sector, in blkdev_issue_write_same() argument
230 ret = __blkdev_issue_write_same(bdev, sector, nr_sects, gfp_mask, page, in blkdev_issue_write_same()
241 static int __blkdev_issue_write_zeroes(struct block_device *bdev, in __blkdev_issue_write_zeroes() argument
247 struct request_queue *q = bdev_get_queue(bdev); in __blkdev_issue_write_zeroes()
253 max_write_zeroes_sectors = bdev_write_zeroes_sectors(bdev); in __blkdev_issue_write_zeroes()
261 bio_set_dev(bio, bdev); in __blkdev_issue_write_zeroes()
294 static int __blkdev_issue_zero_pages(struct block_device *bdev, in __blkdev_issue_zero_pages() argument
298 struct request_queue *q = bdev_get_queue(bdev); in __blkdev_issue_zero_pages()
310 bio_set_dev(bio, bdev); in __blkdev_issue_zero_pages()
347 int __blkdev_issue_zeroout(struct block_device *bdev, sector_t sector, in __blkdev_issue_zeroout() argument
354 bs_mask = (bdev_logical_block_size(bdev) >> 9) - 1; in __blkdev_issue_zeroout()
358 ret = __blkdev_issue_write_zeroes(bdev, sector, nr_sects, gfp_mask, in __blkdev_issue_zeroout()
363 return __blkdev_issue_zero_pages(bdev, sector, nr_sects, gfp_mask, in __blkdev_issue_zeroout()
381 int blkdev_issue_zeroout(struct block_device *bdev, sector_t sector, in blkdev_issue_zeroout() argument
388 bool try_write_zeroes = !!bdev_write_zeroes_sectors(bdev); in blkdev_issue_zeroout()
390 bs_mask = (bdev_logical_block_size(bdev) >> 9) - 1; in blkdev_issue_zeroout()
398 ret = __blkdev_issue_write_zeroes(bdev, sector, nr_sects, in blkdev_issue_zeroout()
401 ret = __blkdev_issue_zero_pages(bdev, sector, nr_sects, in blkdev_issue_zeroout()
417 if (!bdev_write_zeroes_sectors(bdev)) { in blkdev_issue_zeroout()