drm/amdgpu: fix ras UE error injection failure issue
Subsystems (2)
PATCH 1/1 drm/amdgpu: fix ras UE error injection failure issue
The ras command shared memory is allocated from VRAM and the response status of the command buffer will not be zero due to gpu being in fatal error state after ras UE error injection.
--- drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c +1 -3
@@ -1630,9 +1630,7 @@ static int psp_ras_send_cmd(struct psp_context *psp,switch (cmd) {case TA_RAS_COMMAND__TRIGGER_ERROR : -if (ret || psp->cmd_buf_mem->resp.status) - ret = -EINVAL ; -else if (out) +if (!ret && out)memcpy (out, &ras_cmd->ras_status,sizeof (ras_cmd->ras_status));break ;case TA_RAS_COMMAND__QUERY_ADDRESS :
Signature · 1 line
2.34.1
[AMD Official Use Only - AMD Internal Distribution Only]
Regards,
Hawking
-----Original Message-----
From: Chai, Thomas <[email protected]>
Sent: Monday, July 22, 2024 09:48
To: [email protected]
Cc: Zhang, Hawking <[email protected]>; Zhou1, Tao <[email protected]>; Li, Candice <[email protected]>; Wang, Yang(Kevin) <[email protected]>; Yang, Stanley <[email protected]>; Chai, Thomas <[email protected]>
Subject: [PATCH] drm/amdgpu: fix ras UE error injection failure issue
The ras command shared memory is allocated from VRAM and the response status of the command buffer will not be zero due to gpu being in fatal error state after ras UE error injection.
--- drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c +1 -3
@@ -1630,9 +1630,7 @@ static int psp_ras_send_cmd(struct psp_context *psp,switch (cmd) {case TA_RAS_COMMAND__TRIGGER_ERROR : -if (ret || psp->cmd_buf_mem->resp.status) - ret = -EINVAL ; -else if (out) +if (!ret && out)memcpy (out, &ras_cmd->ras_status,sizeof (ras_cmd->ras_status));break ;case TA_RAS_COMMAND__QUERY_ADDRESS :
--
2.34.1