summaryrefslogtreecommitdiff
path: root/include/linux/blkdev.h
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2022-04-15 07:52:48 +0300
committerJens Axboe <axboe@kernel.dk>2022-04-18 04:49:59 +0300
commit640f2a23911b8388989547f89d055afbb910b88e (patch)
treec52298860b2e43cb1c536d097ae958f3651f9335 /include/linux/blkdev.h
parent64dcc7c2717395b7c83ffb10f040d3be795d03c1 (diff)
downloadlinux-640f2a23911b8388989547f89d055afbb910b88e.tar.xz
block: use bdev_alignment_offset in disk_alignment_offset_show
This does the same as the open coded variant except for an extra branch, and allows to remove queue_alignment_offset entirely. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Martin K. Petersen <martin.petersen@oracle.com> Link: https://lore.kernel.org/r/20220415045258.199825-18-hch@lst.de Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'include/linux/blkdev.h')
-rw-r--r--include/linux/blkdev.h8
1 files changed, 0 insertions, 8 deletions
diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h
index f8c50b77543e..d5346e72e364 100644
--- a/include/linux/blkdev.h
+++ b/include/linux/blkdev.h
@@ -1251,14 +1251,6 @@ bdev_zone_write_granularity(struct block_device *bdev)
return queue_zone_write_granularity(bdev_get_queue(bdev));
}
-static inline int queue_alignment_offset(const struct request_queue *q)
-{
- if (q->limits.misaligned)
- return -1;
-
- return q->limits.alignment_offset;
-}
-
static inline int queue_limit_alignment_offset(struct queue_limits *lim, sector_t sector)
{
unsigned int granularity = max(lim->physical_block_size, lim->io_min);