[PATCH 3/3] nvme: don't set io_opt if NOWS is zero
Chaitanya Kulkarni
chaitanyak at nvidia.com
Mon Jul 1 00:02:38 PDT 2024
On 6/30/24 22:17, Christoph Hellwig wrote:
> NOWS is one of the annoying "0's based values" in NVMe, where 0 means one
> and we thus can't detect if it isn't set. Thus a NOWS value of 0 means
> that the Namespace Optimal Write Size is a single LBA, which is clearly
> bogus. Ignore the value in that case and don't propagate an io_opt
> value to the block layer.
>
> Signed-off-by: Christoph Hellwig<hch at lst.de>
indeed (Figure 97: Identify -> Namespace Optimal Write Size (NOWS)).
wonder why can't spec use 0xFFFF to indicate not supported for all
zero based values to avoid this confusion ?
Looks good.
Reviewed-by: Chaitanya Kulkarni <kch at nvidia.com>
-ck
More information about the Linux-nvme
mailing list