* [PATCH -next] nvme-tcp-offload: Fix error return code in nvme_tcp_ofld_setup_ctrl()
@ 2021-06-08 14:38 ` Wei Yongjun
0 siblings, 0 replies; 2+ messages in thread
From: Wei Yongjun @ 2021-06-08 14:38 UTC (permalink / raw)
To: weiyongjun1, Arie Gershberg, Shai Malin, Ariel Elior,
Keith Busch, Jens Axboe, Christoph Hellwig, Sagi Grimberg
Cc: linux-nvme, linux-kernel, kernel-janitors, Hulk Robot
Fix to return negative error code -EINVAL if mandatory sgls
are not supported.
Fixes: 5aadd5f9311e ("nvme-tcp-offload: Add controller level implementation")
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
---
drivers/nvme/host/tcp-offload.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/nvme/host/tcp-offload.c b/drivers/nvme/host/tcp-offload.c
index c76822e5ada7..3879d5ed7497 100644
--- a/drivers/nvme/host/tcp-offload.c
+++ b/drivers/nvme/host/tcp-offload.c
@@ -622,6 +622,7 @@ static int nvme_tcp_ofld_setup_ctrl(struct nvme_ctrl *nctrl, bool new)
if (!(nctrl->sgls & ((1 << 0) | (1 << 1)))) {
dev_err(nctrl->device, "Mandatory sgls are not supported!\n");
+ rc = -EINVAL;
goto destroy_admin;
}
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [PATCH -next] nvme-tcp-offload: Fix error return code in nvme_tcp_ofld_setup_ctrl()
@ 2021-06-08 14:38 ` Wei Yongjun
0 siblings, 0 replies; 2+ messages in thread
From: Wei Yongjun @ 2021-06-08 14:38 UTC (permalink / raw)
To: weiyongjun1, Arie Gershberg, Shai Malin, Ariel Elior,
Keith Busch, Jens Axboe, Christoph Hellwig, Sagi Grimberg
Cc: linux-nvme, linux-kernel, kernel-janitors, Hulk Robot
Fix to return negative error code -EINVAL if mandatory sgls
are not supported.
Fixes: 5aadd5f9311e ("nvme-tcp-offload: Add controller level implementation")
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
---
drivers/nvme/host/tcp-offload.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/nvme/host/tcp-offload.c b/drivers/nvme/host/tcp-offload.c
index c76822e5ada7..3879d5ed7497 100644
--- a/drivers/nvme/host/tcp-offload.c
+++ b/drivers/nvme/host/tcp-offload.c
@@ -622,6 +622,7 @@ static int nvme_tcp_ofld_setup_ctrl(struct nvme_ctrl *nctrl, bool new)
if (!(nctrl->sgls & ((1 << 0) | (1 << 1)))) {
dev_err(nctrl->device, "Mandatory sgls are not supported!\n");
+ rc = -EINVAL;
goto destroy_admin;
}
_______________________________________________
Linux-nvme mailing list
Linux-nvme@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-nvme
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2021-06-08 14:32 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-08 14:38 [PATCH -next] nvme-tcp-offload: Fix error return code in nvme_tcp_ofld_setup_ctrl() Wei Yongjun
2021-06-08 14:38 ` Wei Yongjun
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.