Bug 91474 - egl initializes wrong card with hybrid graphics card
Summary: egl initializes wrong card with hybrid graphics card
Status: RESOLVED NOTOURBUG
Alias: None
Product: Mesa
Classification: Unclassified
Component: EGL/Wayland (show other bugs)
Version: unspecified
Hardware: Other All
: medium normal
Assignee: Wayland bug list
QA Contact: mesa-dev
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-07-27 15:25 UTC by Marek Chalupa
Modified: 2015-08-10 07:26 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments

Description Marek Chalupa 2015-07-27 15:25:33 UTC
Don't know about it much, but according to strace and logs it look like the user is using intel graphics card and egl is trying to use radeon graphics card, which then results in:

Unable to initialize Clutter: No currently active connector found

https://bugzilla.redhat.com/show_bug.cgi?id=1200439
Comment 1 Axel Davy 2015-07-28 11:52:24 UTC
Mesa egl does indeed support DRI_PRIME for the wayland backend,

however unless DRI_PRIME is set, it uses the same card that the server.
I guess either the user has set DRI_PRIME or the equivalent drirc option,
or Clutter is incorrectly choosing the radeon card as main card, and initialises wayland with it.

I do not believe the bug is Mesa side.
Comment 2 Emil Velikov 2015-07-28 11:59:22 UTC
Using the device extensions one will be able to enumerate and select the device they want without the need of X or the DRI_PRIME variable.

Jonny Lamb posted a series that implements the "base" - device_enumeration + device_query, a few days ago.

[1] http://lists.freedesktop.org/archives/mesa-dev/2015-July/089783.html
Comment 3 Marek Chalupa 2015-07-30 09:27:49 UTC
(In reply to Axel Davy from comment #1)
> Mesa egl does indeed support DRI_PRIME for the wayland backend,
> 
> however unless DRI_PRIME is set, it uses the same card that the server.
> I guess either the user has set DRI_PRIME or the equivalent drirc option,
> or Clutter is incorrectly choosing the radeon card as main card, and
> initialises wayland with it.
> 
> I do not believe the bug is Mesa side.

Was digging into the code a bit and you're probably right. It looks like mutter is always using /dev/dri/card0 (which is the radeon in this case)

https://git.gnome.org/browse/mutter/tree/src/backends/native/meta-launcher.c#n270
Comment 4 Marek Chalupa 2015-08-10 07:26:13 UTC
https://bugzilla.gnome.org/show_bug.cgi?id=753434


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.