summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/gallium/drivers/nouveau/nouveau_mm.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/gallium/drivers/nouveau/nouveau_mm.c b/src/gallium/drivers/nouveau/nouveau_mm.c
index 6c6d28c17f6..91532d7ec72 100644
--- a/src/gallium/drivers/nouveau/nouveau_mm.c
+++ b/src/gallium/drivers/nouveau/nouveau_mm.c
@@ -210,13 +210,13 @@ nouveau_mm_free(struct nouveau_mm_allocation *alloc)
mm_slab_free(slab, alloc->offset >> slab->order);
+ if (slab->free == slab->count) {
+ LIST_DEL(&slab->head);
+ LIST_ADDTAIL(&slab->head, &bucket->free);
+ } else
if (slab->free == 1) {
LIST_DEL(&slab->head);
-
- if (slab->count > 1)
- LIST_ADDTAIL(&slab->head, &bucket->used);
- else
- LIST_ADDTAIL(&slab->head, &bucket->free);
+ LIST_ADDTAIL(&slab->head, &bucket->used);
}
FREE(alloc);