]> www.infradead.org Git - users/jedix/linux-maple.git/commit
drm/amdgpu: Add basic validation for RAS header
authorLijo Lazar <lijo.lazar@amd.com>
Wed, 26 Mar 2025 07:58:38 +0000 (13:28 +0530)
committerAlex Deucher <alexander.deucher@amd.com>
Mon, 7 Apr 2025 19:18:59 +0000 (15:18 -0400)
commit5df0d6addb7e9b6f71f7162d1253762a5be9138e
tree9e69991b1528d75061678eaa103174af4f22783f
parentdaafa303d19f5522e4c24fbf5c1c981a16df2c2f
drm/amdgpu: Add basic validation for RAS header

If RAS header read from EEPROM is corrupted, it could result in trying
to allocate huge memory for reading the records. Add some validation to
header fields.

Signed-off-by: Lijo Lazar <lijo.lazar@amd.com>
Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_ras_eeprom.c