提交 1f4eccfd 编写于 作者: T Thomas Hellstrom 提交者: Dave Airlie

drm: remove hash tables on drm exit

Signed-off-by: NDave Airlie <airlied@linux.ie>
上级 fb41e54b
......@@ -161,6 +161,7 @@ int drm_lastclose(drm_device_t * dev)
drm_ht_remove_item(&dev->magiclist, &pt->hash_item);
drm_free(pt, sizeof(*pt), DRM_MEM_MAGIC);
}
drm_ht_remove(&dev->magiclist);
}
/* Clear AGP information */
......@@ -299,6 +300,7 @@ static void drm_cleanup(drm_device_t * dev)
if (dev->maplist) {
drm_free(dev->maplist, sizeof(*dev->maplist), DRM_MEM_MAPS);
dev->maplist = NULL;
drm_ht_remove(&dev->map_hash);
}
drm_ctxbitmap_cleanup(dev);
......
......@@ -53,6 +53,8 @@ static int drm_setup(drm_device_t * dev)
return ret;
}
dev->magicfree.next = NULL;
/* prebuild the SAREA */
i = drm_addmap(dev, 0, SAREA_MAX, _DRM_SHM, _DRM_CONTAINS_LOCK, &map);
if (i != 0)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册