On 9/20/2021 2:56 AM, Arnd Bergmann wrote:
From: Arnd Bergmann <arnd@xxxxxxxx> I fixed a stringop-overread warning earlier this year, now a second copy of the original code was added and the warning came back: drivers/scsi/lpfc/lpfc_attr.c: In function 'lpfc_cmf_info_show': drivers/scsi/lpfc/lpfc_attr.c:289:25: error: 'strnlen' specified bound 4095 exceeds source size 24 [-Werror=stringop-overread] 289 | strnlen(LPFC_INFO_MORE_STR, PAGE_SIZE - 1), | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Fix it the same way as the other copy. Fixes: ada48ba70f6b ("scsi: lpfc: Fix gcc -Wstringop-overread warning") Fixes: 74a7baa2a3ee ("scsi: lpfc: Add cmf_info sysfs entry") Signed-off-by: Arnd Bergmann <arnd@xxxxxxxx> --- drivers/scsi/lpfc/lpfc_attr.c | 7 ++-----
Thank You Arnd. Looks good. Reviewed-by: James Smart <jsmart2021@xxxxxxxxx> -- james