diff options
author | Keith Busch <kbusch@kernel.org> | 2022-02-15 16:03:08 +0100 |
---|---|---|
committer | Christoph Hellwig <hch@lst.de> | 2022-02-28 12:45:06 +0100 |
commit | 1c3adf0de1db86cf354dcb1a2dd1184e5e63a50a (patch) | |
tree | c2ba3ac3621f270e6f8032ae93806e14d00c367f /drivers/nvme | |
parent | nvme: expose cntrltype and dctype through sysfs (diff) | |
download | linux-1c3adf0de1db86cf354dcb1a2dd1184e5e63a50a.tar.xz linux-1c3adf0de1db86cf354dcb1a2dd1184e5e63a50a.zip |
nvme: explicitly set non-error for directives
Stream directives is an optional feature. It is not an error if a
controller doesn't support as many as the kernel can optionally use.
Explicitly set the non-error return value on this condition with a
comment explaining why.
Note, the return value was already 0 in this condition, so the setting
is redundant. This patch should just silence bots that falsely believe
the condition contains an error omission.
Signed-off-by: Keith Busch <kbusch@kernel.org>
Reviewed-by: Chaitanya Kulkarni <kch@nvidia.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'drivers/nvme')
-rw-r--r-- | drivers/nvme/host/core.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/nvme/host/core.c b/drivers/nvme/host/core.c index 52a49ae5b673..1ce579d583c0 100644 --- a/drivers/nvme/host/core.c +++ b/drivers/nvme/host/core.c @@ -809,6 +809,8 @@ static int nvme_configure_directives(struct nvme_ctrl *ctrl) if (ctrl->nssa < BLK_MAX_WRITE_HINTS - 1) { dev_info(ctrl->device, "too few streams (%u) available\n", ctrl->nssa); + /* this condition is not an error: streams are optional */ + ret = 0; goto out_disable_stream; } |