[Patch v4 4/4] drm/amdgpu/runpm: enable runpm on baco capable VI+ asics
Alex Deucher
alexdeucher at gmail.com
Tue Feb 11 16:40:48 UTC 2020
On Mon, Feb 10, 2020 at 1:48 PM Rajneesh Bhardwaj
<rajneesh.bhardwaj at amd.com> wrote:
>
> From: Alex Deucher <alexander.deucher at amd.com>
>
> Seems to work reliably on VI+ except for a few so enable runpm barring
> those where baco for runtime power management is not supported.
>
> [rajneesh] Picked https://patchwork.freedesktop.org/patch/335402/ to
> enable runtime pm with baco for kfd. Also fixed a checkpatch warning and
> added extra checks for VEGA20 and ARCTURUS.
>
Reviewed-by: Alex Deucher <alexander.deucher at amd.com>
> Signed-off-by: Rajneesh Bhardwaj <rajneesh.bhardwaj at amd.com>
> Signed-off-by: Alex Deucher <alexander.deucher at amd.com>
> ---
> drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c | 10 ++++++++--
> 1 file changed, 8 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c
> index 3a0ea9096498..0f3563926ad1 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c
> @@ -170,10 +170,16 @@ int amdgpu_driver_load_kms(struct drm_device *dev, unsigned long flags)
> }
>
> if (amdgpu_device_supports_boco(dev) &&
> - (amdgpu_runtime_pm != 0)) /* enable runpm by default */
> + (amdgpu_runtime_pm != 0)) /* enable runpm by default for boco */
> adev->runpm = true;
> else if (amdgpu_device_supports_baco(dev) &&
> - (amdgpu_runtime_pm > 0)) /* enable runpm if runpm=1 */
> + (amdgpu_runtime_pm != 0) &&
> + (adev->asic_type >= CHIP_TOPAZ) &&
> + (adev->asic_type != CHIP_VEGA20) &&
> + (adev->asic_type != CHIP_ARCTURUS)) /* enable runpm on VI+ */
> + adev->runpm = true;
> + else if (amdgpu_device_supports_baco(dev) &&
> + (amdgpu_runtime_pm > 0)) /* enable runpm if runpm=1 on CI */
> adev->runpm = true;
>
> /* Call ACPI methods: require modeset init
> --
> 2.17.1
>
> _______________________________________________
> amd-gfx mailing list
> amd-gfx at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/amd-gfx
More information about the amd-gfx
mailing list