* [PATCH] scsi: qla2xxx: Use PTR_ERR_OR_ZERO
@ 2017-08-29 13:50 Himanshu Jha
0 siblings, 0 replies; only message in thread
From: Himanshu Jha @ 2017-08-29 13:50 UTC (permalink / raw)
To: jejb
Cc: martin.petersen, qla2xxx-upstream, linux-scsi, linux-kernel,
Himanshu Jha
Use PTR_ERR_OR_ZERO rather than if(IS_ERR(...)) + PTR_ERR
Signed-off-by: Himanshu Jha <himanshujha199640@gmail.com>
---
drivers/scsi/qla2xxx/tcm_qla2xxx.c | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/drivers/scsi/qla2xxx/tcm_qla2xxx.c b/drivers/scsi/qla2xxx/tcm_qla2xxx.c
index 3f82ea1..bf33350 100644
--- a/drivers/scsi/qla2xxx/tcm_qla2xxx.c
+++ b/drivers/scsi/qla2xxx/tcm_qla2xxx.c
@@ -1522,10 +1522,7 @@ static int tcm_qla2xxx_check_initiator_node_acl(
sizeof(struct qla_tgt_cmd),
TARGET_PROT_ALL, port_name,
qlat_sess, tcm_qla2xxx_session_cb);
- if (IS_ERR(se_sess))
- return PTR_ERR(se_sess);
-
- return 0;
+ return PTR_ERR_OR_ZERO(se_sess);
}
static void tcm_qla2xxx_update_sess(struct fc_port *sess, port_id_t s_id,
--
2.7.4
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2017-08-29 13:50 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-08-29 13:50 [PATCH] scsi: qla2xxx: Use PTR_ERR_OR_ZERO Himanshu Jha
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.