Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gnome-shell crashes when trying to enable notebook screen while switched to Nvidia eGPU #3

Open
flxzt opened this issue Dec 16, 2021 · 8 comments

Comments

@flxzt
Copy link

flxzt commented Dec 16, 2021

Hey, thank you so much for the script.
I am having this issue:

I am able to switch to the eGPU with both methods. However choosing either disables the display of my notebook. The first (disabling the internal GPU) results in a black/disabled notebook screen and only my external monitor shows up in the gnome display settings. The second (setting the boot flag) also only enables the external monitor, but the vendor splash screen is being displayed on the internal display. The internal display then also shows up in the settings. Any attempts to set it as a secondary monitor are crashing gnome-shell though. The crash-report gives me:

reason: gnome-shell killed by SIGTRAP
crash_function: dump_gjs_stack_on_signal_handler

Tell me what else you need, I saved the crash-report files. The event_log only gives me this though:

2021-12-16-14:12:39> Erstellen eines Mikroreports aus den Problemdaten fehlgeschlagen
2021-12-16-14:12:39* (»report_uReport« abgebrochen durch 1)

I should mention that under X11 I am able to use both screens without an issue.

Not sure if the crashes are fixable by the script, but I thought you may have an idea for a workaround

System:
Fedora 35, Kernel 5.15.7
gnome-shell 41.2, mutter 41.2, Nvidia Drivers: 495.44

Hardware:
Lenovo Thinkpad X1 Yoga
Intel UHD 620
NVIDIA GeForce GTX 1080
Gigabyte Aorus Gaming box TB3

@ewagner12
Copy link
Owner

Thanks for the report, I actually do appreciate people using the script and finding issues with it and stuff.

I do have an old nvidia card and Fedora install so I will test this and report back if I can replicate this. I don't remember this being an issue with previous versions I tested on. I think this might be caused by the new GBM buffer support in Nvidia driver 495.44 so you might try rolling back to any older version and see if that fixes it.

@ewagner12
Copy link
Owner

Well the GT710 I'm testing isn't supprted in 495, but I was able to basically replicate this on driver 470.
Digging in a bit more, this looks like an issue that has existed for a while on nvidia+wayland and affects non-egpu laptops as well so it looks like an upstream nvidia/mutter/mesa issue. See this bug thread that I believe is an equivalent issue: https://gitlab.gnome.org/GNOME/mutter/-/issues/1891

@flxzt
Copy link
Author

flxzt commented Feb 9, 2022

Interestingly after a reinstall of fedora 35 and with Nvidia 510 drivers, Gnome does not crash anymore when the settings of the internal display are being changed and instead of a splash screen, it shows the grey background of (I think) gdm. I assume it has something to to with the new EGL backend. But any changes in the settings still don't have any effect.

@flxzt
Copy link
Author

flxzt commented May 21, 2022

With mutter 42.1 on fedora 36, there should be external /multi monitor support for hybrid systems. ( this fixed issue ).

But when the boot flag is switched with the script gdm still does not start. With journalctl -u gdm -b I am getting:

Gdm: Child process -<some PID> was already dead.

I think it has to do with gdm starting before drivers are loaded, but not sure how to fix it.

@ewagner12
Copy link
Owner

Ok, I'm away from my egpu setup atm, but when I get back I will look into this. It could definitely be a timing issue like you say

@ewagner12
Copy link
Owner

Hey, sorry it took a while for me to get my hands on the hardware to test.

On my test system running Fedora 36, GNOME 42.1, NVIDIA driver 510.68.02, Linux kernel 5.17.11. GNOME Wayland desktop and gdm3 login screen also using wayland.

When switching to the nvidia eGPU as primary, on my system the external display connected to the eGPU works, gdm runs and I can login and everything, but the internal display stays black. I see the same error (fedora gdm[1266]: Gdm: Child process -3392 was already dead.) in the log, but it is not fatal. Note in /etc/gdm/custom.conf you can enable debugging to see more info in the logs.

So as far as I can tell on my end, the issue remains upstream that internal displays connected to the iGPU don't work when the nvidia eGPU is set as primary. The linked issue fixes the problem when the iGPU is primary, but not when the nvidia GPU is primary. It looks to me this is the same issue I am seeing: https://gitlab.gnome.org/GNOME/mutter/-/issues/2073

The only issue I could address within the script is that when you connect an nvidia eGPU without an external display and try to switch to it you are given a black screen. So if desired I could add a check to see if a display is connected and if no display is detected, report an error and switch back to the iGPU.

@flxzt
Copy link
Author

flxzt commented Jun 5, 2022

no worries, and thank you for taking the time to investigate this. I totally missed that the linked fix is only fixing iGPU with external monitors..
Personally I'll stay on X11 for the time being, but I think your proposed solution would be the best way to handle this on all-ways-egpu's side.

@JulioLoayzaM
Copy link

Hi. I have a similar problem, the internal display is not used when switching to the eGPU using either method, but gnome-shell does not crash. It's not a deal-breaker since I have a couple of monitors connected directly to the GPU.

It does sound like it is a mutter issue, so I left a comment on the issue you linked. In the meantime, thank you for developing all-ways-egpu!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants