All of lore.kernel.org
 help / color / mirror / Atom feed
From: Kunwu Chan <chentao@kylinos.cn>
To: njavali@marvell.com, mrangankar@marvell.com,
	GR-QLogic-Storage-Upstream@marvell.com, jejb@linux.ibm.com,
	martin.petersen@oracle.com
Cc: linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org,
	kunwu.chan@hotmail.com, Kunwu Chan <chentao@kylinos.cn>,
	stable@vger.kernel.org, kernel test robot <lkp@intel.com>
Subject: [PATCH] scsi: qedi: Fix an endian bug in qedi_ring_doorbell
Date: Fri, 17 Nov 2023 16:01:51 +0800	[thread overview]
Message-ID: <20231117080151.1825970-1-chentao@kylinos.cn> (raw)

drivers/scsi/qedi/qedi_fw.c:932:40: sparse: sparse: incorrect type in
assignment (different base types) expected restricted __le16
[usertype] sq_prod got unsigned short [usertype] fw_sq_prod_idx

Cc: stable@vger.kernel.org
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/r/202311161351.7sPcpket-lkp@intel.com/
Signed-off-by: Kunwu Chan <chentao@kylinos.cn>
---
 drivers/scsi/qedi/qedi_fw.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/scsi/qedi/qedi_fw.c b/drivers/scsi/qedi/qedi_fw.c
index 6901738324da..72da9dce4e6f 100644
--- a/drivers/scsi/qedi/qedi_fw.c
+++ b/drivers/scsi/qedi/qedi_fw.c
@@ -922,7 +922,7 @@ void qedi_fp_process_cqes(struct qedi_work *work)
 
 static void qedi_ring_doorbell(struct qedi_conn *qedi_conn)
 {
-	qedi_conn->ep->db_data.sq_prod = qedi_conn->ep->fw_sq_prod_idx;
+	qedi_conn->ep->db_data.sq_prod = cpu_to_le16(qedi_conn->ep->fw_sq_prod_idx);
 
 	/* wmb - Make sure fw idx is coherent */
 	wmb();
-- 
2.34.1


                 reply	other threads:[~2023-11-17  8:02 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=20231117080151.1825970-1-chentao@kylinos.cn \
    --to=chentao@kylinos.cn \
    --cc=GR-QLogic-Storage-Upstream@marvell.com \
    --cc=jejb@linux.ibm.com \
    --cc=kunwu.chan@hotmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=lkp@intel.com \
    --cc=martin.petersen@oracle.com \
    --cc=mrangankar@marvell.com \
    --cc=njavali@marvell.com \
    --cc=stable@vger.kernel.org \
    /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.