Mali & UMP memory allocation
来源:互联网 发布:c语言math函数库 编辑:程序博客网 时间:2024/06/07 01:52
The MALI & UMP device drivers reside in driver/gpu directory:
Mali driver: gpu/mali/mali/linux/mali_kernel_linux.c.
It is a platform device, the driver name is "mali-utgard". (ls /sys/bus/platform/drivers),
the device name is "mali-utgard.0" (ls /sys/bus/platform/devices)
UMP driver: gpu/mali/ump/linux/ump_kernel_linux.c
It is a char device, the driver name is "ump", (ls sys/module/ump)
the device name is "ump", (ls /sys/devices/virtual)
Them mali $ UMP drivers both can be configured to allocate memory from
A. Dedicated memory
or
B. Share the Kernel memory
Below are related items in config, SparkPos project.
CONFIG_MALI_GPU=y //The Mali GPU is enabled.The mali driver does not reference this value at all.
CONFIG_MALI400=y //The GPU version.The mali driver does not reference this value at all.
CONFIG_MALI_OS_MEMORY=y //Share memory with Kernel.The mali driver does not reference this value at all.
CONFIG_MALI_MEMORY_SIZE=512 //size in MiB. The mali driver reference this value in gpu/mali/mali/platform/tcc-m400/mali_platform.c
shared_mem_size = CONFIG_MALI_MEMORY_SIZE * 1024UL * 1024UL
CONFIG_MALI400_PROFILING=y //mali driver reference this value directly
CONFIG_MALI_UMP=y //UMP is enable, The UMP driver does not reference this value at all.
CONFIG_UMP_OS_MEMORY=y //Share memory with Kernel. The UMP module further defines a macro "#define ARCH_UMP_BACKEND_DEFAULT 1"
//in gpu/mali/ump/arch/config.h
CONFIG_UMP_MEMORY_ADDRESS=0 //The UMP module further defines a macro
//"#define ARCH_UMP_MEMORY_ADDRESS_DEFAULT CONFIG_UMP_MEMORY_ADDRESS
//ingpu/mali/ump/arch/config.h
CONFIG_UMP_MEMORY_SIZE=64 //Size in MiB,The UMP module further defines a macro
//#define ARCH_UMP_MEMORY_SIZE_DEFAULT (CONFIG_UMP_MEMORY_SIZE * 1024UL * 1024UL)
//ingpu/mali/ump/arch/config.h
Below are related logs:
[ 1.070000] UMP<2>: Inserting UMP device driver. Compiled: Jul 7 2014, time: 17:56:26
[ 1.080000] UMP<2>: Using OS memory backend, allocation limit: 67108864 //64 MiB
[ 1.090000] UMP<2>: Using dedicated memory backend
[ 1.090000] UMP<2>: Requesting dedicated memory: 0x82000000, size: 28311552 //27 MiB, 0x1b0,0000
[ 1.100000] UMP: UMP device driver 1M loaded
[ 1.100000] Mali: Inserting Mali v20 device driver.
[ 1.110000] Mali: Compiled: Jun 28 2014, time: 14:41:58.
[ 1.110000] Mali: Driver revision: r3p2-01rel1-r1
[ 1.120000] Mali: Mali device driver loaded
It turns out that the UMP allocates 64MB memory from kernel memory via kmalloc() routine. At the mean time, UMP occupies 27MB dedicated memory (preserved by pmap) from 0x82000000 to 0x83b00000) . Reference function ump_kernel_constructor() in gpu/mali/ump/common/ump_kernel_common.c.
- Mali & UMP memory allocation
- kernel导致android无法启动的原因(ump,mali)
- Memory Allocation
- Memory allocation with strings
- DomUs and memory allocation
- Windows Memory Allocation Limitations
- Advanced Memory Allocation
- memory allocation manager
- Advanced Memory Allocation
- Dynamic memory allocation example
- C++: Custom memory allocation
- Kernel Memory Allocation
- Memory Allocation of C++
- Geeksquiz | Dynamic Memory Allocation
- memcache -- memory allocation
- KVM max memory allocation
- aligned memory allocation
- Mysql Memory Allocation
- Java Map
- 中科燕园gis外包案例之二---影像超市
- 15 个旅行中超级好用的小窍门!
- iOS通过iTunes search检测版本更新,并提示用户更新!
- Java对日期Date类进行加减运算,年份加减,月份加减
- Mali & UMP memory allocation
- [FOJ 2105][Vjudge 35179] Digits Count [线段树]
- ajax基础
- JavaScript学习笔记 第五记
- Android开发全程记录(十二)——ImageView 加边框的方法
- Java 多线程 原子性 Java编程思想读书笔记
- crawler4j源码分析(四)Parser
- python登陆Discuz!论坛通用代码
- php 解决MySQL插入数据出现 Incorrect string value: '\xF0\x9F\x92\x8BTi...'错误