Mali400
For information on how to install the OpenGLES (3D) driver for the Mali-400 GPU present on the Allwinner A10 and A13, please refer to the binary drivers installation guide. There does not seem to be much relevant information left in this page, only obscure background information.
Mali-400 MP (Mali400 for short) is a GPU (Graphics Processor Unit) from ARM Ltd. (ARM Holdings plc), designed for embedded systems.[1][2]
Contents |
Overview
The Mali series of Graphics Processing Units (GPUs) are semiconductor intellectual property cores produced by ARM Holdings for licensing in various ASIC (Application-specific integrated circuit) designs by ARM partners. The core is mainly developed by ARM Norway, at the former Falanx company site.
Like other embedded IP cores for 3D support, the Mali GPU does not feature display controllers driving monitors (such as the combination often found in common video cards). Instead it is a pure 3D engine that renders graphics into memory and hands the rendered image over to another core that handles the display.
ARM supplies tools to help in authoring OpenGL ES shaders named Mali GPU Shader Development Studio and Mali GPU User Interface Engine.
Variants:
The Mali core grew out of the cores previously produced by Falanx and currently constitute:
| Name | GPU Cores | CPU Level 2 cache size | API conformance | Reference |
|---|---|---|---|---|
| Mali-400 MP | 1 | 256 KiB | OpenGL ES 1.1 & 2.0, OpenVG 1.1 | [3] |
| Mali-400 MP2 | 2 | 256 KiB | OpenGL ES 1.1 & 2.0, OpenVG 1.1 | [4] |
More information can be found on the ARM website.
Allwinner implementations
Allwinner officially only supports the Mali GPU driver on the Android platform only. In this article we cover native Linux usage, (for Android refer to publicly available sources https://github.com/allwinnerwk https://github.com/allwinner-ics and many others).
The Mali GPU variants can be found in the following SoCs (systems on chips) by Allwinner:
Mali-400 MP in A1x
Allwinner A10 (sun7i), A10s (sun5i), and A13 (sun5i) SoCs all features a Single-Core Cortex-A8 ARM CPU and an single fragment shader (1GP tied to 1PP) Mali400 GPU from ARM.
Mali-400 MP2 in A20
Allwinner A20 (sun7i) SoC features a Dual-Core Cortex-A7 ARM CPU and a dual fragment shader (1GP tied to 2 PPs) Mali400 MP2 GPU from ARM.
Binary libraries download links
Mali-400 uses proprietary libraries that must be provided by SoC manufacturer. This libraries are built with Mali DDK in various variants defining supported APIs. Example: if VARIANT is mali400-vg-gles20-linux-ump, library will be built with support for OpenGL ES 2 and OpenVG.
Libraries depend on driver version, for each Mali-400 kernel module drivers update you need appropriate libraries version and appropriate X11/DRI2 drivers version. If this conditions will not be met, you will end with unsupported IOCTL's and basically unstable system.
Please keep in mind that we have Makefile installation system for libraries with detection of what kernel space drivers you have. It is located at https://github.com/linux-sunxi/mali-libs In driver installation section we use only mali-libs. Following table contains every Mali-400 library that we got from various sources. You can use it for your own risk, most stable stuff is always in mali-libs.
NOTE: In r3p0 and newer versions all symbols are contained within libMali.so and libUMP.so. The standard OpenGL libraries are just symlinks to libMali.so. Thus it might be tempting to just install libMali.so and libUMP.so and link your application against them. But that will not work. libMali tries to dlopen() libGLESv2.so.2.0 et. all. and without them it will just fail with a EGL_BAD_CONFIG (0x3005)
Mali-400 libraries breif table
| Version | Link | Build info from binary | Framebuffer support | X11 support | Android support |
|---|---|---|---|---|---|
| r2p4 armel | Download | BUILD=RELEASE ARCH=arch_011_udd PLATFORM=ca8 TRACE=0 THREAD= GEOM= CORES=MALI400 USING_MALI400=1 TARGET_CORE_REVISION=0x0101 TOPLEVEL_REPO_URL=Linux-r2p4-02rel0 REVISION=Linux-r2p4-02rel0 CHANGED_REVISION=Linux-r2p4-02rel0 REPO_URL=Linux-r2p4-02rel0 BUILD_DATE=2012a?? 03? 06? ? ? ? a? 11:10:03 CST CHANGE_DATE=Linux-r2p4-02rel0 TARGET_TOOLCHAIN=arm-linux-gcc-vfp HOST_TOOLCHAIN=gcc OPTS_TOOLCHAIN=arm-linux-gcc-vfp TARGET_TOOLCHAIN_VERSION=gcc version 4.5.2 (Sourcery G++ Lite 2011.03-41) HOST_TOOLCHAIN_VERSION=gcc version 4.4.3 (Ubuntu 4.4.3-4ubuntu5) OPTS_TOOLCHAIN_VERSION=gcc version 4.5.2 (Sourcery G++ Lite 2011.03-41) TARGET_SYSTEM=gcc-arm-vfp-linux HOST_SYSTEM=gcc-x86_64-linux CPPFLAGS= CUSTOMER=internal VARIANT=mali400-r1p1-gles11-gles20-linux-ump HOSTLIB=direct INSTRUMENTED=FALSE USING_MRI=FALSE MALI_TEST_API= UDD_OS=linux | Yes | No | No |
| r2p4 android | Download | BUILD=RELEASE ARCH=arch_011_udd PLATFORM=ca8 TRACE=0 THREAD= GEOM=mali_gp_geometry_common CORES=MALI400 USING_MALI400=1 TARGET_CORE_REVISION=0x0101 TOPLEVEL_REPO_URL=Linux-r2p4-02rel0 REVISION=Linux-r2p4-02rel0 CHANGED_REVISION=Linux-r2p4-02rel0 REPO_URL=Linux-r2p4-02rel0 BUILD_DATE=2012å¹´ 03æ 05æ ¥ æ æ ä¸ 10:06:13 CST CHANGE_DATE=Linux-r2p4-02rel0 TARGET_TOOLCHAIN=arm-linux-gcc-vfp HOST_TOOLCHAIN=gcc OPTS_TOOLCHAIN=arm-linux-gcc-vfp TARGET_TOOLCHAIN_VERSION=gcc version 4.5.2 (Sourcery G++ Lite 2011.03-41) HOST_TOOLCHAIN_VERSION=gcc version 4.4.3 (Ubuntu 4.4.3-4ubuntu5) OPTS_TOOLCHAIN_VERSION=gcc version 4.5.2 (Sourcery G++ Lite 2011.03-41) TARGET_SYSTEM=gcc-arm-vfp-linux HOST_SYSTEM=gcc-x86_64-linux CPPFLAGS= CUSTOMER=internal VARIANT=mali400-r1p1-gles11-gles20-linux-android-ics-rgb_is_xrgb-ump HOSTLIB=direct INSTRUMENTED=FALSE USING_MRI=FALSE MALI_TEST_API= UDD_OS=linux | No | No | Yes |
| r2p4 armhf | Download | BUILD=DEBUG ARCH=arch_011_udd PLATFORM=default_5te TRACE=0 THREAD= GEOM= CORES=MALI400 USING_MALI400=1 TARGET_CORE_REVISION=0x0101 TOPLEVEL_REPO_URL=Linux-r2p4-01dev0 REVISION=Linux-r2p4-01dev0 CHANGED_REVISION=Linux-r2p4-01dev0 REPO_URL=Linux-r2p4-01dev0 BUILD_DATE=Wed Jun 20 00:29:47 CST 2012 CHANGE_DATE=Linux-r2p4-01dev0 TARGET_TOOLCHAIN=gcc HOST_TOOLCHAIN=gcc OPTS_TOOLCHAIN=gcc TARGET_TOOLCHAIN_VERSION=gcc version 4.6.3 (Ubuntu/Linaro 4.6.3-1ubuntu5) HOST_TOOLCHAIN_VERSION=gcc version 4.6.3 (Ubuntu/Linaro 4.6.3-1ubuntu5) OPTS_TOOLCHAIN_VERSION=gcc version 4.6.3 (Ubuntu/Linaro 4.6.3-1ubuntu5) TARGET_SYSTEM=gcc-arm-linux-gnueabihf HOST_SYSTEM=gcc-arm-linux-gnueabihf CPPFLAGS= CUSTOMER=internal VARIANT=mali400-gles20-gles11-linux-x11-ump HOSTLIB=indirect INSTRUMENTED=FALSE USING_MRI=FALSE MALI_TEST_API= UDD_OS=linux | No | Yes | No |
| r3p0 armhf | Download | BUILD=DEBUG ARCH=arch_011_udd PLATFORM=default_7a TRACE=0 THREAD= GEOM= CORES=MALI400 USING_MALI400=1 TARGET_CORE_REVISION=0x0101 TOPLEVEL_REPO_URL=Linux-r3p0-04rel0 REVISION=Linux-r3p0-04rel0 CHANGED_REVISION=Linux-r3p0-04rel0 REPO_URL=Linux-r3p0-04rel0 BUILD_DATE=Wed Dec 12 01:20:06 CST 2012 CHANGE_DATE=Linux-r3p0-04rel0 TARGET_TOOLCHAIN=gcc HOST_TOOLCHAIN=gcc TARGET_TOOLCHAIN_VERSION=gcc version 4.6.3 (Ubuntu/Linaro 4.6.3-1ubuntu5) HOST_TOOLCHAIN_VERSION=gcc version 4.6.3 (Ubuntu/Linaro 4.6.3-1ubuntu5) TARGET_SYSTEM=gcc-arm-linux-gnueabihf HOST_SYSTEM=gcc-arm-linux-gnueabihf CPPFLAGS= CUSTOMER=internal VARIANT=mali400-vg-gles20-linux-ump HOSTLIB=indirect INSTRUMENTED=FALSE USING_MRI=FALSE MALI_TEST_API= UDD_OS=linux | No | Yes, but his version is known to have problems with OpenVG externs, please use next one instead. | No |
| r3p0 armhf | Download | BUILD=RELEASE ARCH=arch_011_udd PLATFORM=default_7a TRACE=0 THREAD= GEOM=mali_gp_geometry_common CORES=MALI400 USING_MALI400=1 TARGET_CORE_REVISION=0x0101 TOPLEVEL_REPO_URL=Linux-r3p0-04rel0 REVISION=Linux-r3p0-04rel0 CHANGED_REVISION=Linux-r3p0-04rel0 REPO_URL=Linux-r3p0-04rel0 BUILD_DATE=Tue Jan 1 00:00:13 CST 2013 CHANGE_DATE=Linux-r3p0-04rel0 TARGET_TOOLCHAIN=gcc HOST_TOOLCHAIN=gcc TARGET_TOOLCHAIN_VERSION=gcc version 4.6.3 (Ubuntu/Linaro 4.6.3-1ubuntu5) HOST_TOOLCHAIN_VERSION=gcc version 4.6.3 (Ubuntu/Linaro 4.6.3-1ubuntu5) TARGET_SYSTEM=gcc-arm-linux-gnueabihf HOST_SYSTEM=gcc-arm-linux-gnueabihf CPPFLAGS= CUSTOMER=internal VARIANT=mali400-gles11-gles20-linux-ump HOSTLIB=direct INSTRUMENTED=FALSE USING_MRI=FALSE MALI_TEST_API= UDD_OS=linux | Yes | No | No |
| r3p0 armhf | Download | BUILD=DEBUG ARCH=arch_011_udd PLATFORM=default_7a TRACE=0 THREAD= GEOM= CORES=MALI400 USING_MALI400=1 TARGET_CORE_REVISION=0x0101 TOPLEVEL_REPO_URL=Linux-r3p0-04rel0 REVISION=Linux-r3p0-04rel0 CHANGED_REVISION=Linux-r3p0-04rel0 REPO_URL=Linux-r3p0-04rel0 BUILD_DATE=Wed Dec 12 00:21:41 CST 2012 CHANGE_DATE=Linux-r3p0-04rel0 TARGET_TOOLCHAIN=gcc HOST_TOOLCHAIN=gcc TARGET_TOOLCHAIN_VERSION=gcc version 4.6.3 (Ubuntu/Linaro 4.6.3-1ubuntu5) HOST_TOOLCHAIN_VERSION=gcc version 4.6.3 (Ubuntu/Linaro 4.6.3-1ubuntu5) TARGET_SYSTEM=gcc-arm-linux-gnueabihf HOST_SYSTEM=gcc-arm-linux-gnueabihf CPPFLAGS= CUSTOMER=internal VARIANT=mali400-gles20-gles11-linux-x11-ump-no_monolithic HOSTLIB=indirect INSTRUMENTED=FALSE USING_MRI=FALSE MALI_TEST_API= UDD_OS=linux | No | Yes, but missing various symbols. | No |
| r3p0 android | Download | No build info compiled in. | No | No | Yes |
| r3p0 armhf | Download | BUILD=RELEASE ARCH=arch_011_udd PLATFORM=default_7a TRACE=0 THREAD= GEOM=mali_gp_geometry_common CORES=MALI400 USING_MALI400=1 TARGET_CORE_REVISION=0x0101 TOPLEVEL_REPO_URL=Linux-r3p0-04rel0 REVISION=Linux-r3p0-04rel0 CHANGED_REVISION=Linux-r3p0-04rel0 REPO_URL=Linux-r3p0-04rel0 BUILD_DATE=Thu Dec 13 00:22:45 CST 2012 CHANGE_DATE=Linux-r3p0-04rel0 TARGET_TOOLCHAIN=gcc HOST_TOOLCHAIN=gcc TARGET_TOOLCHAIN_VERSION=gcc version 4.6.3 (Ubuntu/Linaro 4.6.3-1ubuntu5) HOST_TOOLCHAIN_VERSION=gcc version 4.6.3 (Ubuntu/Linaro 4.6.3-1ubuntu5) TARGET_SYSTEM=gcc-arm-linux-gnueabihf HOST_SYSTEM=gcc-arm-linux-gnueabihf CPPFLAGS= CUSTOMER=internal VARIANT=mali400-gles20-gles11-linux-x11-ump HOSTLIB=direct INSTRUMENTED=FALSE USING_MRI=FALSE MALI_TEST_API= UDD_OS=linux | No | Yes | No |
| r3p1 armhf | Download | BUILD=RELEASE ARCH=arch_011_udd PLATFORM=default_7a TRACE=0 THREAD= GEOM=mali_gp_geometry_common CORES=MALI400 USING_MALI400=1 TARGET_CORE_REVISION=0x0101 TOPLEVEL_REPO_URL=Linux-r3p1-01rel0 REVISION=Linux-r3p1-01rel0 CHANGED_REVISION=Linux-r3p1-01rel0 REPO_URL=Linux-r3p1-01rel0 BUILD_DATE=Wed Dec 12 00:13:50 CST 2012 CHANGE_DATE=Linux-r3p1-01rel0 TARGET_TOOLCHAIN=gcc HOST_TOOLCHAIN=gcc TARGET_TOOLCHAIN_VERSION=gcc version 4.6.3 (Ubuntu/Linaro 4.6.3-1ubuntu5) HOST_TOOLCHAIN_VERSION=gcc version 4.6.3 (Ubuntu/Linaro 4.6.3-1ubuntu5) TARGET_SYSTEM=gcc-arm-linux-gnueabihf HOST_SYSTEM=gcc-arm-linux-gnueabihf CPPFLAGS= CUSTOMER=internal VARIANT=mali400-gles11-gles20-linux-ump HOSTLIB=direct INSTRUMENTED=FALSE USING_MRI=FALSE MALI_TEST_API= UDD_OS=linux | Yes | No | No |
| r3p1 armhf | Download | BUILD=RELEASE ARCH=arch_011_udd PLATFORM=default_7a TRACE=0 THREAD= GEOM=mali_gp_geometry_common CORES=MALI400 USING_MALI400=1 TARGET_CORE_REVISION=0x0101 TOPLEVEL_REPO_URL=Linux-r3p1-01rel0 REVISION=Linux-r3p1-01rel0 CHANGED_REVISION=Linux-r3p1-01rel0 REPO_URL=Linux-r3p1-01rel0 BUILD_DATE=Thu Dec 13 00:40:12 CST 2012 CHANGE_DATE=Linux-r3p1-01rel0 TARGET_TOOLCHAIN=gcc HOST_TOOLCHAIN=gcc TARGET_TOOLCHAIN_VERSION=gcc version 4.6.3 (Ubuntu/Linaro 4.6.3-1ubuntu5) HOST_TOOLCHAIN_VERSION=gcc version 4.6.3 (Ubuntu/Linaro 4.6.3-1ubuntu5) TARGET_SYSTEM=gcc-arm-linux-gnueabihf HOST_SYSTEM=gcc-arm-linux-gnueabihf CPPFLAGS= CUSTOMER=internal VARIANT=mali400-gles20-gles11-linux-x11-ump HOSTLIB=direct INSTRUMENTED=FALSE USING_MRI=FALSE MALI_TEST_API= UDD_OS=linux | No | Yes | No |
Lima open source Mali driver
Lima is a project to develop a completely open source graphics driver which supports ARM's Mali-200 and Mali-400 GPUs (work in progress).
The aim of this driver and others such as freedreno is to finally bring all the advantages of open source software to ARM SoC graphics drivers. Currently, the sole availability of binary drivers is increasing development and maintenance overhead, while also reducing portability, compatibility and limiting choice. Anyone who has dealt with GPU support on ARM, be it for a linux with a GNU stack, or for an android, knows the pain of dealing with these binaries.
Mali-400 X11 DRI2 drivers
For information on how to install the OpenGLES (3D) driver for the Mali-400 GPU present on the Allwinner A10 and A13, please refer to the binary drivers installation guide.
Some demo of these drivers is available on the youtube http://www.youtube.com/watch?v=tyR3Wqw5yZ0
Tips on building
- Some distributions have libdri2 compiled in X11 binary, so there is libdri2 separated in a github repo https://github.com/robclark/libdri2
API Info
APIs reported by es1_info:
EGL_VERSION: 1.4 Linux-r3p0-04rel0
EGL_VENDOR: ARM
EGL_EXTENSIONS:
EGL_KHR_image, EGL_KHR_image_base, EGL_KHR_image_pixmap,
EGL_KHR_gl_texture_2D_image, EGL_KHR_gl_texture_cubemap_image,
EGL_KHR_gl_renderbuffer_image, EGL_KHR_reusable_sync, EGL_KHR_fence_sync,
EGL_KHR_lock_surface, EGL_KHR_lock_surface2
EGL_CLIENT_APIS: OpenGL_ES
GL_VERSION: OpenGL ES-CM 1.1
GL_RENDERER: Mali-400 MP
GL_EXTENSIONS:
GL_OES_byte_coordinates, GL_OES_fixed_point, GL_OES_single_precision,
GL_OES_matrix_get, GL_OES_read_format, GL_OES_compressed_paletted_texture,
GL_OES_point_size_array, GL_OES_point_sprite, GL_OES_texture_npot,
GL_OES_query_matrix, GL_OES_matrix_palette,
GL_OES_extended_matrix_palette, GL_OES_compressed_ETC1_RGB8_texture,
GL_OES_EGL_image, GL_OES_draw_texture, GL_OES_depth_texture,
GL_OES_packed_depth_stencil, GL_EXT_texture_format_BGRA8888,
GL_OES_framebuffer_object, GL_OES_stencil8, GL_OES_depth24, GL_ARM_rgba8,
GL_OES_EGL_image_external, GL_OES_EGL_sync,
GL_EXT_multisampled_render_to_texture, GL_OES_texture_cube_map,
GL_EXT_discard_framebuffer
APIs reported by es2_info:
EGL_VERSION: 1.4 Linux-r3p0-04rel0
EGL_VENDOR: ARM
EGL_EXTENSIONS:
EGL_KHR_image, EGL_KHR_image_base, EGL_KHR_image_pixmap,
EGL_KHR_gl_texture_2D_image, EGL_KHR_gl_texture_cubemap_image,
EGL_KHR_gl_renderbuffer_image, EGL_KHR_reusable_sync, EGL_KHR_fence_sync,
EGL_KHR_lock_surface, EGL_KHR_lock_surface2
EGL_CLIENT_APIS: OpenGL_ES
GL_VERSION: OpenGL ES 2.0
GL_RENDERER: Mali-400 MP
GL_EXTENSIONS:
GL_OES_texture_npot, GL_OES_compressed_ETC1_RGB8_texture,
GL_OES_standard_derivatives, GL_OES_EGL_image, GL_OES_depth24,
GL_ARM_rgba8, GL_ARM_mali_shader_binary, GL_OES_depth_texture,
GL_OES_packed_depth_stencil, GL_EXT_texture_format_BGRA8888,
GL_EXT_blend_minmax, GL_OES_EGL_image_external, GL_OES_EGL_sync,
GL_EXT_multisampled_render_to_texture, GL_EXT_discard_framebuffer,
GL_OES_get_program_binary, GL_EXT_shader_texture_lod
TODO for developers
- Make Mali-400 kernel drivers output the version on load
- Figure out permissions problems for popular distros (udev rule?)
- Integrate G2D support for 2D acceleration, right now Mali drivers sometimes are slower than FBDEV in 2D tasks. Example of EXA integration with 2D acceleration from qualcomm: https://www.codeaurora.org/gitweb/quic/xwin/?p=xf86-video-msm.git;a=blob;f=src/msm-exa-c2d.c;hb=refs/heads/chromium
- Integrate Sunxi_disp_driver support
- Integrate EDID support for HDMI/DVI connections (dynamic resolution detection)
- (OPTIONAL) Toss out libump and ump kernel module, Mali-400 modules can directly use OS RAM if needed (or check Snowball for this, they use /dev/hwmem device that gives 16MB of RAM to Mali)
See also
References
- ↑ http://www.cnx-software.com/2013/01/19/gpus-comparison-arm-mali-vs-vivante-gcxxx-vs-powervr-sgx-vs-nvidia-geforce-ulp/ GPUs Comparison: ARM Mali vs Vivante GCxxx vs PowerVR SGX vs Nvidia Geforce ULP
- ↑ http://blog.thinkteletronics.com/all-mobile-socsolutions/ All Mobile Soc/Solutions.
- ↑ Mali-400 Webpage; Arm Holdings.
- ↑ Mali-400 Webpage; Arm Holdings.