scsi: lpfc: Use correct scnprintf() limit
authorDan Carpenter <dan.carpenter@oracle.com>
Thu, 16 Sep 2021 13:23:31 +0000 (16:23 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 30 Sep 2021 08:11:04 +0000 (10:11 +0200)
commit0595fc4794c3b0ac9c88d7c609d66c71ba9811b5
treee0196d548021d46252350676c0e3f0009799d29f
parentcb948b158a868a5c46b40e95ffafecf1eb82b589
scsi: lpfc: Use correct scnprintf() limit

[ Upstream commit 6dacc371b77f473770ec646e220303a84fe96c11 ]

The limit should be "PAGE_SIZE - len" instead of "PAGE_SIZE".  We're not
going to hit the limit so this fix will not affect runtime.

Link: https://lore.kernel.org/r/20210916132331.GE25094@kili
Fixes: 5b9e70b22cc5 ("scsi: lpfc: raise sg count for nvme to use available sg resources")
Reviewed-by: James Smart <jsmart2021@gmail.com>
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/scsi/lpfc/lpfc_attr.c