[PATCH] nvme: zns: limit max_zone_append by max_segments

Christoph Hellwig hch at infradead.org
Mon Jul 31 07:05:40 PDT 2023


On Mon, Jul 31, 2023 at 11:02:35PM +0900, Damien Le Moal wrote:
> > 
> > 	blk_queue_max_zone_append_sectors(q,
> > 		queue_max_sectors(q), ns->ctrl->max_zone_append);
> 
> blk_queue_max_zone_append_sectors() already does cap max zone append to
> max_hw_sectors.

Then we should not need this..

> We could also add the cap to queue_max_segments(q) <<
> PAGE_SECTORS_SHIFT in that function as well given that all zoned devices should
> have that anyway...

No.  That's a NVMe specific thing.  Most SCSI HBAs don't have this
issue.  NVMe devices supporting SGLs don't really have it either, but
for that we'd need to commit to always using SGLs for non-tiny I/O,
which we should probably be doing.



More information about the Linux-nvme mailing list