drm/amd/amdgpu: if visible VRAM allocation fail, fall back to invisible try again
Subsystems (2)
PATCH 1/1 drm/amd/amdgpu: if visible VRAM allocation fail, fall back to invisible try again
Change-Id Ib30efa5f007fce12a85a66722a8c9f76496f2dec
Signed-off-by Roger He <[email protected]>
--- drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c | 5 +++++ 1 file changed, 5 insertions(+)
drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c +5 -0
@@ -63,6 +63,11 @@ int amdgpu_gem_object_create(struct amdgpu_device *adev, unsigned long size, flags, NULL, resv, 0, &bo);if (r) {if (r != -ERESTARTSYS ) { +if (flags &AMDGPU_GEM_CREATE_CPU_ACCESS_REQUIRED ) { + flags &= ~AMDGPU_GEM_CREATE_CPU_ACCESS_REQUIRED ; + goto retry; + } +if (initial_domain ==AMDGPU_GEM_DOMAIN_VRAM ) { initial_domain |=AMDGPU_GEM_DOMAIN_GTT ; goto retry;
Signature · 6 lines
2.7.4 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
A message that is not in the archive (sent off-list or not yet received): 1510316253-2874-1-git-send-email-Hongbo.He-5C7GfCeVMHo@public.gmane.org
Am 10.11.2017 um 13:17 schrieb Roger He:
Quoted 2 lines
Change-Id Ib30efa5f007fce12a85a66722a8c9f76496f2decSigned-off-by Roger He <[email protected]>
Yep, exactly what I had in mind during our discussion as well.
Patch is Reviewed-by: Christian König <[email protected]>.
Thanks for taking care of this,
Christian.
Quoted 10 lines
--- drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c | 5 +++++ 1 file changed, 5 insertions(+)drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c +0
-0@@ -63,6 +63,11 @@ int amdgpu_gem_object_create(struct amdgpu_device *adev, unsigned long size, flags, NULL, resv, 0, &bo);
drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c int amdgpu_gem_object_create(struct amdgpu_device *adev, unsigned long size, · line 73
Quoted 10 lines
drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c +5
-0if (r) {if (r != -ERESTARTSYS ) { +if (flags &AMDGPU_GEM_CREATE_CPU_ACCESS_REQUIRED ) { + flags &= ~AMDGPU_GEM_CREATE_CPU_ACCESS_REQUIRED ; + goto retry; + } +if (initial_domain ==AMDGPU_GEM_DOMAIN_VRAM ) { initial_domain |=AMDGPU_GEM_DOMAIN_GTT ; goto retry;
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx