diff options
author | Christian König <christian.koenig@amd.com> | 2015-08-25 13:05:20 (GMT) |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2015-08-26 21:51:37 (GMT) |
commit | 02537d63623ce5281c20d76f1b61797a7836acf4 (patch) | |
tree | 110a8cb3b126d60f7855dafd9eb2546427341292 | |
parent | c7ae72c01be10f539f385f624713f8ba0aa11a8f (diff) | |
download | linux-02537d63623ce5281c20d76f1b61797a7836acf4.tar.xz |
drm/amdgpu: fix postclose order
The context needs to finish before everything else.
Signed-off-by: Christian König <christian.koenig@amd.com>
Acked-by: Alex Deucher <alexander.deucher@amd.com>
Reviewed-by: Jammy Zhou <Jammy.Zhou@amd.com>
Reviewed-by: Chunming Zhou <david1.zhou@amd.com>
-rw-r--r-- | drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c index 87da6b1..2236793 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c @@ -560,6 +560,8 @@ void amdgpu_driver_postclose_kms(struct drm_device *dev, if (!fpriv) return; + amdgpu_ctx_mgr_fini(&fpriv->ctx_mgr); + amdgpu_vm_fini(adev, &fpriv->vm); idr_for_each_entry(&fpriv->bo_list_handles, list, handle) @@ -568,8 +570,6 @@ void amdgpu_driver_postclose_kms(struct drm_device *dev, idr_destroy(&fpriv->bo_list_handles); mutex_destroy(&fpriv->bo_list_lock); - amdgpu_ctx_mgr_fini(&fpriv->ctx_mgr); - kfree(fpriv); file_priv->driver_priv = NULL; } |