amd-gfx.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
From: Alex Deucher <alexdeucher@gmail.com>
To: Prike Liang <Prike.Liang@amd.com>
Cc: amd-gfx list <amd-gfx@lists.freedesktop.org>,
	 "Deucher, Alexander" <Alexander.Deucher@amd.com>,
	Huang Rui <ray.huang@amd.com>
Subject: Re: [PATCH] drm/amdgpu: force exit gfxoff on sdma resume for rmb s0ix
Date: Mon, 27 Sep 2021 11:16:40 -0400	[thread overview]
Message-ID: <CADnq5_NGSMJUs_WJKwWX7K9WboN6PuoTVtTeHNnFiCVYmfaWog@mail.gmail.com> (raw)
In-Reply-To: <1632661843-3923-1-git-send-email-Prike.Liang@amd.com>

On Sun, Sep 26, 2021 at 9:14 AM Prike Liang <Prike.Liang@amd.com> wrote:
>
> In the s2idle stress test sdma resume fail occasionally,in the
> failed case GPU is in the gfxoff state.This issue may introduce
> by FSDL miss handle doorbell S/R and now temporary fix the issue
> by forcing exit gfxoff for sdma resume.
>
> Signed-off-by: Prike Liang <Prike.Liang@amd.com>

Reviewed-by: Alex Deucher <alexander.deucher@amd.com>

> ---
>  drivers/gpu/drm/amd/amdgpu/sdma_v5_2.c | 8 ++++++++
>  1 file changed, 8 insertions(+)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/sdma_v5_2.c b/drivers/gpu/drm/amd/amdgpu/sdma_v5_2.c
> index e4a96e7e386d..81906955ef52 100644
> --- a/drivers/gpu/drm/amd/amdgpu/sdma_v5_2.c
> +++ b/drivers/gpu/drm/amd/amdgpu/sdma_v5_2.c
> @@ -868,6 +868,12 @@ static int sdma_v5_2_start(struct amdgpu_device *adev)
>                         msleep(1000);
>         }
>
> +       /* TODO: check whether can submit a doorbell request to raise
> +        * a doorbell fence to exit gfxoff.
> +        */
> +       if (adev->in_s0ix)
> +               amdgpu_gfx_off_ctrl(adev, false);
> +
>         sdma_v5_2_soft_reset(adev);
>         /* unhalt the MEs */
>         sdma_v5_2_enable(adev, true);
> @@ -876,6 +882,8 @@ static int sdma_v5_2_start(struct amdgpu_device *adev)
>
>         /* start the gfx rings and rlc compute queues */
>         r = sdma_v5_2_gfx_resume(adev);
> +       if (adev->in_s0ix)
> +               amdgpu_gfx_off_ctrl(adev, true);
>         if (r)
>                 return r;
>         r = sdma_v5_2_rlc_resume(adev);
> --
> 2.17.1
>

  reply	other threads:[~2021-09-27 15:16 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-26 13:10 [PATCH] drm/amdgpu: force exit gfxoff on sdma resume for rmb s0ix Prike Liang
2021-09-27 15:16 ` Alex Deucher [this message]
  -- strict thread matches above, loose matches on Subject: below --
2021-09-24  5:18 Prike Liang
2021-09-24  5:55 ` Liang, Prike

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CADnq5_NGSMJUs_WJKwWX7K9WboN6PuoTVtTeHNnFiCVYmfaWog@mail.gmail.com \
    --to=alexdeucher@gmail.com \
    --cc=Alexander.Deucher@amd.com \
    --cc=Prike.Liang@amd.com \
    --cc=amd-gfx@lists.freedesktop.org \
    --cc=ray.huang@amd.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).