public inbox for linux-rdma@vger.kernel.org
 help / color / mirror / Atom feed
From: Sagi Grimberg <sagig-LDSdmyG8hGV8YrgS2mwiifqBs+8SCbDb@public.gmane.org>
To: "Nicholas A. Bellinger"
	<nab-IzHhD5pYlfBP7FQvKIMDCQ@public.gmane.org>,
	Sagi Grimberg <sagig-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
Cc: target-devel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	roland-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org,
	linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	oren-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org,
	martin.petersen-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org
Subject: Re: [PATCH v2 12/12] IB/isert: Support T10-PI protected transactions
Date: Thu, 13 Mar 2014 20:57:50 +0200	[thread overview]
Message-ID: <5321FFAE.5050105@dev.mellanox.co.il> (raw)
In-Reply-To: <1394734546.19265.2.camel-XoQW25Eq2zviZyQQd+hFbcojREIfoBdhmpATvIKMPHk@public.gmane.org>

On 3/13/2014 8:15 PM, Nicholas A. Bellinger wrote:
> Hey Sagi,
>
> On Wed, 2014-02-19 at 17:50 +0200, Sagi Grimberg wrote:
>> In case the Target core passed transport T10 protection
>> operation:
>>
>> 1. Register data buffer (data memory region)
>> 2. Register protection buffer if exsists (prot memory region)
>> 3. Register signature region (signature memory region)
>>     - use work request IB_WR_REG_SIG_MR
>> 4. Execute RDMA
>> 5. Upon RDMA completion check the signature status
>>     - if succeeded send good SCSI response
>>     - if failed send SCSI bad response with appropriate sense buffer
>>
>> Signed-off-by: Sagi Grimberg <sagig-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
>> ---
>>   drivers/infiniband/ulp/isert/ib_isert.c |  321 ++++++++++++++++++++++++++++---
>>   drivers/infiniband/ulp/isert/ib_isert.h |    1 +
>>   2 files changed, 292 insertions(+), 30 deletions(-)
>>
>> diff --git a/drivers/infiniband/ulp/isert/ib_isert.c b/drivers/infiniband/ulp/isert/ib_isert.c
>> index 3871ab2..04bdd79 100644
>> --- a/drivers/infiniband/ulp/isert/ib_isert.c
>> +++ b/drivers/infiniband/ulp/isert/ib_isert.c
> <SNIP>
>
>> @@ -2454,26 +2708,33 @@ isert_put_datain(struct iscsi_conn *conn, struct iscsi_cmd *cmd)
>>   		return rc;
>>   	}
>>   
>> -	/*
>> -	 * Build isert_conn->tx_desc for iSCSI response PDU and attach
>> -	 */
>> -	isert_create_send_desc(isert_conn, isert_cmd, &isert_cmd->tx_desc);
>> -	iscsit_build_rsp_pdu(cmd, conn, true, (struct iscsi_scsi_rsp *)
>> -			     &isert_cmd->tx_desc.iscsi_header);
>> -	isert_init_tx_hdrs(isert_conn, &isert_cmd->tx_desc);
>> -	isert_init_send_wr(isert_conn, isert_cmd,
>> -			   &isert_cmd->tx_desc.send_wr, true);
>> +	if (se_cmd->prot_type == TARGET_PROT_NORMAL) {
>> +		/*
>> +		 * Build isert_conn->tx_desc for iSCSI response PDU and attach
>> +		 */
>> +		isert_create_send_desc(isert_conn, isert_cmd,
>> +				       &isert_cmd->tx_desc);
>> +		iscsit_build_rsp_pdu(cmd, conn, false, (struct iscsi_scsi_rsp *)
>> +				     &isert_cmd->tx_desc.iscsi_header);
>> +		isert_init_tx_hdrs(isert_conn, &isert_cmd->tx_desc);
>> +		isert_init_send_wr(isert_conn, isert_cmd,
>> +				   &isert_cmd->tx_desc.send_wr, true);
>> +		isert_cmd->rdma_wr.s_send_wr.next = &isert_cmd->tx_desc.send_wr;
>> +	}
>>   
> So I'm fixing up some v3.14-rc6 context changes before applying this
> series to for-next, and noticed something above..
>
> Namely, that iscsi_build_rsp_pdu() has been changed to pass 'false' as
> it's second argument vs. the original case passing 'true'.  This boolean
> controls the incrementing of the StatSN in the traditional response
> header, which AFAICT should still be 'true' for this case.
>
> Is there a reason why this was changed..?

Well, it wrong... This probably was left around when I rebased to 3.14 
(earlier versions incremented StatSN explicitly).
I wonder how that works though...

Want me to fix and resend?

Sagi.
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  parent reply	other threads:[~2014-03-13 18:57 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-02-19 15:50 [PATCH v2 00/12] T10-DIF Initial support for iSER target Sagi Grimberg
2014-02-19 15:50 ` [PATCH v2 01/12] Target/transport: Allocate protection sg if needed Sagi Grimberg
2014-02-19 15:50 ` [PATCH v2 02/12] Target/sbc: Set protection operation and relevant checks Sagi Grimberg
2014-02-19 15:50 ` [PATCH v2 03/12] Target/file: place escape values for protection information format Sagi Grimberg
2014-02-19 15:50 ` [PATCH v2 04/12] Target/sbc: don't return from sbc_check for non prot_sg Sagi Grimberg
2014-02-19 15:50 ` [PATCH v2 05/12] Target/core: Remove prot_handover use for now Sagi Grimberg
2014-02-19 15:50 ` [PATCH v2 06/12] Target/iscsi: Add T10-PI indication for iscsi_portal_group Sagi Grimberg
2014-02-19 15:50 ` [PATCH v2 07/12] Target/configfs: Expose iSCSI network portal group T10-PI support Sagi Grimberg
     [not found] ` <1392825025-29943-1-git-send-email-sagig-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
2014-02-19 15:50   ` [PATCH v2 08/12] Target/sbc: add debug print Sagi Grimberg
2014-02-19 15:50   ` [PATCH v2 09/12] IB/isert: Introduce isert_map/unmap_data_buf Sagi Grimberg
2014-02-19 15:50   ` [PATCH v2 10/12] IB/isert: Initialize T10-PI resources Sagi Grimberg
2014-02-19 15:50   ` [PATCH v2 11/12] IB/isert: Accept RDMA_WRITE completions Sagi Grimberg
2014-02-19 15:50   ` [PATCH v2 12/12] IB/isert: Support T10-PI protected transactions Sagi Grimberg
2014-03-13 18:15     ` Nicholas A. Bellinger
     [not found]       ` <1394734546.19265.2.camel-XoQW25Eq2zviZyQQd+hFbcojREIfoBdhmpATvIKMPHk@public.gmane.org>
2014-03-13 18:57         ` Sagi Grimberg [this message]
2014-03-13 18:59           ` Nicholas A. Bellinger
2014-03-13 19:14             ` Sagi Grimberg
2014-03-13 19:16               ` Nicholas A. Bellinger
2014-02-19 23:14 ` [PATCH v2 00/12] T10-DIF Initial support for iSER target Nicholas A. Bellinger
2014-02-20 12:51   ` Sagi Grimberg

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5321FFAE.5050105@dev.mellanox.co.il \
    --to=sagig-ldsdmyg8hgv8yrgs2mwiifqbs+8scbdb@public.gmane.org \
    --cc=linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=martin.petersen-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org \
    --cc=nab-IzHhD5pYlfBP7FQvKIMDCQ@public.gmane.org \
    --cc=oren-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org \
    --cc=roland-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
    --cc=sagig-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org \
    --cc=target-devel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox