drm/amdgpu: support RLCP firmware front door load
authorLikun Gao <Likun.Gao@amd.com>
Mon, 11 Apr 2022 21:16:37 +0000 (17:16 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 4 May 2022 14:43:53 +0000 (10:43 -0400)
Support RLCP firmware front door load.

Signed-off-by: Likun Gao <Likun.Gao@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_psp.c
drivers/gpu/drm/amd/amdgpu/amdgpu_ucode.c
drivers/gpu/drm/amd/amdgpu/amdgpu_ucode.h

index 30ee4042e203398a4dad3ba8521c02cc8743aeb0..3637525a25a6de078722b968d50fde7f4ed9e5bc 100644 (file)
@@ -2139,6 +2139,9 @@ static int psp_get_fw_type(struct amdgpu_firmware_info *ucode,
        case AMDGPU_UCODE_ID_CP_MEC2_JT:
                *type = GFX_FW_TYPE_CP_MEC_ME2;
                break;
+       case AMDGPU_UCODE_ID_RLC_P:
+               *type = GFX_FW_TYPE_RLC_P;
+               break;
        case AMDGPU_UCODE_ID_RLC_G:
                *type = GFX_FW_TYPE_RLC_G;
                break;
index a4502dfe9c407425c25f65f8b734a723b321f634..a100f3b9e2a35972089d070bd7d041a5052e57fd 100644 (file)
@@ -701,6 +701,10 @@ static int amdgpu_ucode_init_single_fw(struct amdgpu_device *adev,
                        ucode->ucode_size = adev->gfx.rlc.rlc_dram_ucode_size_bytes;
                        ucode_addr = adev->gfx.rlc.rlc_dram_ucode;
                        break;
+               case AMDGPU_UCODE_ID_RLC_P:
+                       ucode->ucode_size = adev->gfx.rlc.rlcp_ucode_size_bytes;
+                       ucode_addr = adev->gfx.rlc.rlcp_ucode;
+                       break;
                case AMDGPU_UCODE_ID_CP_MES:
                        ucode->ucode_size = le32_to_cpu(mes_hdr->mes_ucode_size_bytes);
                        ucode_addr = (u8 *)ucode->fw->data +
index fb88f951fb3a0e8ffb37c6bd917f0e7b28acebcb..554a4a0521bca87a00b286ae18ad273f12aa9e6a 100644 (file)
@@ -400,6 +400,7 @@ enum AMDGPU_UCODE_ID {
        AMDGPU_UCODE_ID_RLC_RESTORE_LIST_SRM_MEM,
        AMDGPU_UCODE_ID_RLC_IRAM,
        AMDGPU_UCODE_ID_RLC_DRAM,
+       AMDGPU_UCODE_ID_RLC_P,
        AMDGPU_UCODE_ID_RLC_G,
        AMDGPU_UCODE_ID_STORAGE,
        AMDGPU_UCODE_ID_SMC,