summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
diff options
context:
space:
mode:
authorChristian König <christian.koenig@amd.com>2018-02-16 09:52:51 +0100
committerAlex Deucher <alexander.deucher@amd.com>2018-02-20 14:40:22 -0500
commitc06cc6f7608d70561655d4fc9e3f9144761aa44b (patch)
treebb6760c9617d2c24e31096bf827f6ca7475e6ead /drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
parent9021d2edd259d992cf8b5b48791ab50829129de7 (diff)
downloadop-kernel-dev-c06cc6f7608d70561655d4fc9e3f9144761aa44b.zip
op-kernel-dev-c06cc6f7608d70561655d4fc9e3f9144761aa44b.tar.gz
drm/amdgpu: use drm_gem_private_object_init
We use our own backing store and don't need the shmem file. Signed-off-by: Christian König <christian.koenig@amd.com> Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_object.c')
-rw-r--r--drivers/gpu/drm/amd/amdgpu/amdgpu_object.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
index 512612e..969de54 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
@@ -371,11 +371,7 @@ static int amdgpu_bo_do_create(struct amdgpu_device *adev,
bo = kzalloc(sizeof(struct amdgpu_bo), GFP_KERNEL);
if (bo == NULL)
return -ENOMEM;
- r = drm_gem_object_init(adev->ddev, &bo->gem_base, size);
- if (unlikely(r)) {
- kfree(bo);
- return r;
- }
+ drm_gem_private_object_init(adev->ddev, &bo->gem_base, size);
INIT_LIST_HEAD(&bo->shadow_list);
INIT_LIST_HEAD(&bo->va);
bo->preferred_domains = domain & (AMDGPU_GEM_DOMAIN_VRAM |
OpenPOWER on IntegriCloud