Re: [Buildroot] [PATCH 4/7] package/mali-bifrost-driver: new package
From: Giulio Benetti <giulio.benetti@benettiengineering.com>
Date: 2021-12-30 16:45:59
On 30/12/21 17:08, Thomas Petazzoni wrote:
Hello, On Thu, 30 Dec 2021 16:28:57 +0100 Giulio Benetti [off-list ref] wrote:quoted
I had no chance to test it on real hardware for lack of time :-/ so I don't know if it works, and it should not be expected to work. I've compared r8 version of midgard against bifrost and they are pretty different.I'm pretty sure it works, since I've seen myself the patches from Miquèl allowing to run Qt5/OpenGL on a Rockchip PX30 platform. I'm questioning the terminology/choice of naming.
Ok. Probably Midgard and Bifrost have lot in common on driver side and that's why it works. PX30 has a G31-2EE which is a Bifrost: https://developer.arm.com/ip-products/graphics-and-multimedia/mali-gpus/mali-g31-gpu So ok, it works but it should be changed. What I can do is providing the bifrost driver with the patches for Midgard ported against Bifrost and ask the PR. But I don't have time to test and I don't have a working PX30 BR defconfig for PX30-Mini-Evb or Engicam PX30 board that I wanted to provide.
quoted
I'm working on this patchset in spare time[1] with the goal to create a single mali-driver package to deal with Utgard, Midgard and Bifrost. I've already requested to change repository name from mali-bifrost-driver to mali-driver and it's been done plus merging patches to allow building with up to Linux 5.15[2].Ah, we did this rename?
Yes: https://github.com/bootlin/mali-driver
quoted
Thomas, do you want me to send the v2 patchset in[1] to Buildroot mailing list? It's not complete at all, but it's some step forward.I'm a bit lost with all these renames. We already have sunxi-mali-mainline-driver in the tree, which points to https://github.com/mripard/sunxi-mali. I'm not sure which kernel driver handles which GPU variant.
mripard/sunxi-mali[1] only deals with Mali Utgard for Sunxi. The problem is that the mripard/sunxi-mali has a specific platform implementation for sunxi: https://github.com/mripard/sunxi-mali/blob/master/patches/0005-mali-Add-sunxi-platform.patch While bootlin/mali-driver[2] doesn't have any platform-specific implementation. As you've pointed you've tested PX30(Bifrost G31) and it works, so that means that G31 doesn't need any specific platform-specific implementations. BUT there is CONFIG_MALI_PLATFORM_NAME that can be used to point to platform-specific implementation(i.e. sunxi): https://github.com/bootlin/mali-driver/blob/master/r8p0/drivers/gpu/arm/midgard/Kconfig#L72-L79 So what we can do is to add that Sunxi implementation to r6p2 and r8p1 while adding them to bootlin/mali-driver[2] and remove the actual sunxi-mali-mainline-driver BR package. That way we will end up(for the moment) with these packages: A1) mali-driver => with all Utgard(Sunxi platform included), Midgard, Bifrost versions. A2) sunxi-mali-mainline => that should change into sunxi-mali-utgard, check pending patches[3] for this. And as a second step I would call it mali-blobs-sunxi and try to have access from Allwinner to other Blobs with license(because I have access to G31 Sunxi blobs but I can't publish them) collecting there all Sunxi mali blobs(Utgard, Midgard, Bifrost) A3) mali-blobs-rockchip => with all Rockchip blobs(Utgard, Midgard, Bifrost) that we can easily take from rockchip-linux/libmali This way it becomes easy to add other SoCs drivers and blobs. Steps would be: B1) add platform specific implementation to bootlin/mali-driver(if any) B2) waiting for PR to be merged B3) add Buildroot package for the blobs with dependencies on mali-driver like mali-blobs-newSoc Said this, the problem is time for me. Hope everything is clear. [1]: https://github.com/mripard/sunxi-mali [2]: https://github.com/bootlin/mali-driver [3]: https://patchwork.ozlabs.org/project/buildroot/list/?series=270656 Best regards -- Giulio Benetti Benetti Engineering sas _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot