Skip to contentSkip to conversation

mesa3d: add intel gallium driver support

PATCH New Gustavo Zacarias 4 participants 12 messages Mar 10, 2016 – Mar 31, 2016

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 mesa3d: add intel gallium driver support

---
 package/mesa3d/Config.in | 9 +++++++++
 package/mesa3d/mesa3d.mk | 1 +
 2 files changed, 10 insertions(+)
package/mesa3d/Config.in +9 -0
index 9057746..5badefa 100644
@@ -43,6 +43,15 @@ config BR2_PACKAGE_MESA3D_NEEDS_XA
 
 comment "Gallium drivers"
 
+config BR2_PACKAGE_MESA3D_GALLIUM_DRIVER_I915
+	bool "Gallium i915 driver"
+	depends on BR2_i386 || BR2_x86_64
+	select BR2_PACKAGE_MESA3D_GALLIUM_DRIVER
+	select BR2_PACKAGE_LIBDRM_INTEL
+	select BR2_PACKAGE_MESA3D_NEEDS_XA
+	help
+	  Driver for Intel integrated graphics.
+
 config BR2_PACKAGE_MESA3D_GALLIUM_DRIVER_NOUVEAU
 	bool "Gallium nouveau driver"
 	depends on BR2_i386 || BR2_x86_64
package/mesa3d/mesa3d.mk +1 -0
index ff2f932..c1f2f45 100644
@@ -61,6 +61,7 @@ endif
 # Drivers
 
 #Gallium Drivers
+MESA3D_GALLIUM_DRIVERS-$(BR2_PACKAGE_MESA3D_GALLIUM_DRIVER_I915)     += i915
 MESA3D_GALLIUM_DRIVERS-$(BR2_PACKAGE_MESA3D_GALLIUM_DRIVER_NOUVEAU)  += nouveau
 MESA3D_GALLIUM_DRIVERS-$(BR2_PACKAGE_MESA3D_GALLIUM_DRIVER_R600)     += r600
 MESA3D_GALLIUM_DRIVERS-$(BR2_PACKAGE_MESA3D_GALLIUM_DRIVER_SVGA)     += svga
Signature · 1 line
2.4.10
#1 lore raw

PATCH 1/1 mesa3d: add intel gallium driver support

Quoted 15 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Gustavo" == Gustavo Zacarias <[email protected]> writes:

---
 package/mesa3d/Config.in | 9 +++++++++
 package/mesa3d/mesa3d.mk | 1 +
 2 files changed, 10 insertions(+)
package/mesa3d/Config.in +0 -0
index 9057746..5badefa 100644
@@ -43,6 +43,15 @@ config BR2_PACKAGE_MESA3D_NEEDS_XA
 
 comment "Gallium drivers"

package/mesa3d/Config.in config BR2_PACKAGE_MESA3D_NEEDS_XA · line 54

Quoted 10 lines
package/mesa3d/Config.in +9 -0
 
+config BR2_PACKAGE_MESA3D_GALLIUM_DRIVER_I915
+	bool "Gallium i915 driver"
+	depends on BR2_i386 || BR2_x86_64
+	select BR2_PACKAGE_MESA3D_GALLIUM_DRIVER
+	select BR2_PACKAGE_LIBDRM_INTEL
+	select BR2_PACKAGE_MESA3D_NEEDS_XA
+	help
+	  Driver for Intel integrated graphics.
+

I don't know much about mesa, but I thought the Intel driver didn't use galium? Is this some kind of alternative to the dri driver?

Signature · 1 line
Bye, Peter Korsgaard
#2 lore raw

PATCH 1/1 mesa3d: add intel gallium driver support

Quoted 2 lines · Peter Korsgaard

I don't know much about mesa, but I thought the Intel driver didn't use galium? Is this some kind of alternative to the dri driver?

You've got both, from mesa configure:

--with-gallium-drivers[=DIRS...]

    comma delimited Gallium drivers list, e.g.
    "i915,ilo,nouveau,r300,r600,radeonsi,freedreno,svga,swrast,vc4,virgl"
    [default=r300,r600,svga,swrast]

Enabling it builds /usr/lib/dri/i915_dri.so besides others you may have selected (in my case kms_swrast_dri.so and swrast_dri.so). Otherwise we can ask Bernd, but i get that additional driver with this option, and it's documented.
Regards.

#3 lore raw

PATCH 1/1 mesa3d: add intel gallium driver support

Am Thu, 10 Mar 2016 17:08:47 -0300 schrieb Gustavo Zacarias:

Quoted 10 lines · Peter Korsgaard
Quoted 3 lines

I don't know much about mesa, but I thought the Intel driver didn't use galium? Is this some kind of alternative to the dri driver?

You've got both, from mesa configure:

--with-gallium-drivers[=DIRS...]
comma delimited Gallium drivers list, e.g.

"i915,ilo,nouveau,r300,r600,radeonsi,freedreno,svga,swrast,vc4,virgl"

Quoted 7 lines
    [default=r300,r600,svga,swrast]

Enabling it builds /usr/lib/dri/i915_dri.so besides others you may have selected (in my case kms_swrast_dri.so and swrast_dri.so). Otherwise we can ask Bernd, but i get that additional driver with this option, and it's documented.
Regards.

Hi,

I am using the DRI driver for my Kodi system and never tried the Gallium one because my personal Kodi package follows the OpenElec development, and they use DRI, too ;)
https://github.com/OpenELEC/OpenELEC.tv/blob/master/config/graphic#L26

Some quotes I found during a quick research:
http://www.mesa3d.org/relnotes/8.0.html (February 9, 2012) "Removed the dead Gallium i965, cell and failover drivers, which were either broken and with nobody in sight to fix the situation or deprecated."

https://blogs.igalia.com/itoral/2014/08/08/diving-into-mesa/
"Although there were some efforts to port the Intel driver to Gallium in the past, development of the Intel Gallium drivers (i915g and i965g) is stalled now as far as I know. Intel is focusing in the classic version of the drivers instead."

These days Intel is busy in coding a Vulkan driver for mesa3d:
https://cgit.freedesktop.org/mesa/mesa/tree/README.intel-vulkan.txt?
h=vulkan

To sum up: Yes, it is possible to build a i915 gallium driver in mesa3d, but who needs it? That's the reason I never implemented a Config.in option for it, but it will not hurt having one ;)

Regards, Bernd

#4 lore raw

PATCH 1/1 mesa3d: add intel gallium driver support

Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Bernd" == Bernd Kuhls <[email protected]> writes:

Hi,

Quoted 3 lines

To sum up: Yes, it is possible to build a i915 gallium driver in mesa3d, but who needs it? That's the reason I never implemented a Config.in option for it, but it will not hurt having one ;)

Ok, that was more of less also my understanding. Gustavoz, what do you need the gallium driver for?

Signature · 1 line
Bye, Peter Korsgaard
#5 lore raw

PATCH 1/1 mesa3d: add intel gallium driver support

Quoted 8 lines · Peter Korsgaard

Hi,

Quoted 3 lines

To sum up: Yes, it is possible to build a i915 gallium driver in mesa3d, but who needs it? That's the reason I never implemented a Config.in option for it, but it will not hurt having one ;)

Ok, that was more of less also my understanding. Gustavoz, what do you need the gallium driver for?

"DRI drivers need X.org" -> wayland, plus libgtk3 with it as backend. All that libepoxy effort would go to /dev/null otherwise. Regards.

#6 lore raw

PATCH 1/1 mesa3d: add intel gallium driver support

Quoted 9 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Gustavo" == Gustavo Zacarias <[email protected]> writes:

Quoted 6 lines · Peter Korsgaard

Hi,

Quoted 3 lines

To sum up: Yes, it is possible to build a i915 gallium driver in mesa3d, but who needs it? That's the reason I never implemented a Config.in option for it, but it will not hurt having one ;)

Quoted 6 lines
Quoted 2 lines

Ok, that was more of less also my understanding. Gustavoz, what do you need the gallium driver for?

"DRI drivers need X.org" -> wayland, plus libgtk3 with it as backend. All that libepoxy effort would go to /dev/null otherwise. Regards.

I actually think the comment is wrong. Googling around for wayland / mesa / intel seems to show a bunch of references to people using dri drivers and not gallium:

https://wayland.freedesktop.org/building.html
https://lists.freedesktop.org/archives/wayland-devel/2011-February/000702.html
https://lists.freedesktop.org/archives/wayland-devel/2012-August/004832.html
https://gist.github.com/tmpvar/6218568

Signature · 2 lines
Venlig hilsen,
Peter Korsgaard 
#7 lore raw

PATCH 1/1 mesa3d: add intel gallium driver support

Quoted 8 lines · Peter Korsgaard

I actually think the comment is wrong. Googling around for wayland / mesa / intel seems to show a bunch of references to people using dri drivers and not gallium:

https://wayland.freedesktop.org/building.html
https://lists.freedesktop.org/archives/wayland-devel/2011-February/000702.html
https://lists.freedesktop.org/archives/wayland-devel/2012-August/004832.html
https://gist.github.com/tmpvar/6218568

Many people use xwayland hence care (or don't, depending on perspective) about lingering x11 stuff around.
The end reason is libgtk3 with the wayland and/or broadway backend, newer gtk3 versions require some form of *GL support provided by the libepoxy wrapper.
libepoxy in turn needs a real GLX and/or EGL provider, GLX is a no-brainer, it requires X11. EGL on the other hand does not. With some patching (sent) libepoxy can be built X11-less to only handle EGL, after all who wants a gtk3 with wayland carrying x11 luggage? (when building libgtk3 with only the wayland and/or broadway backends) Now, since newer libgtk3 versions mandate some form of GL support, which is wrapped by libepoxy and provided by mesa, doesn't it make sense that said GL support is accelerated?
Regards.

#8 lore raw

PATCH 1/1 mesa3d: add intel gallium driver support

Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Gustavo" == Gustavo Zacarias <[email protected]> writes:

Hi,

Quoted 3 lines

Now, since newer libgtk3 versions mandate some form of GL support, which is wrapped by libepoxy and provided by mesa, doesn't it make sense that said GL support is accelerated?

Yes it does, it is just not clear to me that using this gallium driver is the way to do it. Your commit message also didn't explain this, which is why I'm asking.

Is this gallium driver useful for non-wayland (X11) setups? If not, perhaps it should depend on wayland.

Signature · 2 lines
Venlig hilsen,
Peter Korsgaard 
#9 lore raw

PATCH 1/1 mesa3d: add intel gallium driver support

Quoted 6 lines · Peter Korsgaard

Yes it does, it is just not clear to me that using this gallium driver is the way to do it. Your commit message also didn't explain this, which is why I'm asking.

Is this gallium driver useful for non-wayland (X11) setups? If not, perhaps it should depend on wayland.

I fail to see why, you've got many other gallium drivers and they don't mention wayland either (noveau, r600, svga, swrast, virgl). I'm pretty sure these are valid for qt5 as well since it can use an EGL backend too.
Regards.

#10 lore raw

PATCH 1/1 mesa3d: add intel gallium driver support

In reply to Gustavo Zacarias

Hello,

Quoted 4 lines · Gustavo Zacarias
Quoted 2 lines · Peter Korsgaard

Hi,

Quoted 8 lines
Quoted 6 lines
Quoted 3 lines

To sum up: Yes, it is possible to build a i915 gallium driver in mesa3d, but who needs it? That's the reason I never implemented a Config.in option for it, but it will not hurt having one ;)

Ok, that was more of less also my understanding. Gustavoz, what do you need the gallium driver for?

"DRI drivers need X.org" -> wayland, plus libgtk3 with it as backend.

"DRI drivers need X.org" ? This seems wrong, since you precisely sent a patch recently to all DRI drivers to be built without X.org.

So I guess this specific patch, allowing to build the unmaintained Intel Gallium driver is no longer needed?

I've marked it as Rejected on patchwork for now. Let me know if you disagree for some reason.

Thanks!

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
#11 lore raw

PATCH 1/1 mesa3d: add intel gallium driver support

Quoted 6 lines · Thomas Petazzoni

"DRI drivers need X.org" ? This seems wrong, since you precisely sent a patch recently to all DRI drivers to be built without X.org.

So I guess this specific patch, allowing to build the unmaintained Intel Gallium driver is no longer needed?

Quoted 6 lines

I've marked it as Rejected on patchwork for now. Let me know if you disagree for some reason.

Thanks!

Thomas

Hi Thomas.
The gallium intel driver wasn't cutting it like Bernd said so i tried/investigated the DRI route and it worked out.
So yes, even though it might be academically interesting to have the option to build the intel gallium driver it's pretty much useless so no argument from me since i got what was really interesting from the other patchset.
Regards.