[PATCH v2] nvme: split nvme_update_zone_info

Christoph Hellwig hch at lst.de
Tue Apr 2 20:40:55 PDT 2024


On Tue, Apr 02, 2024 at 01:58:25PM -0600, Keith Busch wrote:
> On Tue, Apr 02, 2024 at 04:47:54PM +0200, Christoph Hellwig wrote:
> > +	lim->chunk_sectors = ns->head->zsze =
> > +		nvme_lba_to_sect(ns->head, zi->zone_size);
> 
> Hey, since chuck_sectors is only 32 bits and zone_size is 64, do we need
> to worry about massive zones breaking this limit? Unlikely as we are to
> see a multi-terabyte zone, it's easy enough to check. We never have
> before though, so I guess we're confident it won't happen?

Reasonable confident.  Adding an overflow check probably would not be a
bad idea.  I can look into a patch for that.



More information about the Linux-nvme mailing list