-
Notifications
You must be signed in to change notification settings - Fork 129
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
[Nvidia Optimus] SOUND_POWER_SAVE_ON_AC=0 prevents power down of the GPU #495
Comments
the hang was caused by a kernel bug we fixed in the meantime. I don't think that TLP was responsible for that. But I agree that on laptops those defaults need to change in order to power down GPUs even when the AC is plugged in. |
By the way: this is a reoccurring problem on our end and it wastes our time as we need to debug with users why their GPU is not suspending. So please fix this. |
SOUND_POWER_SAVE_ON_AC=0 (and splitting the setting between AC and BAT) was chosen as compromise for the sound disturbances that many user had when sound power save was active for both AC and BAT. So the simple solution of changing the default leads to annoyance with other users. @karolherbst : what are the kernel defaults (without TLP) for systems with nouveau?
for the nvidia card and
for the audio? I'm thinking about blacklisting i.e. not touching audio power save at all when nouveau ist detected. |
@linrunner I obviously don't know all the configurations and tradeofs like you do, but 2 ideas:
|
by default everything suspends. |
well.. to be more correct here, it depends on the kernel build, but distributions tend to build with SND_HDA_POWER_SAVE_DEFAULT=y these days. |
This is probably the reason why owners of Nvidia Optimus laptops are so enthusiastic about the power consumption ;) Just to be sure (as I don't have access to Optimus hardware): the nouveau kernel driver sets control = auto for the PCIe device? |
@marcmerlin : the real tradeoff is that your charger is severely underspecced and this could very well be the reason for the crashes. You have to come to terms with the consequences of your free decision. Enough said about that (including #494). But the core problem here is that the Nvidia doesn't suspend when audio power save is off. Could you do me a favour?
for both via https://gist.github.com/ |
@linrunner to be clear, I have no more crashes since I applied the sound suspend fix, so honestly all is good on my side. |
Yes, please. And thanks for the clarification. |
yes |
Rationale: * amdgpu, nvidia: blacklisting will actually prevent the GPU from suspending when unused, which is not what users expect * pcieport: there have been no indications of problems recently Note: nouveau selects 'auto' by default, so keep it blacklisted to not interfere. References: * #488 * #498 * #495 (comment)
Rationale: disabling sound power saving interferes with nouveau (driver enables runtime pm by default) so that the GPU doesn't suspend when idle. Solution: default to SOUND_POWER_SAVE_ON_AC=1. Discussion: consideration showed that excessive power consumption of the GPU will annoy users of TLP much more than occasional sound disturbances. Reference: * #495
@marcmerlin : I changed the default to default to SOUND_POWER_SAVE_ON_AC=1, thanks for your arguments. Because of @karolherbst remark i waive warning about crashes. |
@marcmerlin : i'm still longing for your outputs ... |
I think it would make more sense to default to whatever distributions are doing here as it seems like in the past there were some bugs and I'd feel better if by default distributions choice is honored here. On newer kernels it's probably not an issue.. more thinking about older debian releases or something. |
@linrunner sorry for the delay. I have lots of work on my laptop right now that I can't easily shut down. it will probably take a while before I can reboot, sorry. I will get this to you though. |
@karolherbst : TLP's mission is to be more aggressive than the defensive kernel/distribution defaults. People have been telling me for 10 years that kernel optimizations will soon make TLP redundant; however, this has not yet happened ... @marcmerlin : Don't stress yourself, please, it's not that important. |
* Hybrid graphics, moved from faq/graphics * Limit CPU PD, moved from faq/graphics * Remove refs to Bumblebee (way deprecated) References: * linrunner/TLP#488 * linrunner/TLP#495 * linrunner/TLP#498
There you go, AC and BAT with tlp off, and then again with after TLP was turned on. Hope this helps. 00:00.0 Host bridge: Intel Corporation Device 3e20 (rev 0d) |
Now I'm confused. In your initial post you characterized your problem with:
But your outputs show that no driver is loaded, which is an indication that the proprietary driver nvidia is installed and Intel (Power Saving Mode) selected in their tool:
So I'm afraid the outputs are (a) unrelated to your problem and (b) don't help me to check the runtime pm default of the nouveau driver on your hardware. |
@linrunner I can assure you that the binary nvidia driver was never installed on that machine
The binary driver, if present, would be here:
(that's another machine) I do have nouveau installed and loaded, as it is required to turn the nvidia chip off:
|
Thanks for the clarification and your patience. Then i'll have to get hold of a similar hardware to check why tlp-stat doesn't display the driver. |
So, one thing I did notice, is that the nouveau driver hadn't self loaded after boot, not entirely sure why. Maybe it's because I booted in battery (as per your request). I did manually insert the driver while X was running and got this Maybe I can'shoutld force the loading of that driver in /etc/modules , not sure why it stopped autoloading this time. |
OK, that's the expected result. |
FAQ done. |
I'm not sure if there is a way to auto detect or document this.
Problem:
When the nouveau driver is loaded on my lenovo thinkpad P73 laptop with hybrid graphics (where I only use i915 to save batteries), while the driver does not yet properly support my chip for external display, it is required to power down the chip and save 40W.
With TLP, I started getting hard hangs when plugging power in
Fix:
Symptom:
(hang)
Rationale:
https://lists.freedesktop.org/archives/nouveau/2020-May/036016.html
https://lists.freedesktop.org/archives/nouveau/2020-May/036019.html
"note that TLP has a problem where it forces the audio
sub-function to always-on which prevents the GPU from suspending."
The text was updated successfully, but these errors were encountered: