diff mbox series

[v2,1/3] scsi: Cleanup scsi_noretry_cmd()

Message ID 20200910074843.217661-2-damien.lemoal@wdc.com (mailing list archive)
State Accepted
Headers show
Series Improve error handling | expand

Commit Message

Damien Le Moal Sept. 10, 2020, 7:48 a.m. UTC
No need for else after return.

Signed-off-by: Damien Le Moal <damien.lemoal@wdc.com>
---
 drivers/scsi/scsi_error.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Johannes Thumshirn Sept. 10, 2020, 8:05 a.m. UTC | #1
Looks good,
Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Himanshu Madhani Sept. 10, 2020, 3:45 p.m. UTC | #2
> On Sep 10, 2020, at 2:48 AM, Damien Le Moal <Damien.LeMoal@wdc.com> wrote:
> 
> No need for else after return.
> 
> Signed-off-by: Damien Le Moal <damien.lemoal@wdc.com>
> ---
> drivers/scsi/scsi_error.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/scsi/scsi_error.c b/drivers/scsi/scsi_error.c
> index 927b1e641842..5f3726abed78 100644
> --- a/drivers/scsi/scsi_error.c
> +++ b/drivers/scsi/scsi_error.c
> @@ -1755,8 +1755,8 @@ int scsi_noretry_cmd(struct scsi_cmnd *scmd)
> 	if (scmd->request->cmd_flags & REQ_FAILFAST_DEV ||
> 	    blk_rq_is_passthrough(scmd->request))
> 		return 1;
> -	else
> -		return 0;
> +
> +	return 0;
> }
> 
> /**
> -- 
> 2.26.2
> 

Looks Good. 

Reviewed-by: Himanshu Madhani <himanshu.madhani@oracle.com>

--
Himanshu Madhani	 Oracle Linux Engineering
diff mbox series

Patch

diff --git a/drivers/scsi/scsi_error.c b/drivers/scsi/scsi_error.c
index 927b1e641842..5f3726abed78 100644
--- a/drivers/scsi/scsi_error.c
+++ b/drivers/scsi/scsi_error.c
@@ -1755,8 +1755,8 @@  int scsi_noretry_cmd(struct scsi_cmnd *scmd)
 	if (scmd->request->cmd_flags & REQ_FAILFAST_DEV ||
 	    blk_rq_is_passthrough(scmd->request))
 		return 1;
-	else
-		return 0;
+
+	return 0;
 }
 
 /**