Skip to content

Commit abfc9d8

Browse files
Christoph Hellwigaxboe
authored andcommitted
block: remove the fallback case in queue_dma_alignment
Now that all updates go through blk_validate_limits the default of 511 is set at initialization time. Also remove the unused NULL check as calling this helper on a NULL queue can't happen (and doesn't make much sense to start with). Signed-off-by: Christoph Hellwig <[email protected]> Reviewed-by: John Garry <[email protected]> Reviewed-by: Damien Le Moal <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Jens Axboe <[email protected]>
1 parent 73781b3 commit abfc9d8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

include/linux/blkdev.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1394,7 +1394,7 @@ static inline bool bdev_is_zone_start(struct block_device *bdev,
13941394

13951395
static inline int queue_dma_alignment(const struct request_queue *q)
13961396
{
1397-
return q ? q->limits.dma_alignment : 511;
1397+
return q->limits.dma_alignment;
13981398
}
13991399

14001400
static inline unsigned int

0 commit comments

Comments
 (0)