diff options
Diffstat (limited to 'meta-amd-bsp/recipes-kernel/linux-4.19/linux-yocto-4.19.8/0158-drm-amdgpu-add-status-checking-after-fw-is-loaded.patch')
-rw-r--r-- | meta-amd-bsp/recipes-kernel/linux-4.19/linux-yocto-4.19.8/0158-drm-amdgpu-add-status-checking-after-fw-is-loaded.patch | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/meta-amd-bsp/recipes-kernel/linux-4.19/linux-yocto-4.19.8/0158-drm-amdgpu-add-status-checking-after-fw-is-loaded.patch b/meta-amd-bsp/recipes-kernel/linux-4.19/linux-yocto-4.19.8/0158-drm-amdgpu-add-status-checking-after-fw-is-loaded.patch new file mode 100644 index 00000000..aac2b505 --- /dev/null +++ b/meta-amd-bsp/recipes-kernel/linux-4.19/linux-yocto-4.19.8/0158-drm-amdgpu-add-status-checking-after-fw-is-loaded.patch @@ -0,0 +1,35 @@ +From ace564d038f9fb09c274fdc7bae9a83b402c6add Mon Sep 17 00:00:00 2001 +From: Huang Rui <ray.huang@amd.com> +Date: Sun, 5 Aug 2018 12:45:35 +0800 +Subject: [PATCH 0158/2940] drm/amdgpu: add status checking after fw is loaded + +The status field must be 0 after FW is loaded. + +Signed-off-by: Huang Rui <ray.huang@amd.com> +Acked-by: Alex Deucher <alexander.deucher@amd.com> +Signed-off-by: Alex Deucher <alexander.deucher@amd.com> +--- + drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c | 7 +++++++ + 1 file changed, 7 insertions(+) + +diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c +index 58e20385eab5..bd397d2916fb 100644 +--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c ++++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c +@@ -134,6 +134,13 @@ psp_cmd_submit_buf(struct psp_context *psp, + msleep(1); + } + ++ /* the status field must be 0 after FW is loaded */ ++ if (ucode && psp->cmd_buf_mem->resp.status) { ++ DRM_ERROR("failed loading with status (%d) and ucode id (%d)\n", ++ psp->cmd_buf_mem->resp.status, ucode->ucode_id); ++ return -EINVAL; ++ } ++ + if (ucode) { + ucode->tmr_mc_addr_lo = psp->cmd_buf_mem->resp.fw_addr_lo; + ucode->tmr_mc_addr_hi = psp->cmd_buf_mem->resp.fw_addr_hi; +-- +2.17.1 + |