drm/amdgpu: Fix potential issue if reserve function is interrupted If amdgpu_bo_reserve function is interrupted by signal, amdgpu_bo_kunmap function is not called.
Subsystems (2)
PATCH 1/4 drm/amdgpu: Fix potential issue if reserve function is interrupted If amdgpu_bo_reserve function is interrupted by signal, amdgpu_bo_kunmap function is not called.
--- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +1 -1
@@ -350,7 +350,7 @@ static void amdgpu_vram_scratch_fini(struct amdgpu_device *adev)if (adev->vram_scratch.robj ==NULL ) {return ; } - r =amdgpu_bo_reserve (adev->vram_scratch.robj, false); + r =amdgpu_bo_reserve (adev->vram_scratch.robj, true);if (likely (r ==0 )) {amdgpu_bo_kunmap (adev->vram_scratch.robj);amdgpu_bo_unpin (adev->vram_scratch.robj);
Signature · 6 lines
1.9.1 _______________________________________________ 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): 1493058545-9733-1-git-send-email-AlexBin.Xie-5C7GfCeVMHo@public.gmane.org
PATCH 2/4 drm/amdgpu: Fix use of interruptible waiting 1. The signal interrupt can affect the expected behaviour. 2. There is no mechanism to handle the corresponding error.
--- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +3 -3
@@ -2181,7 +2181,7 @@ int amdgpu_device_suspend(struct drm_device *dev, bool suspend, bool fbcon)if (amdgpu_crtc->cursor_bo) {struct amdgpu_bo *aobj =gem_to_amdgpu_bo (amdgpu_crtc->cursor_bo); - r =amdgpu_bo_reserve (aobj, false); + r =amdgpu_bo_reserve (aobj, true);if (r ==0 ) {amdgpu_bo_unpin (aobj);amdgpu_bo_unreserve (aobj);
@@ -2194,7 +2194,7 @@ int amdgpu_device_suspend(struct drm_device *dev, bool suspend, bool fbcon) robj =gem_to_amdgpu_bo (rfb->obj);/* don't unpin kernel fb objects */ if (!amdgpu_fbdev_robj_is_fb (adev, robj)) { - r =amdgpu_bo_reserve (robj, false); + r =amdgpu_bo_reserve (robj, true);if (r ==0 ) {amdgpu_bo_unpin (robj);amdgpu_bo_unreserve (robj);
@@ -2301,7 +2301,7 @@ int amdgpu_device_resume(struct drm_device *dev, bool resume, bool fbcon)if (amdgpu_crtc->cursor_bo) {struct amdgpu_bo *aobj =gem_to_amdgpu_bo (amdgpu_crtc->cursor_bo); - r =amdgpu_bo_reserve (aobj, false); + r =amdgpu_bo_reserve (aobj, true);if (r ==0 ) { r = amdgpu_bo_pin(aobj, AMDGPU_GEM_DOMAIN_VRAM,
Signature · 6 lines
1.9.1 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
PATCH 3/4 drm/amdgpu: Fix use of interruptible waiting 1. The signal interrupt can affect the expected behaviour. 2. There is no good mechanism to handle the corresponding error.
In reply to a message not in the archive--- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +1 -1
@@ -2479,7 +2479,7 @@ static int amdgpu_recover_vram_from_shadow(struct amdgpu_device *adev,if (!bo->shadow)return 0 ; - r =amdgpu_bo_reserve (bo, false); + r =amdgpu_bo_reserve (bo, true);if (r)return r; domain =amdgpu_mem_type_to_domain (bo->tbo.mem.mem_type);
Signature · 6 lines
1.9.1 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
PATCH 4/4 drm/amdgpu: Fix use of interruptible waiting 1. The signal interrupt can affect the expected behaviour. 2. There is no good mechanism to handle the corresponding error.
In reply to a message not in the archive--- drivers/gpu/drm/amd/amdgpu/amdgpu_object.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_object.c +1 -1
@@ -295,7 +295,7 @@ void amdgpu_bo_free_kernel(struct amdgpu_bo **bo, u64 *gpu_addr,if (*bo ==NULL )return ; -if (likely (amdgpu_bo_reserve (*bo, false) ==0 )) { +if (likely (amdgpu_bo_reserve (*bo, true) ==0 )) {if (cpu_addr)amdgpu_bo_kunmap (*bo);
Signature · 6 lines
1.9.1 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
All commit messages got mangled into the subject line.
You probably forgot the empty line between subject and commit message while creating the commit.
With that fixed the whole series is Reviewed-by: Christian König <[email protected]>.
Regards,
Christian.
Am 24.04.2017 um 20:29 schrieb Alex Xie:
Quoted 11 lines
Change-Id Ide2b3be6549b3afb8d6116094b5fff495b18addfSigned-off-by Alex Xie <[email protected]>--- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +0
-0
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c static void amdgpu_vram_scratch_fini(struct amdgpu_device *adev) · line 356
Quoted 8 lines
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +1
-1@@ -350,7 +350,7 @@ static void amdgpu_vram_scratch_fini(struct amdgpu_device *adev)if (adev->vram_scratch.robj ==NULL ) {return ; } - r =amdgpu_bo_reserve (adev->vram_scratch.robj, false); + r =amdgpu_bo_reserve (adev->vram_scratch.robj, true);if (likely (r ==0 )) {amdgpu_bo_kunmap (adev->vram_scratch.robj);amdgpu_bo_unpin (adev->vram_scratch.robj);
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx