All of lore.kernel.org
 help / color / mirror / Atom feed
From: cgel.zte@gmail.com
To: mdr@sgi.com
Cc: jejb@linux.ibm.com, martin.petersen@oracle.com,
	linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org,
	Changcheng Deng <deng.changcheng@zte.com.cn>,
	Zeal Robot <zealci@zte.com.cn>
Subject: [PATCH] scsi: qla1280: Use bitwise instead of arithmetic operator for flags
Date: Wed, 24 Nov 2021 03:28:09 +0000	[thread overview]
Message-ID: <20211124032809.35693-1-deng.changcheng@zte.com.cn> (raw)

From: Changcheng Deng <deng.changcheng@zte.com.cn>

Fix the following coccicheck warnings:
./drivers/scsi/qla1280.c: 3719: sum of probable bitmasks, consider |

Reported-by: Zeal Robot <zealci@zte.com.cn>
Signed-off-by: Changcheng Deng <deng.changcheng@zte.com.cn>
---
 drivers/scsi/qla1280.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/scsi/qla1280.c b/drivers/scsi/qla1280.c
index 1dc56f4c89d8..1147a32ef488 100644
--- a/drivers/scsi/qla1280.c
+++ b/drivers/scsi/qla1280.c
@@ -3716,7 +3716,7 @@ qla1280_error_entry(struct scsi_qla_host *ha, struct response *pkt,
 		ha->outstanding_cmds[handle] = NULL;
 
 		/* Bad payload or header */
-		if (pkt->entry_status & (BIT_3 + BIT_2)) {
+		if (pkt->entry_status & (BIT_3 | BIT_2)) {
 			/* Bad payload or header, set error status. */
 			/* CMD_RESULT(sp->cmd) = CS_BAD_PAYLOAD; */
 			CMD_RESULT(sp->cmd) = DID_ERROR << 16;
-- 
2.25.1


                 reply	other threads:[~2021-11-24  3:28 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=20211124032809.35693-1-deng.changcheng@zte.com.cn \
    --to=cgel.zte@gmail.com \
    --cc=deng.changcheng@zte.com.cn \
    --cc=jejb@linux.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=martin.petersen@oracle.com \
    --cc=mdr@sgi.com \
    --cc=zealci@zte.com.cn \
    /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.