mbox series

[v3,00/11] qla2xxx: Add EDIF support

Message ID 20210623102611.3637-1-njavali@marvell.com
Headers show
Series qla2xxx: Add EDIF support | expand

Message

Nilesh Javali June 23, 2021, 10:26 a.m. UTC
Martin,
Please apply the EDIF support feature to the scsi tree at your earliest
convenience.

v3:
- Incorporate the review comments.
- Enable recently added heartbeat validation for EDIF.

v2:
Split the EDIF support feature into logical commits for better readability.

Thanks,
Nilesh

Nilesh Javali (1):
  qla2xxx: Update version to 10.02.00.107-k

Quinn Tran (10):
  qla2xxx: Add start + stop bsg's
  qla2xxx: Add getfcinfo and statistic bsg's
  qla2xxx: Add send, receive and accept for auth_els
  qla2xxx: Add extraction of auth_els from the wire
  qla2xxx: Add key update
  qla2xxx: Add authentication pass + fail bsg's
  qla2xxx: Add detection of secure device
  qla2xxx: Add doorbell notification for app
  qla2xxx: Add encryption to IO path
  qla2xxx: enable heartbeat validation for edif command

 drivers/scsi/qla2xxx/Makefile       |    3 +-
 drivers/scsi/qla2xxx/qla_attr.c     |    5 +
 drivers/scsi/qla2xxx/qla_bsg.c      |   90 +-
 drivers/scsi/qla2xxx/qla_bsg.h      |    3 +
 drivers/scsi/qla2xxx/qla_dbg.h      |    1 +
 drivers/scsi/qla2xxx/qla_def.h      |  195 +-
 drivers/scsi/qla2xxx/qla_edif.c     | 3409 +++++++++++++++++++++++++++
 drivers/scsi/qla2xxx/qla_edif.h     |  128 +
 drivers/scsi/qla2xxx/qla_edif_bsg.h |  220 ++
 drivers/scsi/qla2xxx/qla_fw.h       |   12 +-
 drivers/scsi/qla2xxx/qla_gbl.h      |   50 +-
 drivers/scsi/qla2xxx/qla_gs.c       |    6 +-
 drivers/scsi/qla2xxx/qla_init.c     |  168 +-
 drivers/scsi/qla2xxx/qla_iocb.c     |   69 +-
 drivers/scsi/qla2xxx/qla_isr.c      |  320 ++-
 drivers/scsi/qla2xxx/qla_mbx.c      |   33 +-
 drivers/scsi/qla2xxx/qla_mid.c      |    7 +-
 drivers/scsi/qla2xxx/qla_nvme.c     |    4 +
 drivers/scsi/qla2xxx/qla_os.c       |  101 +-
 drivers/scsi/qla2xxx/qla_target.c   |  145 +-
 drivers/scsi/qla2xxx/qla_target.h   |   19 +-
 drivers/scsi/qla2xxx/qla_version.h  |    4 +-
 22 files changed, 4845 insertions(+), 147 deletions(-)
 create mode 100644 drivers/scsi/qla2xxx/qla_edif.c
 create mode 100644 drivers/scsi/qla2xxx/qla_edif.h
 create mode 100644 drivers/scsi/qla2xxx/qla_edif_bsg.h


base-commit: 041761f4a4db662e38b4ae9d510b8beb24c7d4b6
prerequisite-patch-id: 62258e2861a8064d0d7fc3ea4efbf71758054bde

Comments

Himanshu Madhani June 23, 2021, 6:47 p.m. UTC | #1
On 6/23/21 5:26 AM, Nilesh Javali wrote:
> From: Quinn Tran <qutran@marvell.com>
> 
> Increment the command and the completion counts.

I don't see enablement of heartbeat validation code in this patch.

Am i missing something?

> 
> Signed-off-by: Quinn Tran <qutran@marvell.com>
> Signed-off-by: Nilesh Javali <njavali@marvell.com>
> ---
>   drivers/scsi/qla2xxx/qla_edif.c | 1 +
>   drivers/scsi/qla2xxx/qla_isr.c  | 3 +--
>   2 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/scsi/qla2xxx/qla_edif.c b/drivers/scsi/qla2xxx/qla_edif.c
> index 8e730cc882e6..ccbe0e1bfcbc 100644
> --- a/drivers/scsi/qla2xxx/qla_edif.c
> +++ b/drivers/scsi/qla2xxx/qla_edif.c
> @@ -2926,6 +2926,7 @@ qla28xx_start_scsi_edif(srb_t *sp)
>   		req->ring_ptr++;
>   	}
>   
> +	sp->qpair->cmd_cnt++;
>   	/* Set chip new ring index. */
>   	wrt_reg_dword(req->req_q_in, req->ring_index);
>   
> diff --git a/drivers/scsi/qla2xxx/qla_isr.c b/drivers/scsi/qla2xxx/qla_isr.c
> index ce4f93fb4d25..e8928fd83049 100644
> --- a/drivers/scsi/qla2xxx/qla_isr.c
> +++ b/drivers/scsi/qla2xxx/qla_isr.c
> @@ -3192,10 +3192,9 @@ qla2x00_status_entry(scsi_qla_host_t *vha, struct rsp_que *rsp, void *pkt)
>   		return;
>   	}
>   
> -	sp->qpair->cmd_completion_cnt++;
> -
>   	/* Fast path completion. */
>   	qla_chk_edif_rx_sa_delete_pending(vha, sp, sts24);
> +	sp->qpair->cmd_completion_cnt++;
>   
>   	if (comp_status == CS_COMPLETE && scsi_status == 0) {
>   		qla2x00_process_completed_request(vha, req, handle);
>
Nilesh Javali June 24, 2021, 4:02 a.m. UTC | #2
Himanshu,

The heartbeat check patch attached does the actual validation,
and the same is extended for edif commands too.

Thanks,
Nilesh

> -----Original Message-----

> From: Himanshu Madhani <himanshu.madhani@oracle.com>

> Sent: Thursday, June 24, 2021 12:17 AM

> To: Nilesh Javali <njavali@marvell.com>; martin.petersen@oracle.com

> Cc: linux-scsi@vger.kernel.org; GR-QLogic-Storage-Upstream <GR-QLogic-

> Storage-Upstream@marvell.com>

> Subject: [EXT] Re: [PATCH v3 10/11] qla2xxx: enable heartbeat validation for

> edif command

> 

> External Email

> 

> ----------------------------------------------------------------------

> 

> 

> On 6/23/21 5:26 AM, Nilesh Javali wrote:

> > From: Quinn Tran <qutran@marvell.com>

> >

> > Increment the command and the completion counts.

> 

> I don't see enablement of heartbeat validation code in this patch.

> 

> Am i missing something?

> 

> >

> > Signed-off-by: Quinn Tran <qutran@marvell.com>

> > Signed-off-by: Nilesh Javali <njavali@marvell.com>

> > ---

> >   drivers/scsi/qla2xxx/qla_edif.c | 1 +

> >   drivers/scsi/qla2xxx/qla_isr.c  | 3 +--

> >   2 files changed, 2 insertions(+), 2 deletions(-)

> >

> > diff --git a/drivers/scsi/qla2xxx/qla_edif.c b/drivers/scsi/qla2xxx/qla_edif.c

> > index 8e730cc882e6..ccbe0e1bfcbc 100644

> > --- a/drivers/scsi/qla2xxx/qla_edif.c

> > +++ b/drivers/scsi/qla2xxx/qla_edif.c

> > @@ -2926,6 +2926,7 @@ qla28xx_start_scsi_edif(srb_t *sp)

> >   		req->ring_ptr++;

> >   	}

> >

> > +	sp->qpair->cmd_cnt++;

> >   	/* Set chip new ring index. */

> >   	wrt_reg_dword(req->req_q_in, req->ring_index);

> >

> > diff --git a/drivers/scsi/qla2xxx/qla_isr.c b/drivers/scsi/qla2xxx/qla_isr.c

> > index ce4f93fb4d25..e8928fd83049 100644

> > --- a/drivers/scsi/qla2xxx/qla_isr.c

> > +++ b/drivers/scsi/qla2xxx/qla_isr.c

> > @@ -3192,10 +3192,9 @@ qla2x00_status_entry(scsi_qla_host_t *vha,

> struct rsp_que *rsp, void *pkt)

> >   		return;

> >   	}

> >

> > -	sp->qpair->cmd_completion_cnt++;

> > -

> >   	/* Fast path completion. */

> >   	qla_chk_edif_rx_sa_delete_pending(vha, sp, sts24);

> > +	sp->qpair->cmd_completion_cnt++;

> >

> >   	if (comp_status == CS_COMPLETE && scsi_status == 0) {

> >   		qla2x00_process_completed_request(vha, req, handle);

> >

> 

> --

> Himanshu Madhani                                Oracle Linux Engineering
External Email

----------------------------------------------------------------------

Nilesh,

> Use 'no-op' mailbox command to check and see if FW is still

> responsive.


Applied to 5.14/scsi-staging, thanks!

-- 
Martin K. Petersen	Oracle Linux Engineering
Himanshu Madhani June 24, 2021, 4:27 a.m. UTC | #3
On 6/23/21 11:02 PM, Nilesh Javali wrote:
> Himanshu,

> 

> The heartbeat check patch attached does the actual validation,

> and the same is extended for edif commands too.

> 

Correct.... this patch is not doing that enablment right?

My point is that your commit subject and commit log does not match. it 
should say "qla2xxx: Increment EDIF command and completion counts" 
instead of "qla2xxx: enable heartbeat validation for edif command"

> Thanks,

> Nilesh

> 

>> -----Original Message-----

>> From: Himanshu Madhani <himanshu.madhani@oracle.com>

>> Sent: Thursday, June 24, 2021 12:17 AM

>> To: Nilesh Javali <njavali@marvell.com>; martin.petersen@oracle.com

>> Cc: linux-scsi@vger.kernel.org; GR-QLogic-Storage-Upstream <GR-QLogic-

>> Storage-Upstream@marvell.com>

>> Subject: [EXT] Re: [PATCH v3 10/11] qla2xxx: enable heartbeat validation for

>> edif command

>>

>> External Email

>>

>> ----------------------------------------------------------------------

>>

>>

>> On 6/23/21 5:26 AM, Nilesh Javali wrote:

>>> From: Quinn Tran <qutran@marvell.com>

>>>

>>> Increment the command and the completion counts.

>>

>> I don't see enablement of heartbeat validation code in this patch.

>>

>> Am i missing something?

>>

>>>

>>> Signed-off-by: Quinn Tran <qutran@marvell.com>

>>> Signed-off-by: Nilesh Javali <njavali@marvell.com>

>>> ---

>>>    drivers/scsi/qla2xxx/qla_edif.c | 1 +

>>>    drivers/scsi/qla2xxx/qla_isr.c  | 3 +--

>>>    2 files changed, 2 insertions(+), 2 deletions(-)

>>>

>>> diff --git a/drivers/scsi/qla2xxx/qla_edif.c b/drivers/scsi/qla2xxx/qla_edif.c

>>> index 8e730cc882e6..ccbe0e1bfcbc 100644

>>> --- a/drivers/scsi/qla2xxx/qla_edif.c

>>> +++ b/drivers/scsi/qla2xxx/qla_edif.c

>>> @@ -2926,6 +2926,7 @@ qla28xx_start_scsi_edif(srb_t *sp)

>>>    		req->ring_ptr++;

>>>    	}

>>>

>>> +	sp->qpair->cmd_cnt++;

>>>    	/* Set chip new ring index. */

>>>    	wrt_reg_dword(req->req_q_in, req->ring_index);

>>>

>>> diff --git a/drivers/scsi/qla2xxx/qla_isr.c b/drivers/scsi/qla2xxx/qla_isr.c

>>> index ce4f93fb4d25..e8928fd83049 100644

>>> --- a/drivers/scsi/qla2xxx/qla_isr.c

>>> +++ b/drivers/scsi/qla2xxx/qla_isr.c

>>> @@ -3192,10 +3192,9 @@ qla2x00_status_entry(scsi_qla_host_t *vha,

>> struct rsp_que *rsp, void *pkt)

>>>    		return;

>>>    	}

>>>

>>> -	sp->qpair->cmd_completion_cnt++;

>>> -

>>>    	/* Fast path completion. */

>>>    	qla_chk_edif_rx_sa_delete_pending(vha, sp, sts24);

>>> +	sp->qpair->cmd_completion_cnt++;

>>>

>>>    	if (comp_status == CS_COMPLETE && scsi_status == 0) {

>>>    		qla2x00_process_completed_request(vha, req, handle);

>>>

>>

>> --

>> Himanshu Madhani                                Oracle Linux Engineering


-- 
Himanshu Madhani                                Oracle Linux Engineering
Nilesh Javali June 24, 2021, 4:52 a.m. UTC | #4
Himanshu,

I would re-word the subject line and re-send as v4.
Thanks for review.

--
Nilesh

> -----Original Message-----

> From: Himanshu Madhani <himanshu.madhani@oracle.com>

> Sent: Thursday, June 24, 2021 9:57 AM

> To: Nilesh Javali <njavali@marvell.com>; martin.petersen@oracle.com

> Cc: linux-scsi@vger.kernel.org; GR-QLogic-Storage-Upstream <GR-QLogic-

> Storage-Upstream@marvell.com>

> Subject: Re: [EXT] Re: [PATCH v3 10/11] qla2xxx: enable heartbeat validation

> for edif command

> 

> 

> 

> On 6/23/21 11:02 PM, Nilesh Javali wrote:

> > Himanshu,

> >

> > The heartbeat check patch attached does the actual validation,

> > and the same is extended for edif commands too.

> >

> Correct.... this patch is not doing that enablment right?

> 

> My point is that your commit subject and commit log does not match. it

> should say "qla2xxx: Increment EDIF command and completion counts"

> instead of "qla2xxx: enable heartbeat validation for edif command"

> 

> > Thanks,

> > Nilesh

> >

> >> -----Original Message-----

> >> From: Himanshu Madhani <himanshu.madhani@oracle.com>

> >> Sent: Thursday, June 24, 2021 12:17 AM

> >> To: Nilesh Javali <njavali@marvell.com>; martin.petersen@oracle.com

> >> Cc: linux-scsi@vger.kernel.org; GR-QLogic-Storage-Upstream <GR-QLogic-

> >> Storage-Upstream@marvell.com>

> >> Subject: [EXT] Re: [PATCH v3 10/11] qla2xxx: enable heartbeat validation

> for

> >> edif command

> >>

> >> External Email

> >>

> >> ----------------------------------------------------------------------

> >>

> >>

> >> On 6/23/21 5:26 AM, Nilesh Javali wrote:

> >>> From: Quinn Tran <qutran@marvell.com>

> >>>

> >>> Increment the command and the completion counts.

> >>

> >> I don't see enablement of heartbeat validation code in this patch.

> >>

> >> Am i missing something?

> >>

> >>>

> >>> Signed-off-by: Quinn Tran <qutran@marvell.com>

> >>> Signed-off-by: Nilesh Javali <njavali@marvell.com>

> >>> ---

> >>>    drivers/scsi/qla2xxx/qla_edif.c | 1 +

> >>>    drivers/scsi/qla2xxx/qla_isr.c  | 3 +--

> >>>    2 files changed, 2 insertions(+), 2 deletions(-)

> >>>

> >>> diff --git a/drivers/scsi/qla2xxx/qla_edif.c

> b/drivers/scsi/qla2xxx/qla_edif.c

> >>> index 8e730cc882e6..ccbe0e1bfcbc 100644

> >>> --- a/drivers/scsi/qla2xxx/qla_edif.c

> >>> +++ b/drivers/scsi/qla2xxx/qla_edif.c

> >>> @@ -2926,6 +2926,7 @@ qla28xx_start_scsi_edif(srb_t *sp)

> >>>    		req->ring_ptr++;

> >>>    	}

> >>>

> >>> +	sp->qpair->cmd_cnt++;

> >>>    	/* Set chip new ring index. */

> >>>    	wrt_reg_dword(req->req_q_in, req->ring_index);

> >>>

> >>> diff --git a/drivers/scsi/qla2xxx/qla_isr.c b/drivers/scsi/qla2xxx/qla_isr.c

> >>> index ce4f93fb4d25..e8928fd83049 100644

> >>> --- a/drivers/scsi/qla2xxx/qla_isr.c

> >>> +++ b/drivers/scsi/qla2xxx/qla_isr.c

> >>> @@ -3192,10 +3192,9 @@ qla2x00_status_entry(scsi_qla_host_t *vha,

> >> struct rsp_que *rsp, void *pkt)

> >>>    		return;

> >>>    	}

> >>>

> >>> -	sp->qpair->cmd_completion_cnt++;

> >>> -

> >>>    	/* Fast path completion. */

> >>>    	qla_chk_edif_rx_sa_delete_pending(vha, sp, sts24);

> >>> +	sp->qpair->cmd_completion_cnt++;

> >>>

> >>>    	if (comp_status == CS_COMPLETE && scsi_status == 0) {

> >>>    		qla2x00_process_completed_request(vha, req, handle);

> >>>

> >>

> >> --

> >> Himanshu Madhani                                Oracle Linux Engineering

> 

> --

> Himanshu Madhani                                Oracle Linux Engineering