Home | History | Annotate | Download | only in nouveau

Lines Matching full:heap

29 nouveau_heap_init(struct nouveau_heap **heap,
40 *heap = r;
45 nouveau_heap_destroy(struct nouveau_heap **heap)
47 if (!*heap)
49 free(*heap);
50 *heap = NULL;
54 nouveau_heap_alloc(struct nouveau_heap *heap, unsigned size, void *priv,
59 if (!heap || !size || !res || *res)
62 while (heap) {
63 if (!heap->in_use && heap->size >= size) {
68 r->start = (heap->start + heap->size) - size;
73 heap->size -= size;
75 r->next = heap->next;
76 if (heap->next)
77 heap->next->prev = r;
78 r->prev = heap;
79 heap->next = r;
85 heap = heap->next;