android_kernel_samsung_sm8650/drivers/scsi/lpfc
Justin Tee 04dcef4a78 scsi: lpfc: Fix possible file string name overflow when updating firmware
[ Upstream commit f5779b529240b715f0e358489ad0ed933bf77c97 ]

Because file_name and phba->ModelName are both declared a size 80 bytes,
the extra ".grp" file extension could cause an overflow into file_name.

Define a ELX_FW_NAME_SIZE macro with value 84.  84 incorporates the 4 extra
characters from ".grp".  file_name is changed to be declared as a char and
initialized to zeros i.e. null chars.

Signed-off-by: Justin Tee <justin.tee@broadcom.com>
Link: https://lore.kernel.org/r/20231031191224.150862-3-justintee8345@gmail.com
Reviewed-by: Himanshu Madhani <himanshu.madhani@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-02-05 20:12:50 +00:00
..
lpfc_attr.c scsi: lpfc: Remove SANDiags related code 2022-08-31 23:39:58 -04:00
lpfc_attr.h
lpfc_bsg.c scsi: lpfc: Fix incorrect big endian type assignment in bsg loopback path 2023-09-13 09:42:25 +02:00
lpfc_bsg.h
lpfc_compat.h
lpfc_crtn.h scsi: lpfc: Fix double free in lpfc_cmpl_els_logo_acc() caused by lpfc_nlp_not_used() 2023-07-23 13:49:38 +02:00
lpfc_ct.c scsi: lpfc: Fix spelling mistake "unsolicted" -> "unsolicited" 2022-10-01 05:56:24 -04:00
lpfc_debugfs.c scsi: lpfc: Fix the NULL vs IS_ERR() bug for debugfs_create_file() 2023-09-23 11:11:09 +02:00
lpfc_debugfs.h scsi: lpfc: Copyright updates for 14.2.0.6 patches 2022-08-31 23:39:58 -04:00
lpfc_disc.h scsi: lpfc: Fix multiple NVMe remoteport registration calls for the same NPort ID 2022-09-15 22:18:27 -04:00
lpfc_els.c scsi: lpfc: Abort outstanding ELS cmds when mailbox timeout error is detected 2023-09-23 11:11:06 +02:00
lpfc_hbadisc.c scsi: lpfc: Fix double free in lpfc_cmpl_els_logo_acc() caused by lpfc_nlp_not_used() 2023-07-23 13:49:38 +02:00
lpfc_hw4.h scsi: lpfc: Add reporting capability for Link Degrade Signaling 2022-09-15 22:18:27 -04:00
lpfc_hw.h scsi: lpfc: Rework FDMI attribute registration for unintential padding 2022-09-15 22:18:27 -04:00
lpfc_ids.h
lpfc_init.c scsi: lpfc: Fix possible file string name overflow when updating firmware 2024-02-05 20:12:50 +00:00
lpfc_logmsg.h scsi: lpfc: Add reporting capability for Link Degrade Signaling 2022-09-15 22:18:27 -04:00
lpfc_mbox.c
lpfc_mem.c scsi: lpfc: Copyright updates for 14.2.0.6 patches 2022-08-31 23:39:58 -04:00
lpfc_nl.h
lpfc_nportdisc.c
lpfc_nvme.c
lpfc_nvme.h
lpfc_nvmet.c
lpfc_scsi.c scsi: lpfc: Remove reftag check in DIF paths 2023-09-13 09:42:24 +02:00
lpfc_scsi.h scsi: lpfc: Copyright updates for 14.2.0.6 patches 2022-08-31 23:39:58 -04:00
lpfc_sli4.h scsi: lpfc: Fix various issues reported by tools 2022-09-15 22:18:28 -04:00
lpfc_sli.c scsi: lpfc: Abort outstanding ELS cmds when mailbox timeout error is detected 2023-09-23 11:11:06 +02:00
lpfc_sli.h
lpfc_version.h scsi: lpfc: Update lpfc version to 14.2.0.7 2022-09-15 22:18:28 -04:00
lpfc_vmid.c scsi: lpfc: Fix various issues reported by tools 2022-09-15 22:18:28 -04:00
lpfc_vport.c scsi: lpfc: Remove SANDiags related code 2022-08-31 23:39:58 -04:00
lpfc_vport.h scsi: lpfc: Copyright updates for 14.2.0.6 patches 2022-08-31 23:39:58 -04:00
lpfc.h scsi: lpfc: Fix possible file string name overflow when updating firmware 2024-02-05 20:12:50 +00:00
Makefile