13:50frytaped: Could something be done so that NVIDIA GPU ends up becoming /dev/dri/card1 and gets the /dev/dri/renderD129 node on an optimus laptop ? Everytime NVIDIA GPU becomes /dev/dri/card0 a lot of stuff breaks for me on Wayland.
13:56karolherbst: frytaped: huh.. normally the intel one should be card0 but it kind of depends on loading time
13:56karolherbst: userspace shouldn't rely on any order
13:57frytaped: For me the NVIDIA GPU becomes the card0 almost every time.
13:57frytaped: Chromium on wayland is what breaks for me.
13:57karolherbst: mhhh
13:58karolherbst: in most cases intel usually becomes card0 but it could be different depending on your setup.. maybe there is something obvious in your kenrel log. Mind sharing your dmesg?
13:59frytaped: https://paste.centos.org/view/210a9875
14:02karolherbst: mhhh
14:02karolherbst: is intel or nouveau card0 in this?
14:03frytaped: nouveau
14:03karolherbst: strange
14:04karolherbst: though nouveau seems to be a bit faster to create those nodes, but intel seems faster to claim the frame buffer
14:05karolherbst: but what breaks wiht chromium specifically? It's starts to use nouveau or?
14:05frytaped: GPU stuff start crashing
14:05frytaped: Probably because it tries to use nouveau I think
14:06karolherbst: mhh.. annoying
14:06frytaped: It doesnt crash if Intel is card0 and gets the renderD128 node
14:06karolherbst: do you know if it's just chromium or do other applications also use nouveua?
14:06karolherbst: *nouveau
14:07frytaped: Well electron apps start crashing too if I try to run it using the wayland backend
14:07karolherbst: :(
14:07frytaped: But it uses chromium under the hood anyway
14:07karolherbst: well.. that's chromium still though
14:08karolherbst: if electron/chromium is the only one, then I'd file a bug, because that's clearly wrong. But if others use it there might be something else going on
14:08karolherbst: you can check with /sys/kernel/debug/dri/*/clients
14:08frytaped: I have not tried to deliberately run apps using nouveau though
14:08karolherbst: this should list active processes per node
14:11frytaped: chromium output -> https://paste.centos.org/view/7cc1f1a5
14:11frytaped: /sys/kernel/debug/dri/129/clients -> https://paste.centos.org/view/76588acb
14:12karolherbst: okay.. so stuff usually uses the intel GPU
14:13frytaped: chrome seems to be using both D128 and D129 (judging by the outputs)
14:14karolherbst: mhh
14:14karolherbst: yeah...
14:15karolherbst: no idea why chrome is doing that, it's clearly wrong
14:16frytaped: Is there any udev rule or something that I could use to force Intel gpu to get initialized first ?
14:17karolherbst: frytaped: one thing you could try is to stop chrome, unload nouveau and see if chrome starts
14:17karolherbst: frytaped: not that I am aware of, because this depends on the kernel loading modules
14:17karolherbst: and you usually can't tell which GPU is the main/secondary one until you actually load the driver
14:18karolherbst: that might be simple for your system, but you can have desktops where the nvidia one is main and intel secondary
14:18karolherbst: or systems with two nvidia gpus
14:18frytaped: How would I unload nouveau while I am in my GUI session ?
14:18frytaped: Its still in use
14:19karolherbst: mhhh
14:19karolherbst: at least with gnome that should be possible, maybe something is still using it
14:20karolherbst: having a display connected might also prevent unloading
14:20karolherbst: otherwise check with lsof on the /dev/dri/ nodes
14:20frytaped: Well closing an electron app (running under Xwayland) made it work
14:20karolherbst: ahh
14:20frytaped: (I actually didnt expect it to work)
14:20karolherbst: question is.. do they start now or are they simply giving up
14:20karolherbst: and if chrome starts, what is "chrome://gpu" saying
14:21frytaped: It does seem to work
14:21frytaped: Though I do get GPU process exited unexpectedly: exit_code=134
14:21karolherbst: heh
14:22karolherbst: somewhat weird on my system, where intel is card0
14:22karolherbst: "GPU0 VENDOR= 0x10de, DEVICE=0x1fb9"
14:22frytaped: Yeah I got a segfault but chrome://gpu says everything's fine
14:22karolherbst: "GPU1 VENDOR= 0x8086, DEVICE=0x9bc4 *ACTIVE*"
14:22karolherbst: and 8086 is intel
14:22karolherbst: so whatever chromium is doing, I suspect it's broken
14:23karolherbst: we had some bug in this domain a few weeks earlier (overall GPU bug, not nouveau) where applications assumed there is no gap
14:23karolherbst: so if you'd have card0 and card2 -> crash
14:23frytaped: Wait how is chromium detecting two GPUs even after unloading nouveau
14:23karolherbst: pci devices
14:23frytaped: But there shouldnt be a dri driver right ?
14:24karolherbst: correct
14:24karolherbst: unless something loaded nouveau again
14:24frytaped: It still reports the mesa version for the nvidia gpu
14:24karolherbst: but I assume you only have the card1 and renderD129 nodes
14:24frytaped: Yeah nouveau isnt loaded
14:24frytaped: and no card0
14:24karolherbst: "strange"
14:25karolherbst: anyway, sounds broken
14:25karolherbst: might want to restart gnome to be sure
14:25frytaped: But atleast chromium seems to work now
14:25karolherbst: but I'd fill a bug report against chromium and see what they say
14:26karolherbst: or maybe somebody already did.. I'll ask in #dri-devel
14:27frytaped: I had a similar problem getting va-api working with Firefox some time back but Firefox had fixed it
14:27frytaped: Had to set some env var to make ff use D129
14:28karolherbst: frytaped: sure that chrome uses the wayland backend btw?
14:29frytaped: replied there
20:08top: hello