From 7533724d29d13cde4f8b839ec066c5941a6674c8 Mon Sep 17 00:00:00 2001 From: Rebecca Schultz Zavin Date: Wed, 13 Feb 2013 14:48:11 -0800 Subject: gpu: ion: Make ion_free asynchronous Add the ability for a heap to free buffers asynchrounously. Freed buffers are placed on a free list and freed from a low priority background thread. If allocations from a particular heap fail, the free list is drained. This patch also enable asynchronous frees from the chunk heap. Change-Id: Idfdbc8608b6cbd9e27d2e31ea4fd84fea9f69f7d Signed-off-by: Rebecca Schultz Zavin --- drivers/gpu/ion/ion_system_heap.c | 1 + 1 file changed, 1 insertion(+) (limited to 'drivers/gpu/ion/ion_system_heap.c') diff --git a/drivers/gpu/ion/ion_system_heap.c b/drivers/gpu/ion/ion_system_heap.c index c1061a801a4..6369fe8f305 100644 --- a/drivers/gpu/ion/ion_system_heap.c +++ b/drivers/gpu/ion/ion_system_heap.c @@ -283,6 +283,7 @@ struct ion_heap *ion_system_heap_create(struct ion_platform_heap *unused) return ERR_PTR(-ENOMEM); heap->heap.ops = &system_heap_ops; heap->heap.type = ION_HEAP_TYPE_SYSTEM; + heap->heap.flags = ION_HEAP_FLAG_DEFER_FREE; heap->pools = kzalloc(sizeof(struct ion_page_pool *) * num_orders, GFP_KERNEL); if (!heap->pools) -- cgit v1.2.3-70-g09d2