[PATCH 2/3] drm/amd/amdgpu: init allow_reserved_eviction and resv when create a new bo

Michel Dänzer michel at daenzer.net
Wed Dec 13 10:03:19 UTC 2017


On 2017-12-13 06:17 AM, Roger He wrote:
> Change-Id: I0c6571c2a64e6c5bdad80ccbcccb40eba1c20b4e
> Signed-off-by: Roger He <Hongbo.He at amd.com>
> ---
>  drivers/gpu/drm/amd/amdgpu/amdgpu_object.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
> index dc0a8be..7c7f56f5 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
> @@ -327,7 +327,7 @@ static int amdgpu_bo_do_create(struct amdgpu_device *adev,
>  			       uint64_t init_value,
>  			       struct amdgpu_bo **bo_ptr)
>  {
> -	struct ttm_operation_ctx ctx = { !kernel, false };
> +	struct ttm_operation_ctx ctx = { !kernel, false, true, resv };

Please use named initializers, to make it easier to understand which
field is initialized to which value.


-- 
Earthling Michel Dänzer               |               http://www.amd.com
Libre software enthusiast             |             Mesa and X developer


More information about the amd-gfx mailing list