All of lore.kernel.org
 help / color / mirror / Atom feed
From: Hannes Reinecke <hare@suse.de>
To: Muneendra <muneendra.kumar@broadcom.com>, linux-scsi@vger.kernel.org
Cc: jsmart2021@gmail.com, emilne@redhat.com, mkumar@redhat.com
Subject: Re: [PATCH v2 3/8] scsi: Clear state bit SCMD_NORETRIES_ABORT of scsi_cmd before start request
Date: Wed, 30 Sep 2020 11:19:04 +0200	[thread overview]
Message-ID: <75ff05b1-be57-038a-427c-dd0a8719e20d@suse.de> (raw)
In-Reply-To: <1601268657-940-4-git-send-email-muneendra.kumar@broadcom.com>

On 9/28/20 6:50 AM, Muneendra wrote:
> Clearing the SCMD_NORETRIES_ABORT bit in state flag before
> blk_mq_start_request.
> 
> Added a code in scsi_result_to_blk_status to translate
> a new error DID_TRANSPORT_MARGINAL to the corresponding blk_status_t
> i.e BLK_STS_TRANSPORT
> 
> Signed-off-by: Muneendra <muneendra.kumar@broadcom.com>
> 
> ---
> v2:
> Made changes in scsi_result_to_blk_status to support DID_TRANSPORT_MARGINAL
> ---
>   drivers/scsi/scsi_lib.c | 2 ++
>   1 file changed, 2 insertions(+)
> 
> diff --git a/drivers/scsi/scsi_lib.c b/drivers/scsi/scsi_lib.c
> index f0ee11dc07e4..da95ae8b572f 100644
> --- a/drivers/scsi/scsi_lib.c
> +++ b/drivers/scsi/scsi_lib.c
> @@ -643,6 +643,7 @@ static blk_status_t scsi_result_to_blk_status(struct scsi_cmnd *cmd, int result)
>   			return BLK_STS_OK;
>   		return BLK_STS_IOERR;
>   	case DID_TRANSPORT_FAILFAST:
> +	case DID_TRANSPORT_MARGINAL:
>   		return BLK_STS_TRANSPORT;
>   	case DID_TARGET_FAILURE:
>   		set_host_byte(cmd, DID_OK);
> @@ -1689,6 +1690,7 @@ static blk_status_t scsi_queue_rq(struct blk_mq_hw_ctx *hctx,
>   		req->rq_flags |= RQF_DONTPREP;
>   	} else {
>   		clear_bit(SCMD_STATE_COMPLETE, &cmd->state);
> +		clear_bit(SCMD_NORETRIES_ABORT, &cmd->state);
>   		blk_mq_start_request(req);
>   	}
>   
> 
Please split off this patch and merge the first part with the next 
patch, and the second hunk with the previous one.

Cheers,

Hannes
-- 
Dr. Hannes Reinecke		           Kernel Storage Architect
hare@suse.de			                  +49 911 74053 688
SUSE Software Solutions Germany GmbH, Maxfeldstr. 5, 90409 Nürnberg
HRB 36809 (AG Nürnberg), GF: Felix Imendörffer

  reply	other threads:[~2020-09-30  9:19 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-09-28  4:50 [PATCH v2 0/8] scsi: Support to handle Intermittent errors Muneendra
2020-09-28  4:50 ` [PATCH v2 1/8] scsi: Added a new definition in scsi_cmnd.h Muneendra
2020-09-30  9:17   ` Hannes Reinecke
2020-09-28  4:50 ` [PATCH v2 2/8] scsi: Added a new error code in scsi.h Muneendra
2020-09-30  9:17   ` Hannes Reinecke
2020-09-28  4:50 ` [PATCH v2 3/8] scsi: Clear state bit SCMD_NORETRIES_ABORT of scsi_cmd before start request Muneendra
2020-09-30  9:19   ` Hannes Reinecke [this message]
2020-09-28  4:50 ` [PATCH v2 4/8] scsi: No retries on abort success Muneendra
2020-09-30  9:27   ` Hannes Reinecke
2020-09-28  4:50 ` [PATCH v2 5/8] scsi: Added routine to set/clear SCMD_NORETRIES_ABORT bit for outstanding io on scsi_dev Muneendra
2020-09-30  9:26   ` Hannes Reinecke
2020-09-28  4:50 ` [PATCH v2 6/8] scsi_transport_fc: Added a new rport state FC_PORTSTATE_MARGINAL Muneendra
2020-09-30  9:30   ` Hannes Reinecke
2020-09-28  4:50 ` [PATCH v2 7/8] scsi_transport_fc: Added a new sysfs attribute port_state Muneendra
2020-09-30  9:33   ` Hannes Reinecke
2020-10-01 13:13     ` Muneendra Kumar M
2020-10-05  9:18     ` Muneendra Kumar M
2020-10-05  9:29       ` Hannes Reinecke
2020-10-07  7:14         ` Muneendra Kumar M
2020-10-02 16:26   ` Benjamin Block
2020-10-05  6:49     ` Hannes Reinecke
2020-10-05  8:41       ` Benjamin Block
2020-09-28  4:50 ` [PATCH v2 8/8] lpfc: Added support to handle marginal state Muneendra
2020-09-30  9:36   ` Hannes Reinecke
2020-09-30 11:33     ` Muneendra Kumar M
2020-09-30 11:50       ` Hannes Reinecke
2020-10-01  8:59         ` Muneendra Kumar M
2020-10-02 17:01 ` [PATCH v2 0/8] scsi: Support to handle Intermittent errors Mike Christie
2020-10-02 17:27   ` James Smart

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=75ff05b1-be57-038a-427c-dd0a8719e20d@suse.de \
    --to=hare@suse.de \
    --cc=emilne@redhat.com \
    --cc=jsmart2021@gmail.com \
    --cc=linux-scsi@vger.kernel.org \
    --cc=mkumar@redhat.com \
    --cc=muneendra.kumar@broadcom.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.