Skip to content

Commit bdbfcd5

Browse files
dkruceskeithbusch
authored andcommitted
nvme: Increase block size variable size to 32-bit
Increase block size variable size to 32-bit unsigned to be able to support block devices larger than 32k (starting from 64 KiB). Physical and logical block size already support unsigned 32-bit. Signed-off-by: Daniel Gomez <[email protected]> Reviewed-by: Luis Chamberlain <[email protected]> Reviewed-by: Christoph Hellwig <[email protected]> Signed-off-by: Keith Busch <[email protected]>
1 parent e9227d4 commit bdbfcd5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/nvme/host/core.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1835,7 +1835,7 @@ static void nvme_update_disk_info(struct gendisk *disk,
18351835
struct nvme_ns *ns, struct nvme_id_ns *id)
18361836
{
18371837
sector_t capacity = nvme_lba_to_sect(ns, le64_to_cpu(id->nsze));
1838-
unsigned short bs = 1 << ns->lba_shift;
1838+
u32 bs = 1U << ns->lba_shift;
18391839
u32 atomic_bs, phys_bs, io_opt = 0;
18401840

18411841
/*

0 commit comments

Comments
 (0)