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

scsi: mpt3sas: Replace dynamic allocations with local variables



mpt3sas_scsih.c:_scsih_scan_for_devices_after_reset() allocates and fetches
a MPI2_CONFIG_PAGE_RAID_VOL_0 struct (Mpi2RaidVolPage0_t) and a
MPI2_CONFIG_PAGE_RAID_VOL_1 struct (Mpi2RaidVolPage1_t), but does not
include the terminal flexible array members in the struct size
calculations, fetch those members, or otherwise use those members in any
way.

These dynamic allocations can be replaced with local variables.

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


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