Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

The purpose of this page is to describe how the ARM MALI driver is integrated into Xilinx


Table of Contents

Table of Contents

Overview

Xilinx ZynqMPSoC has the MALI 400MP GPU from ARM. The ARM MALI 400MP is an OpenGLES 2.0 capable GPU.

Driver access and license

The driver for MALI 400MP consists of Linux kernel driver and user library. The user space library is proprietary licensed and will have to be distributed as binaries. The user space library will be provided through Xilinx PetaLinux release. The Linux kernel driver is GPL licensed, and downloadable from http://malideveloper.arm.com/. Until 2016.4, the kernel driver was hosted on Xilinx github. From 2017.1, the kernel driver hosted on Xilinx github is deprecated. This will now be downloaded from ARM website and packaged into the PetaLinux BSP.

...

Selecting particular backends:

You can select particular backend while configuring rootfs

File: project-spec/config/rootfs_config

Code Block
themeMidnight
petalinux-config -c rootfs
  1. Wayland/GBM backend:

    By default, plnx build system will try to package all the backends in the rootfs and depending upon the rootfs config, we create a link to the correct backend. Fbdev, X11, wayland and headless are the choices we have.

    For example: Once you have selected libmali through 'petalinux-config -c rootfs', select backend to wayland and unselect 'packagegroup-petalinux-matchbox' and 'packagegroup-petalinux-x11' and select 'packagegroup-petalinux-weston'. After selection your rootfs_config will look as below. 

    Code Block
    themeMidnight
    CONFIG_libmali-xlnx=y
    CONFIG_mali-backend-wayland=y

    This packagegroup ensures all the essential wayland/weston packages are packaged into the rootfs for having a wayland/weston application work out of the box. On boot, export following parameter in your terminal console.


    Code Block
    themeMidnight
    export XDG_RUNTIME_DIR=/run/


    Now, you can run sample benchmarking application glmark2-es2-wayland.

  2. X11 backend:

    By default, Mali supports X11 backend. Just select libmali-xlnx package from 'petalinux-config -c rootfs'. The root filesystem should now have libmali with X11 support. Also, please select at least one window manager. For example: packagegroup-petalinux-matchbox.

    Once you have selected libmali through 'petalinux-config -c rootfs', and selected backend to x11, your rootfs_config will look as below.


    Code Block
    themeMidnight
    CONFIG_libmali-xlnx=y
    CONFIG_mali-backend-x11=y


  3. Fbdev backend:

    Just select libmali-xlnx package from 'petalinux-config -c rootfs' and select fbdev backend.

    Once you have selected libmali through 'petalinux-config -c rootfs' unselect 'packagegroup-petalinux-matchbox' and 'packagegroup-petalinux-x11'. Your rootfs_config will look as below.


    Code Block
    themeMidnight
    CONFIG_libmali-xlnx=y
    CONFIG_mali-backend-fbdev=y


  4. Headless-EGL backend:

    Just select libmali-xlnx package from 'petalinux-config -c rootfs' and select headless backend. Unselect 'packagegroup-petalinux-matchbox' and 'packagegroup-petalinux-x11'.

    Once you have selected libmali through 'petalinux-config -c rootfs', and selected backend to headless, your rootfs_config will look as below.

    Code Block
    themeMidnight
    CONFIG_libmali-xlnx=y
    CONFIG_mali-backend-headless=y

    Please find more details for Headless rendering on below page.

    Mali 400 Headless rendering


Benchmark:

To run a benchmark example for x11 and wayland backend, please add below lines to build/conf/local.conf


Code Block
themeMidnight
IMAGE_INSTALL:append = "glmark2"


...