diff mbox series

scsi: qla4xxx: Fix Fix inconsistent of format with argument type in ql4_nx.c

Message ID 20200930022228.2840587-1-yebin10@huawei.com (mailing list archive)
State Accepted
Headers show
Series scsi: qla4xxx: Fix Fix inconsistent of format with argument type in ql4_nx.c | expand

Commit Message

yebin (H) Sept. 30, 2020, 2:22 a.m. UTC
Fix follow warning:
[drivers/scsi/qla4xxx/ql4_nx.c:3228]: (warning) %ld in format string (no. 1)
	requires 'long' but the argument type is 'unsigned long'.

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Ye Bin <yebin10@huawei.com>
---
 drivers/scsi/qla4xxx/ql4_nx.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Martin K. Petersen Oct. 8, 2020, 3:07 a.m. UTC | #1
Ye,

> Fix follow warning:
> [drivers/scsi/qla4xxx/ql4_nx.c:3228]: (warning) %ld in format string (no. 1)
> 	requires 'long' but the argument type is 'unsigned long'.

Applied to 5.10/scsi-staging, thanks!
Martin K. Petersen Oct. 13, 2020, 10:43 p.m. UTC | #2
On Wed, 30 Sep 2020 10:22:28 +0800, Ye Bin wrote:

> Fix follow warning:
> [drivers/scsi/qla4xxx/ql4_nx.c:3228]: (warning) %ld in format string (no. 1)
> 	requires 'long' but the argument type is 'unsigned long'.

Applied to 5.10/scsi-queue, thanks!

[1/1] scsi: qla4xxx: Fix inconsistent format argument type
      https://git.kernel.org/mkp/scsi/c/5ccdd101351d
diff mbox series

Patch

diff --git a/drivers/scsi/qla4xxx/ql4_nx.c b/drivers/scsi/qla4xxx/ql4_nx.c
index fd3aabb6a190..f1767b21076f 100644
--- a/drivers/scsi/qla4xxx/ql4_nx.c
+++ b/drivers/scsi/qla4xxx/ql4_nx.c
@@ -3225,7 +3225,7 @@  static void qla4_8xxx_uevent_emit(struct scsi_qla_host *ha, u32 code)
 
 	switch (code) {
 	case QL4_UEVENT_CODE_FW_DUMP:
-		snprintf(event_string, sizeof(event_string), "FW_DUMP=%ld",
+		snprintf(event_string, sizeof(event_string), "FW_DUMP=%lu",
 			 ha->host_no);
 		break;
 	default: