17:02 flipmess: hi, i have optimus setup and use nouveau for external displays which is working beautifully. now since updating the kernel from 6.4.7 to 6.4.10 (also latest 6.4.12) some apps like firefox, qutebrowser and cage seem to automatically use nvidia card and produce garbled output. at the same time journal is filled with: nouveau [...]: fail ttm_vaildate / validating bo list / validate: -22
17:05 flipmess: gpu is NVIDIA Corporation GK107GLM [Quadro K2000M] (rev a1)
17:24 karolherbst: mhh, it's up to userspace to decide what GPU to use
17:25 karolherbst: flipmess: what's your mesa version btw?
17:25 flipmess: Version : 1:23.1.6-4
17:28 karolherbst: right.. not quite sure where that ttm_validate stuff comes from but that's generally a userspace bug, but I'm also surprised it's causing issues on your end. Anything specific you are doing or do you see the garbled output right away?
17:31 flipmess: karolherbst, it's garbled right away. by making a new firefox profile which obviously does not use hardware acceleration i can use firefox but other programs are still broken.
17:31 karolherbst: interesting.. I'm curious on why userspace decides to render on the nvidia GPU here though
17:32 karolherbst: what desktop environment are you using, and what GPU is picked up when running things like glxinof?
17:32 karolherbst: *glxinfo
17:33 flipmess: i'm using i3wm
17:35 flipmess: karolherbst, this is glxinfo output http://sprunge.us/qYEpAy
17:35 flipmess: says: Device: NVE7 (0xffb) so it seems to be the nvidia card
17:36 karolherbst: mhh
17:36 karolherbst: is DRI_PRIME set in the environment?
17:36 karolherbst: and what's your iGPU, intel? Maybe the intel driver failed to load or something... but then your main display shouldn't work
17:36 karolherbst: or something
17:37 karolherbst: kinda curious on what's going on there
17:37 flipmess: dri_prime is not set afaik
17:38 karolherbst: but did you check?
17:38 flipmess: well intel is working i.e. when firefox isn't using hw accel
17:38 karolherbst: but then it's also not using the intel one for acceleration
17:38 flipmess: export > and then searched for the string ^^;
17:38 karolherbst: mhh
17:38 karolherbst: maybe your Xorg server is set up in a wonky way
17:38 karolherbst: mind sharing your Xorg log?
17:38 flipmess: sure
17:39 karolherbst: might also be some loading order problem...
17:39 karolherbst: or something odd
17:39 karolherbst: the way the primary GPU is detected is held together with 5 rolls of duct tape
17:40 flipmess: http://sprunge.us/ugc6Br <- xorg log
17:41 karolherbst: "/usr/lib/dri/i965_dri.so failed (/usr/lib/dri/i965_dri.so: cannot open shared object file: No such file or directory)"
17:41 karolherbst: I think your intel setup is busted
17:42 flipmess: mh...
17:42 karolherbst: LIBGL_DEBUG=verbose glxinfo
17:42 karolherbst: ohh wait
17:42 karolherbst: I think I might know what this is all about
17:42 karolherbst: ehh maybe not
17:43 karolherbst: is your intel GPU supported by iris?
17:43 flipmess: have to check
17:43 karolherbst: but anyway...
17:43 karolherbst: might want to make sure you ahve the i965_dri.so file installed
17:43 karolherbst: but that driver is kinda deprecated
17:44 karolherbst: and these days you'd use iris or crocus depending on the hardware
17:44 karolherbst: anyway, your problem seems to be that acceleration for your Intel GPU can't be initialized and then Xorg and userspace falls back to the nvidia one
17:44 flipmess: i915 is what i use
17:45 karolherbst: on the kernel side, yes, but the mesa side is something different
17:45 karolherbst: you kinda have to use iris or crocus
17:46 karolherbst: maybe using the intel ddx is also causing the issue here
17:46 karolherbst: and you might want to use "modesetting" instead
17:46 karolherbst: xf86-video-intel is dead and unmaintained, you shouldn't use it
17:48 flipmess: mh... since my distro is rolling release i seldom change anything, just do updates.
17:49 flipmess: but if xorg falls back to nouveau, shouldn't it not be garbled? ^^;
17:50 karolherbst: that's correct. I mean this is also a nouveau bug, and I'll try to look into it, but you also should probably fix your setup as well
17:52 flipmess: sure thing, thx a lot for looking into it :)
21:50 flipmess: karolherbst, just removing xf86-video-intel package fixed the intel accel and nouveau output. starting apps with DRI_PRIME=1 prefix works too. sry for the noise.
22:00 karolherbst: flipmess: ahh.. it might be some weird prime corner case nobody tests, so no wonder I didn't run into this issue before