Mali support for Mainline linux on Odroid-C2

Post Reply
narmstrong
Posts: 8
Joined: Tue Mar 21, 2017 7:06 pm
languages_spoken: english
ODROIDs: C2
Location: Villeneuve-Loubet, France
Has thanked: 0
Been thanked: 0
Contact:

Mali support for Mainline linux on Odroid-C2

Unread post by narmstrong » Wed May 10, 2017 12:31 am

Hi Hardkernel folks,

As you may know, I showed a demo of the Odroid-C2 board running Mainline Linux with HDMI, Audio and Mali-450 support.

But, as you encountered, the Amlogic provided Mali shared library is flawed for X11 acceleration.

I know you are now a sublicensee for the Mali-450 driver and you made some improvements to correctly run Ubuntu on the Odroid-C2 based on the Amlogic 3.14 kernel.

But as you may know, I enabled support for the Mali acceleration on the upcoming Linux 4.12.

My attempts using the X11 armsoc driver and Amlogic buildroot libMali for X11 were a disaster, but worked (here is my armsoc version https://github.com/superna9999/xf86-video-armsoc).

But I also managed to get the Framebuffer version running at full performance to run Quake 3 Arena and Kodi 17.

But, it's not enough since Mainline linux uses the DRM/KMS to manage display and change modes, so a GBM version of libMali would be necessary here to permit changing the resolution and the refresh rate.

My question is simple, is it possible to collaborate with you to have "Mainline-working" version of your libMali builds, and have a GBM version to run Kodi without X11 or run Wayland ?
This would greatly improve the support and we could go a step further and think about true video decoding accelerate via a V4L driver and even decoding a video in a Chromium page ?

Neil

User avatar
mad_ady
Posts: 6371
Joined: Wed Jul 15, 2015 5:00 pm
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1, H2, N2
Location: Bucharest, Romania
Has thanked: 146 times
Been thanked: 106 times
Contact:

Re: Mali support for Mainline linux on Odroid-C2

Unread post by mad_ady » Wed May 10, 2017 1:22 am

+subscribed, though I don't have the skills to help. But I'd love to see this work.

User avatar
memeka
Posts: 4321
Joined: Mon May 20, 2013 10:22 am
languages_spoken: english
ODROIDs: XU rev2 + eMMC + UART
U3 + eMMC + IO Shield + UART
Has thanked: 1 time
Been thanked: 13 times
Contact:

Re: Mali support for Mainline linux on Odroid-C2

Unread post by memeka » Wed May 10, 2017 6:33 am

Have you tried the binary driver for hikey from malideveloper website? I remember there was a 64bit fbdev/wayland driver

redhad
Posts: 20
Joined: Wed May 03, 2017 10:58 pm
languages_spoken: english, german, russian, french
ODROIDs: C2
Has thanked: 0
Been thanked: 0
Contact:

Re: Mali support for Mainline linux on Odroid-C2

Unread post by redhad » Wed May 10, 2017 6:55 am

memeka wrote:Have you tried the binary driver for hikey from malideveloper website? I remember there was a 64bit fbdev/wayland driver
Is there a difference between Mali 450 MP3 (being used by S905) and Mali 450 MP4 (being used by Kirin 620)?

User avatar
memeka
Posts: 4321
Joined: Mon May 20, 2013 10:22 am
languages_spoken: english
ODROIDs: XU rev2 + eMMC + UART
U3 + eMMC + IO Shield + UART
Has thanked: 1 time
Been thanked: 13 times
Contact:

Re: Mali support for Mainline linux on Odroid-C2

Unread post by memeka » Wed May 10, 2017 7:20 am

The number of cores, but drivers don't hardcode number of cores :)

brad
Posts: 957
Joined: Tue Mar 29, 2016 1:22 pm
languages_spoken: english
ODROIDs: C2 N1 N2 H2 (64 bit ftw)
Location: Australia
Has thanked: 14 times
Been thanked: 30 times
Contact:

Re: Mali support for Mainline linux on Odroid-C2

Unread post by brad » Thu May 11, 2017 10:15 pm

Hi Hardkernel,
I too would be very interested in hearing your thoughts on this subject and some collaboration with Neil for libMali support for mainline kernel :) I also dont have any expertise in this area but would welcome any efforts or attempts to make it work.

Thanks,
Brad.

User avatar
odroid
Site Admin
Posts: 31787
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English
ODROIDs: ODROID
Has thanked: 86 times
Been thanked: 242 times
Contact:

Re: Mali support for Mainline linux on Odroid-C2

Unread post by odroid » Thu May 11, 2017 10:27 pm

We can join this C2 mainling party in early July after fixing several issues on XU4 Kernel 4.9.
Please give us several weeks. I think we can start to build our Mali DDK when Kernel 4.12 RC3 or RC4 is available.

best_odroidfreak
Posts: 365
Joined: Wed May 04, 2016 1:07 am
languages_spoken: english
Has thanked: 0
Been thanked: 0
Contact:

Re: Mali support for Mainline linux on Odroid-C2

Unread post by best_odroidfreak » Tue May 16, 2017 3:48 pm

narmstrong wrote:Hi Hardkernel folks,

As you may know, I showed a demo of the Odroid-C2 board running Mainline Linux with HDMI, Audio and Mali-450 support.

But, as you encountered, the Amlogic provided Mali shared library is flawed for X11 acceleration.

I know you are now a sublicensee for the Mali-450 driver and you made some improvements to correctly run Ubuntu on the Odroid-C2 based on the Amlogic 3.14 kernel.

But as you may know, I enabled support for the Mali acceleration on the upcoming Linux 4.12.

My attempts using the X11 armsoc driver and Amlogic buildroot libMali for X11 were a disaster, but worked (here is my armsoc version https://github.com/superna9999/xf86-video-armsoc).

But I also managed to get the Framebuffer version running at full performance to run Quake 3 Arena and Kodi 17.

But, it's not enough since Mainline linux uses the DRM/KMS to manage display and change modes, so a GBM version of libMali would be necessary here to permit changing the resolution and the refresh rate.

My question is simple, is it possible to collaborate with you to have "Mainline-working" version of your libMali builds, and have a GBM version to run Kodi without X11 or run Wayland ?
This would greatly improve the support and we could go a step further and think about true video decoding accelerate via a V4L driver and even decoding a video in a Chromium page ?

Neil
When Kernel 4.12 RC3 or RC4 will be available?

User avatar
odroid
Site Admin
Posts: 31787
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English
ODROIDs: ODROID
Has thanked: 86 times
Been thanked: 242 times
Contact:

Re: Mali support for Mainline linux on Odroid-C2

Unread post by odroid » Tue May 16, 2017 4:55 pm

@best_odroidfreak
You had to ask it to Linus Torvalds even he can't predict it precisely.

redhad
Posts: 20
Joined: Wed May 03, 2017 10:58 pm
languages_spoken: english, german, russian, french
ODROIDs: C2
Has thanked: 0
Been thanked: 0
Contact:

Re: Mali support for Mainline linux on Odroid-C2

Unread post by redhad » Tue May 16, 2017 11:12 pm

Look here: https://kernelnewbies.org/LinuxVersions

A major version takes in general 70 days. From the 4.11 on 30.04.17 to 4.12-rc1 on 13.05.17, it took 13 days.
Usually, there is a rc in about every week to two weeks. So 4.12 rc2 should be available around the end of May (depending on how many commits there might be, it may be sooner, or even later). Plus Linus may postpone the rc release, as he quite frequently does, in order to get the developers committing to fix certain aspects of their patches.

With a development window of 70 days, one can however aim at the 9th of July as the release date of 4.12.

narmstrong
Posts: 8
Joined: Tue Mar 21, 2017 7:06 pm
languages_spoken: english
ODROIDs: C2
Location: Villeneuve-Loubet, France
Has thanked: 0
Been thanked: 0
Contact:

Re: Mali support for Mainline linux on Odroid-C2

Unread post by narmstrong » Wed May 17, 2017 6:01 pm

odroid wrote:We can join this C2 mainling party in early July after fixing several issues on XU4 Kernel 4.9.
Please give us several weeks. I think we can start to build our Mali DDK when Kernel 4.12 RC3 or RC4 is available.
Hi,

Thanks !

RC3 will be tagged in 2 weeks.

crow
Posts: 3
Joined: Mon Mar 14, 2016 3:40 am
languages_spoken: english
Has thanked: 0
Been thanked: 0
Contact:

Re: Mali support for Mainline linux on Odroid-C2

Unread post by crow » Thu Jun 08, 2017 8:23 am

Any news on this collaboration between hardkernel and baylibre developers? To be precise hardkernel how is going with fixing XU4 Kernel 4.9, as if I understand your post, after fixing these issue you "could" start to work with baylibre team.

User avatar
odroid
Site Admin
Posts: 31787
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English
ODROIDs: ODROID
Has thanked: 86 times
Been thanked: 242 times
Contact:

Re: Mali support for Mainline linux on Odroid-C2

Unread post by odroid » Thu Jun 08, 2017 9:13 am

We've looked into the meson-DRM driver in C2 Kernel 4.12 to activate the Mali GPU on X11/Linux.
But the DRM driver has many missing functions and we can't port our Mali driver.
We can try the FBDEV version only at this moment. But it was already available in BayLibre's Quake 3 Arena demo.
Unfortunately, we have no skill to implement the DRM driver. So we have to wait until someone implements the fully working DRM driver.

andy5macht
Posts: 238
Joined: Mon May 16, 2016 5:25 am
languages_spoken: english, german
ODROIDs: U3, C2, N2
Has thanked: 5 times
Been thanked: 0
Contact:

Re: Mali support for Mainline linux on Odroid-C2

Unread post by andy5macht » Thu Jun 08, 2017 4:19 pm

That doesnt sound great but...who could this *someone* be? Baylibre-Team? Are there further investigations?

narmstrong
Posts: 8
Joined: Tue Mar 21, 2017 7:06 pm
languages_spoken: english
ODROIDs: C2
Location: Villeneuve-Loubet, France
Has thanked: 0
Been thanked: 0
Contact:

Re: Mali support for Mainline linux on Odroid-C2

Unread post by narmstrong » Thu Jun 08, 2017 10:33 pm

Hi,

I don't understand what's missing to support the DRM driver ?

Can you be explicit about what is missing, honestly I'm not aware of missing features when I look at other DRM implementation for Mali.

If it's about buffer allocation, you can use the DRM_IOCTL_MODE_CREATE_DUMB call to allocate BOs as used in https://github.com/superna9999/xf86-vid ... de_meson.c

Thanks,
Neil

mdrjr
Site Admin
Posts: 11710
Joined: Fri Feb 22, 2013 11:34 pm
languages_spoken: english, portuguese
ODROIDs: -
Location: Brazil
Has thanked: 0
Been thanked: 6 times
Contact:

Re: Mali support for Mainline linux on Odroid-C2

Unread post by mdrjr » Sat Jun 10, 2017 2:00 pm

Hello Neil

Are you on freenode?
If yes ping me. Same nick as here

crow
Posts: 3
Joined: Mon Mar 14, 2016 3:40 am
languages_spoken: english
Has thanked: 0
Been thanked: 0
Contact:

Re: Mali support for Mainline linux on Odroid-C2

Unread post by crow » Sun Jun 11, 2017 12:10 am

he and others are in the

Code: Select all

Freenode IRC in #linux-amlogic
URL: http://linux-meson.com/doku.php?id=start

redhad
Posts: 20
Joined: Wed May 03, 2017 10:58 pm
languages_spoken: english, german, russian, french
ODROIDs: C2
Has thanked: 0
Been thanked: 0
Contact:

Re: Mali support for Mainline linux on Odroid-C2

Unread post by redhad » Fri Jun 30, 2017 9:55 pm

This might be very interesting:

http://phoronix.com/scan.php?page=news_ ... pen-Source
An open-source contributor has begun working on a new open-source driver for the ARM Mali-400 GPU.

Qiang Yu, who appears to still works for AMD, has begun working on an open-source Mali-400 graphics driver. So far this Mesa Gallium3D driver can run a simple OpenGL triangle draw application while he's now working on the shader compiler bits.

This new Mali-400 Gallium3D driver isn't based directly on the past work of Luc Verhaegen's Lima driver but is reusing the hardware information learned from the past efforts and its hilbert render curve algorithm. This new driver consists of the Gallium3D driver, the libdrm support, and a new kernel DRM driver.

This new driver was announced a few days ago on the Lima IRC channel. This Mali-400 OpenGL driver in development can be found via GitHub. It will be interesting to see where this new Mali-400 open-source driver leads and if it ends up advancing enough by this developer to eventually see it mainlined in the future.

crashoverride
Posts: 4491
Joined: Tue Dec 30, 2014 8:42 pm
languages_spoken: english
ODROIDs: C1
Has thanked: 0
Been thanked: 62 times
Contact:

Re: Mali support for Mainline linux on Odroid-C2

Unread post by crashoverride » Fri Jun 30, 2017 10:53 pm

redhad wrote:This might be very interesting:
I find it interesting for a different reason. The github page:
https://github.com/yuq/mesa-lima

Includes the following text in the README:
The software may implement third party technologies (e.g. third party
libraries) that are not licensed to you by AMD and for which you may need
to obtain licenses from other parties.
It appears that AMD is funding/driving this project. This is, of course, just speculation on my part but what fun is life without rumors, speculation, and half-truths! :D

User avatar
odroid
Site Admin
Posts: 31787
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English
ODROIDs: ODROID
Has thanked: 86 times
Been thanked: 242 times
Contact:

Re: Mali support for Mainline linux on Odroid-C2

Unread post by odroid » Mon Jul 03, 2017 5:10 pm

crashoverride wrote:
redhad wrote:This might be very interesting:
I find it interesting for a different reason. The github page:
https://github.com/yuq/mesa-lima

Includes the following text in the README:
The software may implement third party technologies (e.g. third party
libraries) that are not licensed to you by AMD and for which you may need
to obtain licenses from other parties.
It appears that AMD is funding/driving this project. This is, of course, just speculation on my part but what fun is life without rumors, speculation, and half-truths! :D
Very interesting indeed.
I hope we can run some generic OpenGL 2.1 software instead of the OpenGL-ES 2.0 on ODROID-C2 one day.

redhad
Posts: 20
Joined: Wed May 03, 2017 10:58 pm
languages_spoken: english, german, russian, french
ODROIDs: C2
Has thanked: 0
Been thanked: 0
Contact:

Re: Mali support for Mainline linux on Odroid-C2

Unread post by redhad » Tue Jul 11, 2017 8:50 pm

Some time has passed...

Are there any news?

BrozikCZ
Posts: 11
Joined: Mon Jul 17, 2017 10:26 pm
languages_spoken: english
ODROIDs: Odroid C2
Has thanked: 0
Been thanked: 0
Contact:

Re: Mali support for Mainline linux on Odroid-C2

Unread post by BrozikCZ » Thu Jul 27, 2017 2:24 pm

Hi, any progress? :)

redhad
Posts: 20
Joined: Wed May 03, 2017 10:58 pm
languages_spoken: english, german, russian, french
ODROIDs: C2
Has thanked: 0
Been thanked: 0
Contact:

Re: Mali support for Mainline linux on Odroid-C2

Unread post by redhad » Thu Aug 17, 2017 7:07 pm

odroid wrote:We can join this C2 mainling party in early July after fixing several issues on XU4 Kernel 4.9.
Please give us several weeks. I think we can start to build our Mali DDK when Kernel 4.12 RC3 or RC4 is available.
By the way, it is August 2017, the most recent release candidate is 4.13-rc5....


Is it such a delicate topic that no status updates are being made? :evil:

zeta
Posts: 8
Joined: Fri Apr 21, 2017 7:04 am
languages_spoken: english, french
ODROIDs: C2
Has thanked: 0
Been thanked: 0
Contact:

Re: Mali support for Mainline linux on Odroid-C2

Unread post by zeta » Wed Sep 06, 2017 3:19 am

I came across the following news, which could interest some of you :

A talk will be given by Maxime Ripard from the company "Free Electrons" (one of the kernel maintainer), at the "Kernel Recipe" conference in Paris from September 27th to 29th.

"The presentation is based on the work we have done to develop a DRM driver for the Allwinner SoCs display controller with multiple outputs, such as parallel display interfaces, HDMI or MIPI-DSI. The work done to make the ARM Mali OpenGL driver work on top of a mainline DRM/KMS driver will also be detailed, as well as the more traditional, Mesa-based, solution used in a variety of other platforms."

Link is here : https://kernel-recipes.org/en/2017/talk ... subsystem/

I hope there will be videos after the event, as in previous years.

Post Reply

Return to “General Topics”

Who is online

Users browsing this forum: No registered users and 2 guests