We're hiring!

A helping Arm for Panfrost

Daniel Stone avatar

Daniel Stone
July 20, 2023

Share this post:

Reading time:

Collabora's raison d'être has always been simple: accelerate the adoption of Open Source technologies, methodologies & philosophy. This was our founding principle when the company was formed by the founders of the Telepathy and Farstream projects to enable open-source cross-vendor instant messaging, and the company fit around a cafe table. 18 years down the road, with Collabora having grown from three people to three digits, we continue to apply the same principle through our ongoing work across the ecosystem on the Linux kernel, U-Boot, Wayland, Mesa, GStreamer, PipeWire, Monado, WebKit, D-Bus, and more: relentlessly shifting the needle to make high-quality open-source software not just an aspiration, but an expectation.

Today we're pleased to announce an extension of our collaboration with Arm, providing more surety and capability for Panfrost. But apart from making Panfrost better, faster, and stronger, what does it mean? And apart from being a mainline open-source solution to support graphics acceleration on Arm's Mali GPU family, what is Panfrost? Read on for more. (Or, if you're impatient, the answer is that Arm's ongoing long-term support for our work on Panfrost means that you'll have conformant and performant out-of-the-box open-source support for any system you buy with an Arm Mali SoC. Your choice.)

A driver is brewing

When I started at Collabora 15 years ago, I was working on X11, bringing as much capability to it as we could to match the demands of 'modern' systems. We pretty quickly realised we'd hit a wall: it wasn't possible to ship an X11-based system without paying for custom development to make it acceptably fast. As a consultancy, the repeated revenue was good, in a way. For the ecosystem though, it was terrible. Requiring that people paid a consultancy to have a viable display system was an indication that something was badly broken. This is why we jumped on the nascent Wayland project, with some work paid but much unfunded. We wanted to raise the bar and bootstrap the ecosystem, so that everyone could expect a high-quality display system out of the box, for free, and focus on solving more interesting problems.

Panfrost has been on a similar journey. Back in 2017, Alyssa Rosenzweig bootstrapped the chai repository as a summer project to reverse-engineer the Midgard generation of Arm Mali GPUs. Through 2018, her work started to develop into a fully-fledged Mesa driver to support OpenGL ES, together with a kernel driver originally written by Marty Plummer. We sensed a great moment to help, and stuck our shoulder to the wheel: on the stroke of 2019, Tomeu Vizoso started to flesh the kernel driver out into the full-blown Panfrost DRM driver that still lives in the upstream kernel today, soon joined by Boris Brezillon and others. In the summer of 2019, Alyssa joined Collabora, as we decided to fully sponsor the project and push it forward as much as possible. This work bore great fruit, as through the year Panfrost was able to bring up GNOME for the first time, with many conformance and performance improvements.

There's not a lot to be said for the year 2020, however this was the year when Arm first threw its support behind Panfrost as a project, providing us with the support we needed to bring Bifrost to production quality. This was not only a novel and difficult architecture to develop for, but introducing the second architecture resulted in a great number of internal driver cleanups and reorganisations which set us on a much better path for the future.

Open by default

Throughout the past three years, we have been heads-down working away on Panfrost and growing our team. We now support three full architectural generations in Midgard, Bifrost, and Valhall, in our upstream drivers. These drivers are shipped by default in various distributions and builds, and ... it just works. We've gone from being able to identify our users by name, to knowing which groups of people used Panfrost, to it being so widespread that the group is 'everyone'. Even though it's not forging thrilling new ground, a lot of excellent engineering work has gone into making Panfrost so usable as to be unremarkable.

Our approach is the same here as it is everywhere. AngeloGioacchino's work on upstream kernel support for MediaTek devices, and the work done by many Collaborans to upstream support for Rockchip's RK3588 SoC, will have the same outcome: your device just works with a mainline kernel. The work done by our KernelCI team means that we won't fall back on that support. The work done by our Mesa CI team to first introduce hardware testing, and now run conformance, real-world trace, and performance, workloads as part of pre-merge Mesa CI means that it won't regress either. And this is all underpinned by our cast of LAVA developers as well as the team who manage our test lab of hundreds of machines in Cambridge.

All this work behind the scenes is why you don't always hear so much from us, because we're working in the background to make sure that you don't need to think about every single piece of the puzzle. You know it just works, and you can go on to solving the problem you actually wanted to solve in the first place.

Building for the future

We're thrilled to not only have Arm's continued support, but increased long-term backing. Arm's aims are the same as ours: to ensure that Mali GPUs will continue to work well upstream, and to continue closing the gap so that this support is available earlier, works better, and is faster. A closer collaboration between our two teams means that we can achieve these goals much more efficiently than we could previously. This backing allows us and you - the community as well as the reader - to confidently plan for long-term support of Mali GPUs upstream.

Some of the quiet background work has involved a lot of preparation for the 10th-generation Mali cores, aka third-generation Valhall. This generation introduces a new command stream frontend for job scheduling and synchronisation. Whilst it offers a lot of exciting new capabilities, we have needed to do a huge amount of work under the hood to make this happen and support these Valhall (and beyond) GPUs. The Panfrost team have been busily working on this for a long time now, and it is finally coming to fruition, with a solid and credible driver approaching upstream readiness.

One of the things enabled by the new architecture, and Arm's closer backing, is a Vulkan driver for these cores. Being natively architected for Vulkan, these modern GPUs make it far easier to support Vulkan for modern, high-performance, workloads. Our team has begun work on a Vulkan driver aimed at this new architecture, so we can provide high-quality Vulkan support alongside our existing proven OpenGL and OpenGL ES support, as well as our more experimental support for OpenCL.

Looking to the future, we're also excited by some of the capability this new hardware and driver architecture enables, such as direct command submission from userspace to support low-latency, high-performance, workloads. It will be a lot of work there, but the building blocks we're putting in place today are opening up these possibilities for the future.

Credit where credit's due

Although Collabora has long been committed to Panfrost and contributed the vast majority of its work, we are indebted to everyone around us for making it possible.

First, to the initial community of Alyssa, Marty, Connor Abbott, Lyude Paul, Ryan Houdek, and others, for tilting at an impossible windmill with their incredible initial reverse-engineering work. Secondly, to the wider community that has since sprung up around Panfrost, providing not only improvements, fixes, and testing, but also their evangelism to ensure everyone knew about this high-quality open-source driver. Thirdly, to the wider ecosystem including projects like Kodi and LibreELEC in particular, for not only giving us sharp focus and goals, but also pushing it to their users. Further, we are standing on the shoulders of giants: without the incredible work that went into Mesa and the DRI/DRM ecosystem dating back to the late 90s, continuing all the way to Gallium3D, NIR, and the modern kernel DRM subsystem.

Without all this work from a cast of thousands, it would not be possible for Panfrost to be more than a proof of concept - much less a high-quality reliable solution now with the generous backing and support of Arm themselves.


Comments (3)

  1. Razze:
    Jul 22, 2023 at 01:31 PM

    Seems like that kernelci.org link doesn't like to be used with www in front. At least Firefox doesn't trust it, but it's fine without the www

    Reply to this comment

    Reply to this comment

  2. ALfred:
    Jul 26, 2023 at 06:33 PM

    Great so this means we will have MESA support with ARM Mali G610 present in RK3588?

    Reply to this comment

    Reply to this comment

  3. PojavLauncher Player shadyfy:
    Apr 23, 2024 at 11:40 PM

    This Panforst-driver is too strong. I hope it will develop and flourish in the future! As an ordinary user who uses MediaTek-D8100 processor, there are some questions I want to know:

    1、Does this mean that the Redmi-k50 mobile-phone with Mali-G610 will also have Panforst to replace the The ARM-Official R32P1 of the Non-Updatable ancient driver?

    2、For this New-Panforst driver with high efficiency to be released soon, As a mobile phone player of MediaTek D8100 processor, when can you experience the high efficiency performance of the driver on a real machine? On the Baidu-Tieba platform in China, some geeks have posted that this driver will support OpenGL 4.6 natively, is this possible?Will this Panforst-Driver support the more comprehensive Vulkan 1.3 when it is released, or will it continue to support only Vulkan 1.2?




    Reply to this comment

    Reply to this comment

Add a Comment

Allowed tags: <b><i><br>Add a new comment:


Search the newsroom

Latest News & Events

Kernel 6.10: Keep the updates coming


The latest kernel 6.10 release brings multiple core changes and updates to BH workqueues. Let's examine the developments implemented by…

Taming the Panthor: OpenGL ES 3.1 conformance achieved on Mali-G610


The Panthor kernel driver and Mesa Panfrost driver combination has achieved official conformance for OpenGL ES 3.1 on the Mali-G610 chip,…

ElectricMaple: Remote-rendering debuts at AWE 2024


Making its debut this week at Augmented World Expo (AWE) in Long Beach, ElectricMaple is an innovative project by Collabora and PlutoVR…

Open Since 2005 logo

Our website only uses a strictly necessary session cookie provided by our CMS system. To find out more please follow this link.

Collabora Limited © 2005-2024. All rights reserved. Privacy Notice. Sitemap.