Message ID | 20200313085001.3781-1-njavali@marvell.com (mailing list archive) |
---|---|
State | Mainlined |
Commit | 78c3e5e6cde8193467427ed9e5f90a0d585625a1 |
Headers | show |
Series | qla2xxx: Fix I/Os being passed down when FC device is being deleted. | expand |
On Fri, 2020-03-13 at 01:50 -0700, Nilesh Javali wrote: > From: Arun Easi <aeasi@marvell.com> > > I/Os could be passed down while the device FC SCSI device is being > deleted. > This would result in unnecessary delay of I/O and driver messages > (when > extended logging is set). > > Signed-off-by: Arun Easi <aeasi@marvell.com> > --- > drivers/scsi/qla2xxx/qla_os.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/drivers/scsi/qla2xxx/qla_os.c > b/drivers/scsi/qla2xxx/qla_os.c > index b520a98..7a94e11 100644 > --- a/drivers/scsi/qla2xxx/qla_os.c > +++ b/drivers/scsi/qla2xxx/qla_os.c > @@ -864,7 +864,7 @@ void qla2xxx_qpair_sp_compl(srb_t *sp, int res) > goto qc24_fail_command; > } > > - if (atomic_read(&fcport->state) != FCS_ONLINE) { > + if (atomic_read(&fcport->state) != FCS_ONLINE || fcport- > >deleted) { > if (atomic_read(&fcport->state) == FCS_DEVICE_DEAD || > atomic_read(&base_vha->loop_state) == > LOOP_DEAD) { > ql_dbg(ql_dbg_io, vha, 0x3005, > @@ -946,7 +946,7 @@ void qla2xxx_qpair_sp_compl(srb_t *sp, int res) > goto qc24_fail_command; > } > > - if (atomic_read(&fcport->state) != FCS_ONLINE) { > + if (atomic_read(&fcport->state) != FCS_ONLINE || fcport- > >deleted) { > if (atomic_read(&fcport->state) == FCS_DEVICE_DEAD || > atomic_read(&base_vha->loop_state) == > LOOP_DEAD) { > ql_dbg(ql_dbg_io, vha, 0x3077, Tested-by: Laurence Oberman <loberman@redhat.com> Reviewed-by: Laurence Oberman <loberman@redhat.com> Built and tested in Red Hat CEE lab with fault injection.
On Fri, 2020-03-13 at 01:50 -0700, Nilesh Javali wrote: > From: Arun Easi <aeasi@marvell.com> > > I/Os could be passed down while the device FC SCSI device is being deleted. > This would result in unnecessary delay of I/O and driver messages (when > extended logging is set). > > Signed-off-by: Arun Easi <aeasi@marvell.com> > --- > drivers/scsi/qla2xxx/qla_os.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/drivers/scsi/qla2xxx/qla_os.c b/drivers/scsi/qla2xxx/qla_os.c > index b520a98..7a94e11 100644 > --- a/drivers/scsi/qla2xxx/qla_os.c > +++ b/drivers/scsi/qla2xxx/qla_os.c > @@ -864,7 +864,7 @@ void qla2xxx_qpair_sp_compl(srb_t *sp, int res) > goto qc24_fail_command; > } > > - if (atomic_read(&fcport->state) != FCS_ONLINE) { > + if (atomic_read(&fcport->state) != FCS_ONLINE || fcport->deleted) { > if (atomic_read(&fcport->state) == FCS_DEVICE_DEAD || > atomic_read(&base_vha->loop_state) == LOOP_DEAD) { > ql_dbg(ql_dbg_io, vha, 0x3005, > @@ -946,7 +946,7 @@ void qla2xxx_qpair_sp_compl(srb_t *sp, int res) > goto qc24_fail_command; > } > > - if (atomic_read(&fcport->state) != FCS_ONLINE) { > + if (atomic_read(&fcport->state) != FCS_ONLINE || fcport->deleted) { > if (atomic_read(&fcport->state) == FCS_DEVICE_DEAD || > atomic_read(&base_vha->loop_state) == LOOP_DEAD) { > ql_dbg(ql_dbg_io, vha, 0x3077, This fixes an easily reproducible problem and should be considered for -stable. It generally happens with extended driver logging enabled though. Fixes: a8a12eb1920c ("scsi: qla2xxx: Remove defer flag to indicate immeadiate port loss") Reviewed-by: Ewan D. Milne <emilne@redhat.com>
On 2020-03-13 07:09, Ewan D. Milne wrote: > On Fri, 2020-03-13 at 01:50 -0700, Nilesh Javali wrote: >> From: Arun Easi <aeasi@marvell.com> >> >> I/Os could be passed down while the device FC SCSI device is being deleted. >> This would result in unnecessary delay of I/O and driver messages (when >> extended logging is set). >> >> Signed-off-by: Arun Easi <aeasi@marvell.com> >> --- >> drivers/scsi/qla2xxx/qla_os.c | 4 ++-- >> 1 file changed, 2 insertions(+), 2 deletions(-) >> >> diff --git a/drivers/scsi/qla2xxx/qla_os.c b/drivers/scsi/qla2xxx/qla_os.c >> index b520a98..7a94e11 100644 >> --- a/drivers/scsi/qla2xxx/qla_os.c >> +++ b/drivers/scsi/qla2xxx/qla_os.c >> @@ -864,7 +864,7 @@ void qla2xxx_qpair_sp_compl(srb_t *sp, int res) >> goto qc24_fail_command; >> } >> >> - if (atomic_read(&fcport->state) != FCS_ONLINE) { >> + if (atomic_read(&fcport->state) != FCS_ONLINE || fcport->deleted) { >> if (atomic_read(&fcport->state) == FCS_DEVICE_DEAD || >> atomic_read(&base_vha->loop_state) == LOOP_DEAD) { >> ql_dbg(ql_dbg_io, vha, 0x3005, >> @@ -946,7 +946,7 @@ void qla2xxx_qpair_sp_compl(srb_t *sp, int res) >> goto qc24_fail_command; >> } >> >> - if (atomic_read(&fcport->state) != FCS_ONLINE) { >> + if (atomic_read(&fcport->state) != FCS_ONLINE || fcport->deleted) { >> if (atomic_read(&fcport->state) == FCS_DEVICE_DEAD || >> atomic_read(&base_vha->loop_state) == LOOP_DEAD) { >> ql_dbg(ql_dbg_io, vha, 0x3077, > > This fixes an easily reproducible problem and should > be considered for -stable. It generally happens with > extended driver logging enabled though. > > Fixes: a8a12eb1920c ("scsi: qla2xxx: Remove defer flag to indicate immeadiate port loss") > Reviewed-by: Ewan D. Milne <emilne@redhat.com> Hi Ewan, That commit ID does not exist. Did you perhaps want to refer to 3c75ad1d87c7 ("scsi: qla2xxx: Remove defer flag to indicate immeadiate port loss") # v5.6-rc1? Thanks, Bart.
On Fri, 2020-03-13 at 07:44 -0700, Bart Van Assche wrote: > On 2020-03-13 07:09, Ewan D. Milne wrote: > > On Fri, 2020-03-13 at 01:50 -0700, Nilesh Javali wrote: > > > From: Arun Easi <aeasi@marvell.com> > > > > > > I/Os could be passed down while the device FC SCSI device is being deleted. > > > This would result in unnecessary delay of I/O and driver messages (when > > > extended logging is set). > > > > > > Signed-off-by: Arun Easi <aeasi@marvell.com> > > > --- > > > drivers/scsi/qla2xxx/qla_os.c | 4 ++-- > > > 1 file changed, 2 insertions(+), 2 deletions(-) > > > > > > diff --git a/drivers/scsi/qla2xxx/qla_os.c b/drivers/scsi/qla2xxx/qla_os.c > > > index b520a98..7a94e11 100644 > > > --- a/drivers/scsi/qla2xxx/qla_os.c > > > +++ b/drivers/scsi/qla2xxx/qla_os.c > > > @@ -864,7 +864,7 @@ void qla2xxx_qpair_sp_compl(srb_t *sp, int res) > > > goto qc24_fail_command; > > > } > > > > > > - if (atomic_read(&fcport->state) != FCS_ONLINE) { > > > + if (atomic_read(&fcport->state) != FCS_ONLINE || fcport->deleted) { > > > if (atomic_read(&fcport->state) == FCS_DEVICE_DEAD || > > > atomic_read(&base_vha->loop_state) == LOOP_DEAD) { > > > ql_dbg(ql_dbg_io, vha, 0x3005, > > > @@ -946,7 +946,7 @@ void qla2xxx_qpair_sp_compl(srb_t *sp, int res) > > > goto qc24_fail_command; > > > } > > > > > > - if (atomic_read(&fcport->state) != FCS_ONLINE) { > > > + if (atomic_read(&fcport->state) != FCS_ONLINE || fcport->deleted) { > > > if (atomic_read(&fcport->state) == FCS_DEVICE_DEAD || > > > atomic_read(&base_vha->loop_state) == LOOP_DEAD) { > > > ql_dbg(ql_dbg_io, vha, 0x3077, > > > > This fixes an easily reproducible problem and should > > be considered for -stable. It generally happens with > > extended driver logging enabled though. > > > > Fixes: a8a12eb1920c ("scsi: qla2xxx: Remove defer flag to indicate immeadiate port loss") > > Reviewed-by: Ewan D. Milne <emilne@redhat.com> > > Hi Ewan, > > That commit ID does not exist. Did you perhaps want to refer to > 3c75ad1d87c7 ("scsi: qla2xxx: Remove defer flag to indicate immeadiate > port loss") # v5.6-rc1? > > Thanks, > > Bart. Yes, that's the one. Sorry, I can't figure out how I managed to copy that ID. It's not a commit in any tree I use. Thanks. -Ewan
On Fri, Mar 13, 2020 at 01:50:01AM -0700, Nilesh Javali wrote: > From: Arun Easi <aeasi@marvell.com> > > I/Os could be passed down while the device FC SCSI device is being deleted. > This would result in unnecessary delay of I/O and driver messages (when > extended logging is set). > > Signed-off-by: Arun Easi <aeasi@marvell.com> > --- > drivers/scsi/qla2xxx/qla_os.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > Hi Nilesh, Arun, Reviewed-by: Roman Bolshakov <r.bolshakov@yadro.com> Thanks, Roman
On 3/16/2020 1:38 PM, Roman Bolshakov wrote: > On Fri, Mar 13, 2020 at 01:50:01AM -0700, Nilesh Javali wrote: >> From: Arun Easi <aeasi@marvell.com> >> >> I/Os could be passed down while the device FC SCSI device is being deleted. >> This would result in unnecessary delay of I/O and driver messages (when >> extended logging is set). >> >> Signed-off-by: Arun Easi <aeasi@marvell.com> >> --- >> drivers/scsi/qla2xxx/qla_os.c | 4 ++-- >> 1 file changed, 2 insertions(+), 2 deletions(-) >> > > Hi Nilesh, Arun, > > Reviewed-by: Roman Bolshakov <r.bolshakov@yadro.com> > > Thanks, > Roman > Thanks Arun. FWIW, I remember this change :) Reviewed-by: Himanshu Madhani <himanshu.madhani@oracle.com>
Nilesh, > I/Os could be passed down while the device FC SCSI device is being > deleted. This would result in unnecessary delay of I/O and driver > messages (when extended logging is set). Applied to 5.6/scsi-fixes. I corrected the Fixes: commit hash and added your SoB which was missing.
On Tue, 17 Mar 2020, 7:16am, Himanshu Madhani wrote: > On 3/16/2020 1:38 PM, Roman Bolshakov wrote: > > On Fri, Mar 13, 2020 at 01:50:01AM -0700, Nilesh Javali wrote: > > > From: Arun Easi <aeasi@marvell.com> > > > > > > I/Os could be passed down while the device FC SCSI device is being > > > deleted. > > > This would result in unnecessary delay of I/O and driver messages (when > > > extended logging is set). > > > > > > Signed-off-by: Arun Easi <aeasi@marvell.com> > > > --- > > > drivers/scsi/qla2xxx/qla_os.c | 4 ++-- > > > 1 file changed, 2 insertions(+), 2 deletions(-) > > > > > > > Hi Nilesh, Arun, > > > > Reviewed-by: Roman Bolshakov <r.bolshakov@yadro.com> > > > > Thanks, > > Roman Thanks Roman. > > > > Thanks Arun. FWIW, I remember this change :) :) Yep, glad to see you back here, and thanks for the review, Himanshu. Regards, -Arun > > Reviewed-by: Himanshu Madhani <himanshu.madhani@oracle.com> > >
diff --git a/drivers/scsi/qla2xxx/qla_os.c b/drivers/scsi/qla2xxx/qla_os.c index b520a98..7a94e11 100644 --- a/drivers/scsi/qla2xxx/qla_os.c +++ b/drivers/scsi/qla2xxx/qla_os.c @@ -864,7 +864,7 @@ void qla2xxx_qpair_sp_compl(srb_t *sp, int res) goto qc24_fail_command; } - if (atomic_read(&fcport->state) != FCS_ONLINE) { + if (atomic_read(&fcport->state) != FCS_ONLINE || fcport->deleted) { if (atomic_read(&fcport->state) == FCS_DEVICE_DEAD || atomic_read(&base_vha->loop_state) == LOOP_DEAD) { ql_dbg(ql_dbg_io, vha, 0x3005, @@ -946,7 +946,7 @@ void qla2xxx_qpair_sp_compl(srb_t *sp, int res) goto qc24_fail_command; } - if (atomic_read(&fcport->state) != FCS_ONLINE) { + if (atomic_read(&fcport->state) != FCS_ONLINE || fcport->deleted) { if (atomic_read(&fcport->state) == FCS_DEVICE_DEAD || atomic_read(&base_vha->loop_state) == LOOP_DEAD) { ql_dbg(ql_dbg_io, vha, 0x3077,