SRU: PRIME Power Saving mode draws too much power
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
HWE Next |
Fix Released
|
Undecided
|
Unassigned | ||
gdm3 (Ubuntu) |
Fix Released
|
High
|
Alberto Milone | ||
Bionic |
Fix Released
|
High
|
Alberto Milone | ||
nvidia-graphics-drivers-390 (Ubuntu) |
Fix Released
|
High
|
Alberto Milone | ||
Bionic |
Fix Released
|
High
|
Alberto Milone | ||
nvidia-prime (Ubuntu) |
Fix Released
|
High
|
Alberto Milone | ||
Bionic |
Fix Released
|
High
|
Alberto Milone | ||
nvidia-settings (Ubuntu) |
Fix Released
|
High
|
Alberto Milone | ||
Bionic |
Fix Released
|
High
|
Alberto Milone | ||
sddm (Ubuntu) |
Confirmed
|
Undecided
|
Unassigned | ||
Bionic |
Confirmed
|
Undecided
|
Unassigned | ||
ubuntu-drivers-common (Ubuntu) |
Fix Released
|
High
|
Alberto Milone | ||
Bionic |
Fix Released
|
High
|
Alberto Milone |
Bug Description
SRU Request:
[Impact]
Relying on the nouveau driver and on the vga switcheroo (to get around a change in systemd LP: #1777099) caused increased power consumption, and slowed down the switching process.
Furthermore, if the main X/Xwayland session was started by Gdm when the nvidia driver was loaded, the session will keep the nvidia module loaded, and prevent the system from switching off the dGPU. Also, the nouveau driver will be loaded, if nvidia is not, and this can cause problems to unsupported NVIDIA GPUs.
The solution involves the following changes:
1) Solving the problem in systemd (LP: #1777099)
2) Adding code in gpu-manager and in nvidia-prime to unload the nvidia modules, and to allow the PCI device to sleep.
3) Making a slight change to the current patch in Gdm, used to call the PRIME scripts before and after a Gdm session (so that gpu-manager gets actually called on log out)
4) Adding code in gpu-manager to kill the main X/Xwayland session on log out, if the session is preventing us from unloading the nvidia driver. A new X/Xwayland session will be created after unload the module.
5) Removing the systemd service that loads nouveau from the nvidia packages.
[Test Case]
1) Enable the -proposed repository, and install the new "ubuntu-
2) Make sure the nvidia packages are installed, and enable performance mode (if it is already enabled, call "sudo prime-select intel" first):
sudo prime-select nvidia
3) Restart your computer and attach your /var/log/
4) Select power saving mode:
sudo prime-select intel
5) Log out and log back in
6) Check if the nvidia driver is still loaded:
lsmod | grep nvidia
[Regression Potential]
Low, as hybrid graphics support does not work correctly, and the changes only affect this use case.
_______
* Steps to test the updates:
1) Enable the bionic-proposed repositories
2) Create /etc/apt/
Package: *
Pin: release a=bionic-proposed
Pin-Priority: 400
3) Update the list of packages:
sudo apt-get update
4) Install the packages from -proposed using the following command:
sudo apt install nvidia-
Related branches
- Iain Lane (community): Needs Fixing
-
Diff: 240 lines (+115/-40)3 files modifieddebian/patches/series (+1/-0)
debian/patches/ubuntu_nvidia_prime.patch (+46/-40)
debian/patches/unblock-sigusr1.patch (+68/-0)
- Marco Trevisan (Treviño): Approve
- Ubuntu Desktop: Pending requested
-
Diff: 84 lines (+33/-18)2 files modifieddebian/changelog (+8/-0)
debian/patches/ubuntu_nvidia_prime.patch (+25/-18)
CVE References
Changed in gdm3 (Ubuntu): | |
status: | New → In Progress |
importance: | Undecided → High |
assignee: | nobody → Alberto Milone (albertomilone) |
Changed in gdm3 (Ubuntu Bionic): | |
assignee: | nobody → Alberto Milone (albertomilone) |
importance: | Undecided → High |
status: | New → In Progress |
description: | updated |
Changed in nvidia-graphics-drivers-390 (Ubuntu): | |
status: | New → Fix Released |
Changed in nvidia-graphics-drivers-390 (Ubuntu Bionic): | |
status: | New → In Progress |
Changed in nvidia-graphics-drivers-390 (Ubuntu): | |
importance: | Undecided → High |
Changed in nvidia-graphics-drivers-390 (Ubuntu Bionic): | |
importance: | Undecided → High |
Changed in nvidia-graphics-drivers-390 (Ubuntu): | |
assignee: | nobody → Alberto Milone (albertomilone) |
Changed in nvidia-graphics-drivers-390 (Ubuntu Bionic): | |
assignee: | nobody → Alberto Milone (albertomilone) |
description: | updated |
summary: |
- PRIME Power Saving mode draws too much power + SRU: PRIME Power Saving mode draws too much power |
Changed in gdm3 (Ubuntu): | |
status: | In Progress → Fix Committed |
Changed in nvidia-settings (Ubuntu): | |
assignee: | nobody → Alberto Milone (albertomilone) |
importance: | Undecided → High |
status: | New → In Progress |
status: | In Progress → Fix Released |
Changed in nvidia-settings (Ubuntu Bionic): | |
assignee: | nobody → Alberto Milone (albertomilone) |
importance: | Undecided → High |
status: | New → In Progress |
tags: |
added: verification-needed-bionic removed: verification-failed-bionic |
tags: |
added: verification-failed-bionic removed: verification-done-bionic |
tags: |
added: verification-needed-bionic removed: verification-failed-bionic |
description: | updated |
tags: |
added: verification-done-bionic removed: verification-needed-bionic |
tags: | added: originate-from-1788575 somerville |
Changed in gdm3 (Ubuntu Bionic): | |
status: | Fix Committed → Fix Released |
Changed in ubuntu-drivers-common (Ubuntu Bionic): | |
status: | Fix Committed → Fix Released |
Changed in nvidia-settings (Ubuntu Bionic): | |
status: | Fix Committed → Fix Released |
Changed in nvidia-prime (Ubuntu Bionic): | |
status: | Fix Committed → Fix Released |
Changed in nvidia-graphics-drivers-390 (Ubuntu Bionic): | |
status: | Fix Committed → Fix Released |
Changed in hwe-next: | |
status: | New → Fix Released |
Here is a PPA with the current code for Bionic, available for testing: /launchpad. net/~albertomil one/+archive/ ubuntu/ hybridgraphics? field.series_ filter= bionic
https:/
You will have to upgrade systemd, nvidia-prime, and ubuntu- drivers- common, call "sudo update-initramfs -u" (just in case), and reboot