summaryrefslogtreecommitdiffstats
path: root/drivers/scsi/sd_zbc.c
diff options
context:
space:
mode:
authorJohannes Thumshirn <johannes.thumshirn@wdc.com>2023-06-13 05:31:45 -0700
committerMartin K. Petersen <martin.petersen@oracle.com>2023-06-16 12:04:31 -0400
commitce31dc540a01cab38943cdc2011cb1e4542ef5d7 (patch)
tree4f52d696ee4f8e1e4fbf340ba8dcc1e007d3df71 /drivers/scsi/sd_zbc.c
parente3d55626cff32cf7defff7f2053672adc4a712da (diff)
downloadlinux-ce31dc540a01cab38943cdc2011cb1e4542ef5d7.tar.gz
linux-ce31dc540a01cab38943cdc2011cb1e4542ef5d7.tar.bz2
linux-ce31dc540a01cab38943cdc2011cb1e4542ef5d7.zip
scsi: sd: sd_zbc: Use PAGE_SECTORS_SHIFT
Use PAGE_SECTORS_SHIFT instead of open-coding it. Signed-off-by: Johannes Thumshirn <johannes.thumshirn@wdc.com> Link: https://lore.kernel.org/r/20230613-sd_zbc-page_sectors-v1-1-363460a4413d@wdc.com Reviewed-by: Niklas Cassel <niklas.cassel@wdc.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/sd_zbc.c')
-rw-r--r--drivers/scsi/sd_zbc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/scsi/sd_zbc.c b/drivers/scsi/sd_zbc.c
index 22801c24ea19..abbd08933ac7 100644
--- a/drivers/scsi/sd_zbc.c
+++ b/drivers/scsi/sd_zbc.c
@@ -889,7 +889,7 @@ int sd_zbc_revalidate_zones(struct scsi_disk *sdkp)
}
max_append = min_t(u32, logical_to_sectors(sdkp->device, zone_blocks),
- q->limits.max_segments << (PAGE_SHIFT - 9));
+ q->limits.max_segments << PAGE_SECTORS_SHIFT);
max_append = min_t(u32, max_append, queue_max_hw_sectors(q));
blk_queue_max_zone_append_sectors(q, max_append);