]> git.karo-electronics.de Git - mv-sheeva.git/blobdiff - drivers/gpu/drm/drm_hashtab.c
drm/radeon: Fix 3 regressions - since buffer rework
[mv-sheeva.git] / drivers / gpu / drm / drm_hashtab.c
index ac35145c3e20b279e7b17c1bdf40e9f442fc4fe1..f36b21c5b2e1501ac3950b7d4521e00570f93558 100644 (file)
@@ -46,8 +46,7 @@ int drm_ht_create(struct drm_open_hash *ht, unsigned int order)
        ht->table = NULL;
        ht->use_vmalloc = ((ht->size * sizeof(*ht->table)) > PAGE_SIZE);
        if (!ht->use_vmalloc) {
-               ht->table = drm_calloc(ht->size, sizeof(*ht->table),
-                                      DRM_MEM_HASHTAB);
+               ht->table = kcalloc(ht->size, sizeof(*ht->table), GFP_KERNEL);
        }
        if (!ht->table) {
                ht->use_vmalloc = 1;
@@ -200,8 +199,7 @@ void drm_ht_remove(struct drm_open_hash *ht)
                if (ht->use_vmalloc)
                        vfree(ht->table);
                else
-                       drm_free(ht->table, ht->size * sizeof(*ht->table),
-                                DRM_MEM_HASHTAB);
+                       kfree(ht->table);
                ht->table = NULL;
        }
 }