projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
44f9d7b
)
drm/amdgpu/vce3: don't forget to tear down some rings
author
Grazvydas Ignotas
<
[email protected]
>
Sun, 25 Sep 2016 20:34:49 +0000
(23:34 +0300)
committer
Alex Deucher
<
[email protected]
>
Tue, 27 Sep 2016 17:00:52 +0000
(13:00 -0400)
We can use .num_rings for that.
Fixes: 6f0359ff7307 ("vce3: add support for third vce ring")
Cc: Alex Deucher <
[email protected]
>
Signed-off-by: Grazvydas Ignotas <
[email protected]
>
Signed-off-by: Alex Deucher <
[email protected]
>
drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c
patch
|
blob
|
history
diff --git
a/drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c
b/drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c
index 686d99c121a8f794d3862351e58f6b38e5d847a9..3b03558ddb012959c9ae2c38122e1824f2c15ea2 100644
(file)
--- a/
drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c
+++ b/
drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c
@@
-210,6
+210,8
@@
int amdgpu_vce_sw_init(struct amdgpu_device *adev, unsigned long size)
*/
int amdgpu_vce_sw_fini(struct amdgpu_device *adev)
{
+ unsigned i;
+
if (adev->vce.vcpu_bo == NULL)
return 0;
@@
-217,8
+219,8
@@
int amdgpu_vce_sw_fini(struct amdgpu_device *adev)
amdgpu_bo_unref(&adev->vce.vcpu_bo);
- amdgpu_ring_fini(&adev->vce.ring[0]);
-
amdgpu_ring_fini(&adev->vce.ring[1
]);
+ for (i = 0; i < adev->vce.num_rings; i++)
+
amdgpu_ring_fini(&adev->vce.ring[i
]);
release_firmware(adev->vce.fw);
mutex_destroy(&adev->vce.idle_mutex);