#1063750 firmware-amd-graphics: System with AMD Ryzen 7 PRO 7840U laptop fails to suspend, error from amdgpu

#1063750#5
Date:
2024-02-12 02:15:20 UTC
From:
To:
Dear Maintainer,

My laptop, Lenovo ThinkPad P14s Gen 4 with AMD Ryzen 7 PRO 7840U w/
Radeon 780M Graphics SoC, fails to enter suspend.

When I try to suspend, in ~9/10 cases, the suspend "fails" and the
machine immediately resumes. I see the following logs at the end of the
suspend sequence:

Feb 11 20:29:52 f4 kernel: [drm:mes_v11_0_submit_pkt_and_poll_completion.constprop.0 [amdgpu]] *ERROR* MES failed to response msg=14
Feb 11 20:29:52 f4 kernel: [drm:amdgpu_mes_reg_write_reg_wait [amdgpu]] *ERROR* failed to reg_write_reg_wait

At boot I see the errors:

eb 11 20:27:36 f4 kernel: amdgpu 0000:64:00.0: firmware: failed to load amdgpu/gc_11_0_1_mes_2.bin (-2)
Feb 11 20:27:36 f4 kernel: firmware_class: See https://wiki.debian.org/Firmware for information about missing firmware
Feb 11 20:27:36 f4 kernel: amdgpu 0000:64:00.0: firmware: failed to load amdgpu/gc_11_0_1_mes_2.bin (-2)
Feb 11 20:27:36 f4 kernel: amdgpu 0000:64:00.0: Direct firmware load for amdgpu/gc_11_0_1_mes_2.bin failed with error -2

I installed all the firmware files from linux-firmware.git at commit
fbef4d38, regenerated the initramfs and rebooted. Suspend worked in 3/3
tries.

To narrow things down a bit, I tried to copy only the missing firmware
file (amdgpu/gc_11_0_1_mes_2.bin) from the tag of linux-firmware
matching the installed version of the firmware-amd-graphics package
(20230625). That got rid of the "failed to load" error message of course
but suspend still failed with the same error.

Then I copied only the firmware files which are loaded by the driver on
my machine according to the following logs:

Feb 11 20:52:28 f4 kernel: amdgpu 0000:64:00.0: firmware: direct-loading firmware amdgpu/psp_13_0_4_toc.bin
Feb 11 20:52:28 f4 kernel: amdgpu 0000:64:00.0: firmware: direct-loading firmware amdgpu/psp_13_0_4_ta.bin
Feb 11 20:52:28 f4 kernel: amdgpu 0000:64:00.0: firmware: direct-loading firmware amdgpu/dcn_3_1_4_dmcub.bin
Feb 11 20:52:28 f4 kernel: amdgpu 0000:64:00.0: firmware: direct-loading firmware amdgpu/gc_11_0_1_pfp.bin
Feb 11 20:52:28 f4 kernel: amdgpu 0000:64:00.0: firmware: direct-loading firmware amdgpu/gc_11_0_1_me.bin
Feb 11 20:52:28 f4 kernel: amdgpu 0000:64:00.0: firmware: direct-loading firmware amdgpu/gc_11_0_1_rlc.bin
Feb 11 20:52:28 f4 kernel: amdgpu 0000:64:00.0: firmware: direct-loading firmware amdgpu/gc_11_0_1_mec.bin
Feb 11 20:52:28 f4 kernel: amdgpu 0000:64:00.0: firmware: direct-loading firmware amdgpu/vcn_4_0_2.bin
Feb 11 20:52:28 f4 kernel: amdgpu 0000:64:00.0: firmware: direct-loading firmware amdgpu/gc_11_0_1_mes_2.bin
Feb 11 20:52:28 f4 kernel: amdgpu 0000:64:00.0: firmware: direct-loading firmware amdgpu/gc_11_0_1_mes1.bin
Feb 11 20:52:28 f4 kernel: amdgpu 0000:64:00.0: firmware: direct-loading firmware amdgpu/gc_11_0_1_imu.bin
Feb 11 20:52:28 f4 kernel: amdgpu 0000:64:00.0: firmware: direct-loading firmware amdgpu/sdma_6_0_1.bin

I copied the files from linux-firmware.git commit fbef4d38. Somewhat
surprisingly, the suspend problem still occurred. Is there another
related firmware file that gets loaded? I tested once more by installing
all the files from linux-firmware and confirmed that the suspend problem
does not occur.