mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-11 05:17:10 +09:00
Target/iser: Gracefully reject T10-PI enabled connect request if not supported
commit 5f80ff8ecc upstream.
In case user chose to set T10-PI enable on the target while
the IB device does not support it, gracefully reject the request.
Reported-by: Slava Shwartsman <valyushash@gmail.com>
Signed-off-by: Sagi Grimberg <sagig@mellanox.com>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
d616f6745d
commit
5b50bf7e57
@@ -663,8 +663,9 @@ isert_connect_request(struct rdma_cm_id *cma_id, struct rdma_cm_event *event)
|
||||
|
||||
pi_support = np->tpg_np->tpg->tpg_attrib.t10_pi;
|
||||
if (pi_support && !device->pi_capable) {
|
||||
pr_err("Protection information requested but not supported\n");
|
||||
ret = -EINVAL;
|
||||
pr_err("Protection information requested but not supported, "
|
||||
"rejecting connect request\n");
|
||||
ret = rdma_reject(cma_id, NULL, 0);
|
||||
goto out_mr;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user