From 8a1484e134b1b548d46097dc3da861445b5c5d6e Mon Sep 17 00:00:00 2001 From: Alex Deucher Date: Mon, 15 Jun 2026 19:33:49 -0400 Subject: [PATCH] drm/amdgpu/psp13.0.4: replace BUG() with an error There's no need to crash the kernel for this case. Reviewed-by: Kent Russell Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/psp_v13_0_4.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/psp_v13_0_4.c b/drivers/gpu/drm/amd/amdgpu/psp_v13_0_4.c index 3d5e26b3fa00..e1acdbe01833 100644 --- a/drivers/gpu/drm/amd/amdgpu/psp_v13_0_4.c +++ b/drivers/gpu/drm/amd/amdgpu/psp_v13_0_4.c @@ -50,7 +50,9 @@ static int psp_v13_0_4_init_microcode(struct psp_context *psp) return err; break; default: - BUG(); + dev_warn(adev->dev, "Unsupported MP0 version 0x%08x\n", + amdgpu_ip_version(adev, MP0_HWIP, 0)); + return -EINVAL; } return 0;