[PATCH v2 0/3] arm64: sunxi: a523: Enable Mali GPU

iuncuim posted 3 patches 2 months, 4 weeks ago
.../devicetree/bindings/gpu/arm,mali-bifrost.yaml |  1 +
arch/arm64/boot/dts/allwinner/sun55i-a523.dtsi    | 15 +++++++++++++++
.../boot/dts/allwinner/sun55i-a527-cubie-a5e.dts  |  5 +++++
.../boot/dts/allwinner/sun55i-h728-x96qpro+.dts   |  5 +++++
.../boot/dts/allwinner/sun55i-t527-avaota-a1.dts  |  5 +++++
.../dts/allwinner/sun55i-t527-orangepi-4a.dts     |  5 +++++
6 files changed, 36 insertions(+)
[PATCH v2 0/3] arm64: sunxi: a523: Enable Mali GPU
Posted by iuncuim 2 months, 4 weeks ago
From: Mikhail Kalashnikov <iuncuim@gmail.com>

This patch adds gpu support on devices with a523 processor.

$ dmesg | grep panfrost
[    3.826968] panfrost 1800000.gpu: clock rate = 432000000
[    3.832305] panfrost 1800000.gpu: bus_clock rate = 200000000
[    3.838353] panfrost 1800000.gpu: mali-g57 id 0x9091 major 0x0 minor 0x1
               status 0x0
[    3.846050] panfrost 1800000.gpu: features: 00000000,000019f7, issues:
               00000001,80000400
[    3.854134] panfrost 1800000.gpu: Features: L2:0x07110206 Shader:0x00000000
               Tiler:0x00000809 Mem:0x1 MMU:0x00002830 AS:0xff JS:0x7
[    3.866011] panfrost 1800000.gpu: shader_present=0x1 l2_present=0x1
[    3.874108] [drm] Initialized panfrost 1.3.0 for 1800000.gpu on minor 0

Since there is no support for image output yet, it may be difficult to confirm
functionality. This can be done by running weston with vnc access using
the command:
$ weston --renderer=gl --backend=vnc --disable-transport-layer-security
--xwayland --width=640 --height=480

After that I was able to run glmark2 with a terrain result of 30 fps,
while I can see that there is a load on the GPU in nvtop and the CPU remains
unloaded.

Tested on x96qproplus and walnutpi 2b devices.

Based on v6.16-rc5 with patches:
https://lore.kernel.org/all/20250628054438.2864220-1-wens@kernel.org
https://lore.kernel.org/linux-sunxi/20250628161608.3072968-1-wens@kernel.org
https://lore.kernel.org/linux-sunxi/20250627152918.2606728-1-wens@kernel.org/

Changes from v1:
- added compatible to the documentation
v1: https://lore.kernel.org/linux-sunxi/CAGb2v67Pu7CTJx3K=3CVSbQ9mNB-4Vrq+iaA+hUWtxdwS2aD0Q@mail.gmail.com

Mikhail Kalashnikov (3):
  dt-bindings: gpu: mali-bifrost: Add Allwinner A523 compatible
  arm64: dts: allwinner: a523: add Mali GPU node
  arm64: dts: allwinner: a523: enable Mali GPU for all boards

 .../devicetree/bindings/gpu/arm,mali-bifrost.yaml |  1 +
 arch/arm64/boot/dts/allwinner/sun55i-a523.dtsi    | 15 +++++++++++++++
 .../boot/dts/allwinner/sun55i-a527-cubie-a5e.dts  |  5 +++++
 .../boot/dts/allwinner/sun55i-h728-x96qpro+.dts   |  5 +++++
 .../boot/dts/allwinner/sun55i-t527-avaota-a1.dts  |  5 +++++
 .../dts/allwinner/sun55i-t527-orangepi-4a.dts     |  5 +++++
 6 files changed, 36 insertions(+)

-- 
2.50.0
Re: (subset) [PATCH v2 0/3] arm64: sunxi: a523: Enable Mali GPU
Posted by Chen-Yu Tsai 2 months, 3 weeks ago
On Fri, 11 Jul 2025 11:57:26 +0800, iuncuim wrote:
> From: Mikhail Kalashnikov <iuncuim@gmail.com>
> 
> This patch adds gpu support on devices with a523 processor.
> 
> $ dmesg | grep panfrost
> [    3.826968] panfrost 1800000.gpu: clock rate = 432000000
> [    3.832305] panfrost 1800000.gpu: bus_clock rate = 200000000
> [    3.838353] panfrost 1800000.gpu: mali-g57 id 0x9091 major 0x0 minor 0x1
>                status 0x0
> [    3.846050] panfrost 1800000.gpu: features: 00000000,000019f7, issues:
>                00000001,80000400
> [    3.854134] panfrost 1800000.gpu: Features: L2:0x07110206 Shader:0x00000000
>                Tiler:0x00000809 Mem:0x1 MMU:0x00002830 AS:0xff JS:0x7
> [    3.866011] panfrost 1800000.gpu: shader_present=0x1 l2_present=0x1
> [    3.874108] [drm] Initialized panfrost 1.3.0 for 1800000.gpu on minor 0
> 
> [...]

Applied to sunxi/dt-for-6.17 in local tree, thanks!

[2/3] arm64: dts: allwinner: a523: add Mali GPU node
      commit: 3d99e0dc888727a21b45ca64ff7b0cddbd17dd16
[3/3] arm64: dts: allwinner: a523: enable Mali GPU for all boards
      commit: d96d9ac8d2f197f31ea3de931dde1a217950f4ad

Best regards,
-- 
Chen-Yu Tsai <wens@csie.org>