[-next] IB/isert: Fix warning Comparison to bool
diff mbox series

Message ID 1604404674-32998-1-git-send-email-zou_wei@huawei.com
State Accepted
Commit f7a95c902b020c7fe6781f0814187c2e2266a689
Headers show
Series
  • [-next] IB/isert: Fix warning Comparison to bool
Related show

Commit Message

Zou Wei Nov. 3, 2020, 11:57 a.m. UTC
Fix below warning reported by coccicheck:

./ib_isert.c:1104:12-24: WARNING: Comparison to bool

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Zou Wei <zou_wei@huawei.com>
---
 drivers/infiniband/ulp/isert/ib_isert.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Sagi Grimberg Nov. 3, 2020, 8:19 p.m. UTC | #1
Reviewed-by: Sagi Grimberg <sagi@grimberg.me>
Jason Gunthorpe Nov. 12, 2020, 4:38 p.m. UTC | #2
On Tue, Nov 03, 2020 at 07:57:54PM +0800, Zou Wei wrote:
> Fix below warning reported by coccicheck:
> 
> ./ib_isert.c:1104:12-24: WARNING: Comparison to bool
> 
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Signed-off-by: Zou Wei <zou_wei@huawei.com>
> Reviewed-by: Sagi Grimberg <sagi@grimberg.me>
> ---
>  drivers/infiniband/ulp/isert/ib_isert.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Applied to for-next, thanks

Jason

Patch
diff mbox series

diff --git a/drivers/infiniband/ulp/isert/ib_isert.c b/drivers/infiniband/ulp/isert/ib_isert.c
index bd47894..e47cd02 100644
--- a/drivers/infiniband/ulp/isert/ib_isert.c
+++ b/drivers/infiniband/ulp/isert/ib_isert.c
@@ -1101,7 +1101,7 @@  isert_handle_scsi_cmd(struct isert_conn *isert_conn,
 sequence_cmd:
 	rc = iscsit_sequence_cmd(conn, cmd, buf, hdr->cmdsn);
 
-	if (!rc && dump_payload == false && unsol_data)
+	if (!rc && !dump_payload && unsol_data)
 		iscsit_set_unsolicited_dataout(cmd);
 	else if (dump_payload && imm_data)
 		target_put_sess_cmd(&cmd->se_cmd);