Skip to content

lima: add prime import support

Qiang Yu requested to merge enunes:lima-4.13-prime into lima-4.13

Created by: enunes

This patchset adds prime support to the lima kernel driver. With this, it is possible to import buffers allocated in the display driver and exported with prime, enabling lima to render to a buffer that is being scanned to an output (such as HDMI).

Most of the initial commits in this series were not in linux 4.13 and were backported because they allow the sun4i-drm display driver to be used in the Allwinner A20, which is my test target. They define the reference device tree nodes that I used to port to the A20, along with a clock infrastructure change for the A20 which I found to be necessary to reduce the amount of work to make the sun4i-drm bindings to work on the A20.

This was finally tested with this application: https://github.com/enunes/mesa-test-programs/blob/master/gbm-bo-test.c It is also necessary to have the mesa-lima patches to enable prime support there.

Merge request reports