diff options
author | Nicholas Bellinger <nab@linux-iscsi.org> | 2014-04-02 15:52:38 -0400 |
---|---|---|
committer | Nicholas Bellinger <nab@linux-iscsi.org> | 2014-04-07 04:48:54 -0400 |
commit | e70beee783d6977d80eede88a3394f02eabddad1 (patch) | |
tree | 225d10e36bf031e9c4eab3de537699b60bb48f1b /drivers/scsi | |
parent | d84287bcfe624697cd4f3c1df746beb53b86d9c4 (diff) |
target: Pass in transport supported PI at session initialization
In order to support local WRITE_INSERT + READ_STRIP operations for
non PI enabled fabrics, the fabric driver needs to be able signal
what protection offload operations are supported.
This is done at session initialization time so the modes can be
signaled by individual se_wwn + se_portal_group endpoints, as well
as optionally across different transports on the same endpoint.
For iser-target, set TARGET_PROT_ALL if the underlying ib_device
has already signaled PI offload support, and allow this to be
exposed via a new iscsit_transport->iscsit_get_sup_prot_ops()
callback.
For loopback, set TARGET_PROT_ALL to signal SCSI initiator mode
operation.
For all other drivers, set TARGET_PROT_NORMAL to disable fabric
level PI.
Cc: Martin K. Petersen <martin.petersen@oracle.com>
Cc: Sagi Grimberg <sagig@mellanox.com>
Cc: Or Gerlitz <ogerlitz@mellanox.com>
Cc: Quinn Tran <quinn.tran@qlogic.com>
Cc: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
Diffstat (limited to 'drivers/scsi')
-rw-r--r-- | drivers/scsi/qla2xxx/tcm_qla2xxx.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/scsi/qla2xxx/tcm_qla2xxx.c b/drivers/scsi/qla2xxx/tcm_qla2xxx.c index b23a0ffe140e..68fb66fdb757 100644 --- a/drivers/scsi/qla2xxx/tcm_qla2xxx.c +++ b/drivers/scsi/qla2xxx/tcm_qla2xxx.c | |||
@@ -1482,7 +1482,7 @@ static int tcm_qla2xxx_check_initiator_node_acl( | |||
1482 | } | 1482 | } |
1483 | se_tpg = &tpg->se_tpg; | 1483 | se_tpg = &tpg->se_tpg; |
1484 | 1484 | ||
1485 | se_sess = transport_init_session(); | 1485 | se_sess = transport_init_session(TARGET_PROT_NORMAL); |
1486 | if (IS_ERR(se_sess)) { | 1486 | if (IS_ERR(se_sess)) { |
1487 | pr_err("Unable to initialize struct se_session\n"); | 1487 | pr_err("Unable to initialize struct se_session\n"); |
1488 | return PTR_ERR(se_sess); | 1488 | return PTR_ERR(se_sess); |