drm/amdgpu: Add NULL check for asic_funcs
authorLijo Lazar <lijo.lazar@amd.com>
Fri, 18 Jul 2025 03:55:21 +0000 (09:25 +0530)
committerAlex Deucher <alexander.deucher@amd.com>
Mon, 4 Aug 2025 19:47:50 +0000 (15:47 -0400)
commitc2fe914d50ab22defca14ac6fca33888bfb19843
tree6251552d204e67e340e5086843bebcd6633988cc
parent8e6a18cbf3ee2c1e3d0afd8d3debd0ba8738ad0c
drm/amdgpu: Add NULL check for asic_funcs

If driver load fails too early, asic_funcs pointer remains unassigned.
Add NULL check to sanitize unwind path.

Signed-off-by: Lijo Lazar <lijo.lazar@amd.com>
Acked-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
(cherry picked from commit 582bf7c5158dce16f7dc5b8345b7876bd8031224)
Cc: stable@vger.kernel.org
drivers/gpu/drm/amd/amdgpu/amdgpu_nbio.c