[PATCH] drm/amdgpu: simplify the sdma 4_x MGCG/MGLS logic.
Xu, Feifei
Feifei.Xu at amd.com
Thu Mar 4 04:44:51 UTC 2021
[AMD Official Use Only - Internal Distribution Only]
Thanks. The VegaM still need to be rule out.
Thanks,
Feifei
-----Original Message-----
From: Alex Deucher <alexdeucher at gmail.com>
Sent: Thursday, March 4, 2021 12:12 PM
To: Xu, Feifei <Feifei.Xu at amd.com>
Cc: amd-gfx list <amd-gfx at lists.freedesktop.org>
Subject: Re: [PATCH] drm/amdgpu: simplify the sdma 4_x MGCG/MGLS logic.
On Wed, Mar 3, 2021 at 10:58 PM Feifei Xu <Feifei.Xu at amd.com> wrote:
>
> SDMA 4_x asics share the same MGCG/MGLS setting.
>
> Signed-off-by: Feifei Xu <Feifei.Xu at amd.com>
> ---
> drivers/gpu/drm/amd/amdgpu/sdma_v4_0.c | 12 +-----------
> 1 file changed, 1 insertion(+), 11 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/sdma_v4_0.c
> b/drivers/gpu/drm/amd/amdgpu/sdma_v4_0.c
> index 3bede8a70d7e..f46169c048fd 100644
> --- a/drivers/gpu/drm/amd/amdgpu/sdma_v4_0.c
> +++ b/drivers/gpu/drm/amd/amdgpu/sdma_v4_0.c
> @@ -2271,21 +2271,11 @@ static int sdma_v4_0_set_clockgating_state(void *handle,
> if (amdgpu_sriov_vf(adev))
> return 0;
>
> - switch (adev->asic_type) {
> - case CHIP_VEGA10:
> - case CHIP_VEGA12:
> - case CHIP_VEGA20:
> - case CHIP_RAVEN:
> - case CHIP_ARCTURUS:
> - case CHIP_RENOIR:
> - case CHIP_ALDEBARAN:
> + if (adev->asic_type >= CHIP_VEGA10){
Need a space between ) and {. That said, do we even need to check the asic type here at all? I think this applies to all chips that have sdma4.
Alex
> sdma_v4_0_update_medium_grain_clock_gating(adev,
> state == AMD_CG_STATE_GATE);
> sdma_v4_0_update_medium_grain_light_sleep(adev,
> state == AMD_CG_STATE_GATE);
> - break;
> - default:
> - break;
> }
> return 0;
> }
> --
> 2.25.1
>
> _______________________________________________
> amd-gfx mailing list
> amd-gfx at lists.freedesktop.org
> https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Flist
> s.freedesktop.org%2Fmailman%2Flistinfo%2Famd-gfx&data=04%7C01%7CFe
> ifei.Xu%40amd.com%7C67eba26e9d7a4ea88e9b08d8dec3af22%7C3dd8961fe4884e6
> 08e11a82d994e183d%7C0%7C0%7C637504279325196042%7CUnknown%7CTWFpbGZsb3d
> 8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C
> 1000&sdata=jUa2v%2BB6NICmTSr9Zdt0MQdjd1oIXYOzDYloTzUstz0%3D&re
> served=0
More information about the amd-gfx
mailing list