Commit f4f76e14 authored by James Seo's avatar James Seo Committed by Martin K. Petersen
Browse files

scsi: mpt3sas: Use struct_size() for struct size calculations



After converting terminal variable arrays into flexible array members, use
the bounds-checking struct_size() helper when possible to avoid open-coded
arithmetic struct size calculations.

Signed-off-by: default avatarJames Seo <james@equiv.tech>
Link: https://lore.kernel.org/r/20230806170604.16143-8-james@equiv.tech


Tested-by: default avatarBorislav Petkov (AMD) <bp@alien8.de>
Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
parent 1f112660
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment