diff options
author | Ben Skeggs <bskeggs@redhat.com> | 2009-03-01 20:13:04 -0500 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2009-04-24 01:08:41 -0400 |
commit | 30ddbd94401a132f4d932775d1902b3c9a8c41b5 (patch) | |
tree | f3876e98de6c9969057e99cbd30df1805a9f30ca /drivers/gpu/drm/drm_stub.c | |
parent | 400138bc8b9fca66d7d40511eaed2dc3a75426c8 (diff) |
drm: clean the map list before destroying the hash table
The hash tables contains some of the mapping
so its really nice to have it for the deletion phase.
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/drm_stub.c')
-rw-r--r-- | drivers/gpu/drm/drm_stub.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/gpu/drm/drm_stub.c b/drivers/gpu/drm/drm_stub.c index ef878615c49f..e8c2fd4c5e65 100644 --- a/drivers/gpu/drm/drm_stub.c +++ b/drivers/gpu/drm/drm_stub.c | |||
@@ -502,11 +502,11 @@ void drm_put_dev(struct drm_device *dev) | |||
502 | dev->agp = NULL; | 502 | dev->agp = NULL; |
503 | } | 503 | } |
504 | 504 | ||
505 | drm_ht_remove(&dev->map_hash); | ||
506 | drm_ctxbitmap_cleanup(dev); | ||
507 | |||
508 | list_for_each_entry_safe(r_list, list_temp, &dev->maplist, head) | 505 | list_for_each_entry_safe(r_list, list_temp, &dev->maplist, head) |
509 | drm_rmmap(dev, r_list->map); | 506 | drm_rmmap(dev, r_list->map); |
507 | drm_ht_remove(&dev->map_hash); | ||
508 | |||
509 | drm_ctxbitmap_cleanup(dev); | ||
510 | 510 | ||
511 | if (drm_core_check_feature(dev, DRIVER_MODESET)) | 511 | if (drm_core_check_feature(dev, DRIVER_MODESET)) |
512 | drm_put_minor(&dev->control); | 512 | drm_put_minor(&dev->control); |