[AMD Official Use Only - General]

> -----Original Message-----
> From: Chai, Thomas <yipeng.c...@amd.com>
> Sent: Wednesday, July 19, 2023 8:40 PM
> To: amd-gfx@lists.freedesktop.org
> Cc: Chai, Thomas <yipeng.c...@amd.com>; Zhang, Hawking
> <hawking.zh...@amd.com>; Zhou1, Tao <tao.zh...@amd.com>; Li, Candice
> <candice...@amd.com>; Yang, Stanley <stanley.y...@amd.com>; Chai, Thomas
> <yipeng.c...@amd.com>
> Subject: [PATCH 1/2] drm/amdgpu: add ta initialization failure check condition
>
> Add ta initialization failure check condition.

[Tao] better to say "Add condition check for ta initialization failure"

>
> Signed-off-by: YiPeng Chai <yipeng.c...@amd.com>
> ---
>  drivers/gpu/drm/amd/amdgpu/amdgpu_psp_ta.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_psp_ta.c
> b/drivers/gpu/drm/amd/amdgpu/amdgpu_psp_ta.c
> index 468a67b302d4..049d34fd5ba0 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_psp_ta.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_psp_ta.c
> @@ -220,7 +220,7 @@ static ssize_t ta_if_load_debugfs_write(struct file *fp,
> const char *buf, size_t
>       }
>
>       ret = psp_fn_ta_initialize(psp);
> -     if (ret || context->resp_status) {
> +     if (ret || context->resp_status || !context->initialized) {
>               dev_err(adev->dev, "Failed to load TA via debugfs (%d) and 
> status
> (0x%X)\n",
>                       ret, context->resp_status);
>               if (!ret)
> --
> 2.34.1

Reply via email to