Skip to content

lima: add renderonly-based support for lima sun4i-drm

Qiang Yu requested to merge enunes:lima-17.2-sun4i-renderonly into lima-17.2

Created by: enunes

A mesa driver for sun4i-drm is defined which will call into lima when 3D rendering is requested from it. This uses the renderonly library from mesa, which hides the buffer sharing details between the two drivers from the application. This allows applications that expect a single device node like /dev/dri/card0 (such as kmscube) to run unmodified on Allwinner devices that use the sun4i-drm driver for display and have a Mali400 gpu using lima.

This follows the model of the vc4+pl111 drivers existing in mesa. The code implemented here is mostly borrowed from that particular implementation.

The driver is called sun4i in mesa and it will intentionally generate sun4i-drm_dri.so. This is because mesa will look for a *_dri.so user space driver named after the corresponding kernel driver, which in this case is called sun4i-drm.

Signed-off-by: Erico Nunes nunes.erico@gmail.com

Merge request reports

Loading