drm/msm: Implement .gem_free_object_unlocked
We use a llist and a worker to delay the object cleanup. This avoids taking mmap_sem and struct mutex in the wrong order when calling drm_gem_object_put-unlocked() from drm_gem_mmap(). Fixes lockdep problem with copy_from_user() in msm_ioctl_gem_submit(). Change-Id: Idfe54ae8108158b69f3835f26991642d1e21f8ee Signed-off-by: Kristian H. Kristensen <hoegsberg@chromium.org> Signed-off-by: Rob Clark <robdclark@chromium.org> Git-commit: 48e7f18392c66f9b69ebac11c54f1a2e033ced54 Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git [samtran@codeaurora.org: resolve trivial merge conflict] Signed-off-by: Samantha Tran <samtran@codeaurora.org>
This commit is contained in:

committed by
Samantha Tran

orang tua
19e9831a45
melakukan
a145e793b2
@@ -792,6 +792,9 @@ static int msm_drm_component_init(struct device *dev)
|
||||
priv->wq = alloc_ordered_workqueue("msm_drm", 0);
|
||||
init_waitqueue_head(&priv->pending_crtcs_event);
|
||||
|
||||
INIT_WORK(&priv->free_work, msm_gem_free_work);
|
||||
init_llist_head(&priv->free_list);
|
||||
|
||||
INIT_LIST_HEAD(&priv->client_event_list);
|
||||
INIT_LIST_HEAD(&priv->inactive_list);
|
||||
INIT_LIST_HEAD(&priv->vm_client_list);
|
||||
|
Reference in New Issue
Block a user