From a69c85fec8ed323bffb1324ea08157b3897e97db Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kristian=20H=C3=B8gsberg?= Date: Tue, 9 Oct 2007 21:09:31 -0400 Subject: Drop destroy ioctls for fences and buffer objects. We now always create a drm_ref_object for user objects and this is then the only things that holds a reference to the user object. This way unreference on will destroy the user object when the last drm_ref_object goes way. --- linux-core/drm_fops.c | 13 ------------- 1 file changed, 13 deletions(-) (limited to 'linux-core/drm_fops.c') diff --git a/linux-core/drm_fops.c b/linux-core/drm_fops.c index ab5f4ca5..0ccaed5b 100644 --- a/linux-core/drm_fops.c +++ b/linux-core/drm_fops.c @@ -263,7 +263,6 @@ static int drm_open_helper(struct inode *inode, struct file *filp, priv->lock_count = 0; INIT_LIST_HEAD(&priv->lhead); - INIT_LIST_HEAD(&priv->user_objects); INIT_LIST_HEAD(&priv->refd_objects); for (i=0; i<_DRM_NO_REF_TYPES; ++i) { @@ -338,7 +337,6 @@ static void drm_object_release(struct file *filp) { struct drm_file *priv = filp->private_data; struct list_head *head; - struct drm_user_object *user_object; struct drm_ref_object *ref_object; int i; @@ -357,17 +355,6 @@ static void drm_object_release(struct file *filp) { head = &priv->refd_objects; } - /* - * Free leftover user objects created by me. - */ - - head = &priv->user_objects; - while (head->next != head) { - user_object = list_entry(head->next, struct drm_user_object, list); - drm_remove_user_object(priv, user_object); - head = &priv->user_objects; - } - for(i=0; i<_DRM_NO_REF_TYPES; ++i) { drm_ht_remove(&priv->refd_object_hash[i]); } -- cgit v1.2.3