[PATCH] drm/amd/display: Enable VM support only on APUs newer than CZ

Christian König ckoenig.leichtzumerken at gmail.com
Mon Oct 30 18:00:31 UTC 2017


Am 30.10.2017 um 18:41 schrieb Harry Wentland:
> VM support is only available for CZ and newer APUs. Trying to
> enable it for dGPU will blow up in DC.
>
> Signed-off-by: Harry Wentland <harry.wentland at amd.com>
> Suggested-by: Alex Deucher <alexander.deucher at amd.com>
> CC: Christian Koenig <christian.koenig at amd.com>

Ok, with me. But I think it would be cleaner if the backend can just 
handle this gracefully even when it is not supported by the hardware.

Christian.

> ---
>   drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 4 ++++
>   1 file changed, 4 insertions(+)
>
> diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
> index 26f6d5e4c08c..332761f643f6 100644
> --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
> +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
> @@ -427,6 +427,10 @@ static int amdgpu_dm_init(struct amdgpu_device *adev)
>   		amdgpu_dm_initialize_fbc(adev);
>   	init_data.fbc_gpu_addr = adev->dm.compressor.gpu_addr;
>   #endif
> +
> +	if (adev->flags & AMD_IS_APU && adev->asic_type >= CHIP_CARRIZO)
> +		init_data.flags.gpu_vm_support = true;
> +
>   	/* Display Core create. */
>   	adev->dm.dc = dc_create(&init_data);
>   




More information about the amd-gfx mailing list