GPU acceleration with SPI displays (STM32MP157 with Vivante GPU)
Lucas Stach
l.stach at pengutronix.de
Mon Aug 4 09:59:21 UTC 2025
Hi Josef,
Am Freitag, dem 01.08.2025 um 13:06 +0200 schrieb Josef Luštický:
> Hello,
> I am trying to get GPU acceleration to work with SPI display using
> ili9225_dri.so,
> and I use kmscube to test.
> The SoC is STM32MP157c with Vivante GC400 GPU and I use Mesa3D 24.0.9
> (rootfs generated with Buildroot 2025.02.3) and kernel 5.10.176 (from
> STM).
>
> I also have the same system with MIPI Display attached.
> While kmscube renders at 60 fps with the MIPI Display system, I get
> only 11 fps with the SPI display. Apart from that both systems are the
> same.
The question is what can you expect from a SPI display? SPI is not a
great interface for isochronous traffic with quite high bandwidth
demands. Even at really low resolutions you need a lot of bandwidth to
update a display. What is the resolution and color depth of you
display? How fast is your SPI connection?
You might run modetest -v to get a reference point on how fast the
display can be updated without any GPU rendering going on.
Regards,
Lucas
>
> I checked the output of kmscube and it prints the exact same extensions on both,
> the only difference is the framerate.
> I also checked output of kmscube's /proc/PID/maps and the only
> difference is that with MIPI Display it loads /usr/lib/dri/stm_dri.so
> while with the SPI Display it loads /usr/lib/dri/ili9225_dri.so,
> but I see those files are the same (hardlinks).
> Both open /dev/dri/renderD128 (GPU).
>
> Why am I getting just 11 fps on the system with SPI Display?
> Is there some architectural limitation, either in Mesa, kernel, or HW-related?
> I suppose both setups use kernel's KMS as renderer only (kmsro), thus
> it should render at the same framerate.
> The difference in HW is the peripheral the displays use - LTDC
> (stm_dri.so) vs. SPI (eventually ili9225_dri.so).
> Why do I see no /usr/lib/etnaviv_dri.so loaded?
>
> The MIPI Display is attached to the LTDC (LCD Timing Display
> Controller) peripheral of the STM SoC and the display driver is
> drivers/gpu/drm/panel/panel-sitronix-st7703.c (DRM panel).
>
> The SPI display driver uses the kernel's TinyDRM API and its driver is
> drivers/gpu/drm/tiny/ili9225.c.
>
> I also tried softpipe (disabled GPU in device-tree) and it renders 7
> fps on both systems.
>
> I attach the output from kmscube on the SPI Display system (the MIPI
> Display is the same except framerate is 60 fps.)
>
> Kind regards
> Josef Lusticky
More information about the mesa-dev
mailing list