Mali400

From Linux Rockchip
Jump to: navigation, search

Mali-400 MP (Mali400 for short) is a GPU (Graphics Processor Unit) from ARM Ltd. (ARM Holdings plc), designed for embedded systems.

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.

All Mali400 GPU Variants conform to OpenGL ES 1.1 & 2.0 as well as OpenVG 1.1.

Variants:

The Mali core grew out of the cores previously produced by Falanx and currently constitute:

Name GPU Cores CPU Level 2 cache size Rockchip implementations
Mali-400 MP 1 256 KiB rk2926 rk2928
Mali-400 MP4 4 256 KiB rk3066 rk3068 rk3188

More information can be found on the ARM website.

Driver

Binary driver

The Rockchip now releases the binary driver, you could find it from Rockchip Github. It has accompanied with the Debian packages script, you could build a Debian package easily.

If you want more manual way, please refer to the Mali binary driver on linux-sunxi wiki(not recommend). Take in mind that r3p2 is not supported by those drivers (athough r3p2-1_rel1 and r3p2-1_rel2 are).

GL ES fixes

If you want to run full KDE, some applications will complain about missing _mali_clz_lut function symbol. There is a workaround on linux-sunxi google group for this until an open source 3d driver stack has matured.

cat <<EOF > mali_clz_lut_dump.c
#include <stdio.h>
extern char _mali_clz_lut[256];
int main()
{
    int i;
    printf("char _mali_clz_lut[256] = {");
    for (i = 0; i != 256; i++) {
        if (i % 16 == 0) printf("\n    ");
        printf("%d, ", _mali_clz_lut[i]);
    }
    printf("\n};\n");
    return 0;
}
EOF

gcc mali_clz_lut_dump.c /usr/lib/libGLESv2.so
./a.out > fake_mali_clz_lut.c

sudo su
gcc -fPIC -shared -o /usr/lib/fake_mali_clz_lut.so fake_mali_clz_lut.c
echo "/usr/lib/fake_mali_clz_lut.so" >> /etc/ld.so.preload 

Lima driver (Open Source)

Lima is a project to develop a completely open source graphics driver which supports ARM's Mali-200 and Mali-400 GPUs. This is a work in progress and not yet ready for general use.

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.

See also

References

External Links


These contents are partially taken from linux-sunxi wiki, exactly at http://linux-sunxi/Mali400 under the terms stated at https://creativecommons.org/licenses/by/3.0/