Skip to content
Snippets Groups Projects
Commit ab5d6227 authored by Monk Liu's avatar Monk Liu Committed by Alex Deucher
Browse files

drm/amdgpu/sriov:fix missing error handling

parent 98512bb8
No related branches found
No related tags found
No related merge requests found
...@@ -841,9 +841,12 @@ int amdgpu_driver_open_kms(struct drm_device *dev, struct drm_file *file_priv) ...@@ -841,9 +841,12 @@ int amdgpu_driver_open_kms(struct drm_device *dev, struct drm_file *file_priv)
if (amdgpu_sriov_vf(adev)) { if (amdgpu_sriov_vf(adev)) {
r = amdgpu_map_static_csa(adev, &fpriv->vm, &fpriv->csa_va); r = amdgpu_map_static_csa(adev, &fpriv->vm, &fpriv->csa_va);
if (r) if (r) {
amdgpu_vm_fini(adev, &fpriv->vm);
kfree(fpriv);
goto out_suspend; goto out_suspend;
} }
}
mutex_init(&fpriv->bo_list_lock); mutex_init(&fpriv->bo_list_lock);
idr_init(&fpriv->bo_list_handles); idr_init(&fpriv->bo_list_handles);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment