-
Notifications
You must be signed in to change notification settings - Fork 70
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
Switch graphics mode without reboot #119
Conversation
669b096
to
80bb803
Compare
9ef7d46
to
9b85470
Compare
hi whats up with the review? :) |
Hey thanks for doing this! |
I began testing this and it's looking good, but it's definitely a WIP at the moment. Here is what I'm seeing:
Once we're further along, we can start doing some more testing! |
I would imagine we want to have the messaging and dialog restart the session/GDM for the user. We can probably co-opt the current reboot dialog for that. |
9b85470
to
8fd3601
Compare
Need to investigate runpm. I'm seeing the card left Restarting GDM fixes it. Not sure why it interferes with runpm. |
a8963ad
to
3ea9acd
Compare
I can take another look to see if I can make it happen again, though it looks like the latest eoan build didn't succeed. Once it builds again I will see if it's still an issue and gather logs if it is. |
3ea9acd
to
1d561f4
Compare
self.set_power(true)?; | ||
} | ||
|
||
let status = process::Command::new(SYSTEMCTL_CMD) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
gpu-manager is configured to run before display-manager, so implementing a display-manager restart would allow this call to be removed.
1d561f4
to
a8d3d45
Compare
Great feature, hope it gets merged soon. |
@crawfxrd are we expecting this to function in 18.04 (between Intel and NVIDIA modes)? |
It looks like the required logic exists in |
Any plans to merge this |
By further utilizing gpu-manager, we can perform most operations for switching graphics modes without requiring a reboot. In order for switching and runpm to work correctly, GDM must be restarted. This will end all running GNOME sessions. system76-power graphics <mode> systemctl restart display-manager See: #57
a8d3d45
to
874bec5
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have been unable to recreate the issues seen previously. This looks good to me.
Things to note going forward:
- We should backport this to master_bionic as well Backport switching graphics without reboot to bionic #135 (if possible).
- There should be frontend updates to expose this in the gnome-shell extension Support graphics switching without reboot gnome-shell-extension-system76-power#34
Because this can't be implemented cleanly (must kill all X sessions), we're going to keep requiring a reboot. Steps in #57 will still work. |
By further utilizing gpu-manager, we can perform most operations for switching graphics modes without requiring a reboot.
In order for switching and runpm to work correctly, GDM must be restarted. This will end all running GNOME sessions.
See: #57