linux-yocto/drivers/scsi/lpfc
Daniel Wagner 34c0a67055 scsi: lpfc: Use memcpy() for BIOS version
[ Upstream commit ae82eaf4ae ]

The strlcat() with FORTIFY support is triggering a panic because it
thinks the target buffer will overflow although the correct target
buffer size is passed in.

Anyway, instead of memset() with 0 followed by a strlcat(), just use
memcpy() and ensure that the resulting buffer is NULL terminated.

BIOSVersion is only used for the lpfc_printf_log() which expects a
properly terminated string.

Signed-off-by: Daniel Wagner <wagi@kernel.org>
Link: https://lore.kernel.org/r/20250409-fix-lpfc-bios-str-v1-1-05dac9e51e13@kernel.org
Reviewed-by: Justin Tee <justin.tee@broadcom.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2025-06-27 11:08:56 +01:00
..
lpfc_attr.c
lpfc_attr.h
lpfc_bsg.c
lpfc_bsg.h
lpfc_compat.h
lpfc_crtn.h
lpfc_ct.c
lpfc_debugfs.c
lpfc_debugfs.h
lpfc_disc.h
lpfc_els.c
lpfc_hbadisc.c scsi: lpfc: Fix lpfc_check_sli_ndlp() handling for GEN_REQUEST64 commands 2025-06-27 11:08:55 +01:00
lpfc_hw.h
lpfc_hw4.h
lpfc_ids.h
lpfc_init.c
lpfc_logmsg.h
lpfc_mbox.c
lpfc_mem.c
lpfc_nl.h
lpfc_nportdisc.c
lpfc_nvme.c
lpfc_nvme.h
lpfc_nvmet.c
lpfc_scsi.c
lpfc_scsi.h
lpfc_sli.c scsi: lpfc: Use memcpy() for BIOS version 2025-06-27 11:08:56 +01:00
lpfc_sli.h
lpfc_sli4.h
lpfc_version.h
lpfc_vmid.c
lpfc_vport.c
lpfc_vport.h
lpfc.h
Makefile