tizen 2.4 release
[kernel/linux-3.0.git] / drivers / gpu / arm / mali400 / r4p0_rel0 / linux / mali_memory_block_alloc.h
1 /*
2  * Copyright (C) 2010-2012 ARM Limited. All rights reserved.
3  * 
4  * This program is free software and is provided to you under the terms of the GNU General Public License version 2
5  * as published by the Free Software Foundation, and any use by you of this program is subject to the terms of such GNU licence.
6  * 
7  * A copy of the licence is included with the program, and can also be obtained from Free Software
8  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
9  */
10
11 #ifndef __MALI_BLOCK_ALLOCATOR_H__
12 #define __MALI_BLOCK_ALLOCATOR_H__
13
14 #include "mali_session.h"
15 #include "mali_memory.h"
16
17 #include "mali_memory_types.h"
18
19 typedef struct mali_mem_allocator mali_mem_allocator;
20
21 mali_mem_allocator *mali_block_allocator_create(u32 base_address, u32 cpu_usage_adjust, u32 size);
22 void mali_mem_block_allocator_destroy(mali_mem_allocator *allocator);
23
24 mali_mem_allocation *mali_mem_block_alloc(u32 mali_addr, u32 size, struct vm_area_struct *vma, struct mali_session_data *session);
25 void mali_mem_block_release(mali_mem_allocation *descriptor);
26
27 u32 mali_mem_block_allocator_stat(void);
28
29 #endif /* __MALI_BLOCK_ALLOCATOR_H__ */