All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drm/amdgpu: Ignore stop rlc on SRIOV environment.
@ 2022-11-09 18:24 Gavin Wan
  2022-11-09 19:07 ` Alex Deucher
  2022-11-10  1:13 ` Wang, Yang(Kevin)
  0 siblings, 2 replies; 4+ messages in thread
From: Gavin Wan @ 2022-11-09 18:24 UTC (permalink / raw)
  To: amd-gfx; +Cc: Gavin Wan

For SRIOV, the guest driver should not do stop rlc. The host
handles programing RLC.

On SRIOV, the stop rlc will be hang (RLC related registers are
blocked by policy) when the RLCG interface is not enabled.

Signed-off-by: Gavin Wan <Gavin.Wan@amd.com>
Change-Id: Iac31332e2c958aae9506759de1d3a311b5c84942
---
 drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c b/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c
index 4fe75dd2b329..0e9529b95d35 100644
--- a/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c
+++ b/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c
@@ -1517,7 +1517,7 @@ static int smu_disable_dpms(struct smu_context *smu)
 	}
 
 	if (adev->ip_versions[GC_HWIP][0] >= IP_VERSION(9, 4, 2) &&
-	    adev->gfx.rlc.funcs->stop)
+	    !amdgpu_sriov_vf(adev) && adev->gfx.rlc.funcs->stop)
 		adev->gfx.rlc.funcs->stop(adev);
 
 	return ret;
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] drm/amdgpu: Ignore stop rlc on SRIOV environment.
  2022-11-09 18:24 [PATCH] drm/amdgpu: Ignore stop rlc on SRIOV environment Gavin Wan
@ 2022-11-09 19:07 ` Alex Deucher
  2022-11-09 20:26   ` Liu, Shaoyun
  2022-11-10  1:13 ` Wang, Yang(Kevin)
  1 sibling, 1 reply; 4+ messages in thread
From: Alex Deucher @ 2022-11-09 19:07 UTC (permalink / raw)
  To: Gavin Wan; +Cc: amd-gfx

On Wed, Nov 9, 2022 at 1:24 PM Gavin Wan <Gavin.Wan@amd.com> wrote:
>
> For SRIOV, the guest driver should not do stop rlc. The host
> handles programing RLC.
>
> On SRIOV, the stop rlc will be hang (RLC related registers are
> blocked by policy) when the RLCG interface is not enabled.
>
> Signed-off-by: Gavin Wan <Gavin.Wan@amd.com>

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

> Change-Id: Iac31332e2c958aae9506759de1d3a311b5c84942> ---
>  drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c b/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c
> index 4fe75dd2b329..0e9529b95d35 100644
> --- a/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c
> +++ b/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c
> @@ -1517,7 +1517,7 @@ static int smu_disable_dpms(struct smu_context *smu)
>         }
>
>         if (adev->ip_versions[GC_HWIP][0] >= IP_VERSION(9, 4, 2) &&
> -           adev->gfx.rlc.funcs->stop)
> +           !amdgpu_sriov_vf(adev) && adev->gfx.rlc.funcs->stop)
>                 adev->gfx.rlc.funcs->stop(adev);
>
>         return ret;
> --
> 2.34.1
>

^ permalink raw reply	[flat|nested] 4+ messages in thread

* RE: [PATCH] drm/amdgpu: Ignore stop rlc on SRIOV environment.
  2022-11-09 19:07 ` Alex Deucher
@ 2022-11-09 20:26   ` Liu, Shaoyun
  0 siblings, 0 replies; 4+ messages in thread
From: Liu, Shaoyun @ 2022-11-09 20:26 UTC (permalink / raw)
  To: Alex Deucher, Wan, Gavin; +Cc: amd-gfx

[AMD Official Use Only - General]

Rewed-by: shaoyun liu <shaoyun.liu@amd.com>

-----Original Message-----
From: amd-gfx <amd-gfx-bounces@lists.freedesktop.org> On Behalf Of Alex Deucher
Sent: Wednesday, November 9, 2022 2:07 PM
To: Wan, Gavin <Gavin.Wan@amd.com>
Cc: amd-gfx@lists.freedesktop.org
Subject: Re: [PATCH] drm/amdgpu: Ignore stop rlc on SRIOV environment.

On Wed, Nov 9, 2022 at 1:24 PM Gavin Wan <Gavin.Wan@amd.com> wrote:
>
> For SRIOV, the guest driver should not do stop rlc. The host handles
> programing RLC.
>
> On SRIOV, the stop rlc will be hang (RLC related registers are blocked
> by policy) when the RLCG interface is not enabled.
>
> Signed-off-by: Gavin Wan <Gavin.Wan@amd.com>

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

> Change-Id: Iac31332e2c958aae9506759de1d3a311b5c84942> ---
> drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c
> b/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c
> index 4fe75dd2b329..0e9529b95d35 100644
> --- a/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c
> +++ b/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c
> @@ -1517,7 +1517,7 @@ static int smu_disable_dpms(struct smu_context *smu)
>         }
>
>         if (adev->ip_versions[GC_HWIP][0] >= IP_VERSION(9, 4, 2) &&
> -           adev->gfx.rlc.funcs->stop)
> +           !amdgpu_sriov_vf(adev) && adev->gfx.rlc.funcs->stop)
>                 adev->gfx.rlc.funcs->stop(adev);
>
>         return ret;
> --
> 2.34.1
>

^ permalink raw reply	[flat|nested] 4+ messages in thread

* RE: [PATCH] drm/amdgpu: Ignore stop rlc on SRIOV environment.
  2022-11-09 18:24 [PATCH] drm/amdgpu: Ignore stop rlc on SRIOV environment Gavin Wan
  2022-11-09 19:07 ` Alex Deucher
@ 2022-11-10  1:13 ` Wang, Yang(Kevin)
  1 sibling, 0 replies; 4+ messages in thread
From: Wang, Yang(Kevin) @ 2022-11-10  1:13 UTC (permalink / raw)
  To: Wan, Gavin, amd-gfx; +Cc: Wan, Gavin

[AMD Official Use Only - General]

Reviewed-by: Yang Wang <kevinyang.wang@amd.com>

Best Regards,
Kevin

-----Original Message-----
From: amd-gfx <amd-gfx-bounces@lists.freedesktop.org> On Behalf Of Gavin Wan
Sent: Thursday, November 10, 2022 2:24 AM
To: amd-gfx@lists.freedesktop.org
Cc: Wan, Gavin <Gavin.Wan@amd.com>
Subject: [PATCH] drm/amdgpu: Ignore stop rlc on SRIOV environment.

For SRIOV, the guest driver should not do stop rlc. The host handles programing RLC.

On SRIOV, the stop rlc will be hang (RLC related registers are blocked by policy) when the RLCG interface is not enabled.

Signed-off-by: Gavin Wan <Gavin.Wan@amd.com>
Change-Id: Iac31332e2c958aae9506759de1d3a311b5c84942
---
 drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c b/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c
index 4fe75dd2b329..0e9529b95d35 100644
--- a/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c
+++ b/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c
@@ -1517,7 +1517,7 @@ static int smu_disable_dpms(struct smu_context *smu)
        }

        if (adev->ip_versions[GC_HWIP][0] >= IP_VERSION(9, 4, 2) &&
-           adev->gfx.rlc.funcs->stop)
+           !amdgpu_sriov_vf(adev) && adev->gfx.rlc.funcs->stop)
                adev->gfx.rlc.funcs->stop(adev);

        return ret;
--
2.34.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-11-10  1:13 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-11-09 18:24 [PATCH] drm/amdgpu: Ignore stop rlc on SRIOV environment Gavin Wan
2022-11-09 19:07 ` Alex Deucher
2022-11-09 20:26   ` Liu, Shaoyun
2022-11-10  1:13 ` Wang, Yang(Kevin)

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.