-
Notifications
You must be signed in to change notification settings - Fork 669
fix(profiles): install power-profiles-daemon by default in the desktop profile #4015
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
base: master
Are you sure you want to change the base?
Conversation
|
You'd need to enable the service too and not all DEs package an integration to this, I have a similar patch here |
power-profiles-daemon and tuned (via tuned-ppd) are both started by D-Bus automatically, this could possibly be an issue for people who end up installing a window manager and not one of the big desktop environments, but we're also shipping pipewire which is started by D-Bus too and no one has complained yet (that I can see) so it should be fine?
All the full desktop environments that currently have profiles support it (i.e: GNOME, Plasma, Cinnamon, COSMIC, Xfce, etc.) out of the box without any additional packages as long as something is providing the expected D-Bus interface. I guess it could be considered 'bloat' for some people who end up installing a window manager, but I suspect even laptop users who install a window manager will end up installing either this or tuned. |
|
It's made available for control over d-bus but I think it still needs to be explicitly enabled through |
|
My bad then. Huh I think it's a good change, not sure I'd do it by default for desktops, hence why I wanted a new |
|
There is an open issue for this #2557 which a discussion running there and I can see people suggesting I think this will potentially need at least a selection between the 2 and maybe even only be available if the host device is a laptop/battery? |
|
I personally don't see the benefit of tuned over power-profiles-daemon as both it and power-profiles-daemon essentially do the exact same thing, but I'm not completely against it either, it is arguably more customizable to the end user (which is really the only point brought up in the Fedora proposal that is linked in the discussion). If anyone has any arguments in favor of tuned, feel free to attempt to persuade me! I'm just personally not a fan of the long startup time of tuned (~400ms or so on my older laptop) since well, it's written in Python, and I think presenting users with the option to pick between the two could potentially confuse newer users who may not know the differences between the two, or even what their purpose is. I definitely agree with the laptop/mobile device check though, I'll experiment with some things and work on implementing that. |
|
I added a check to see if a battery is present before installing the package in a5573ce. It's very naïve and could potentially have false positives with weird hardware since it simply checks if a battery is present on the machine and nothing else, but it works on my test machines (desktop and multiple laptops) without any problems so it should be alright. I also wasn't really too sure if this is the ideal location to put this snippet, even after looking around for a bit, but I figured since it was profile specific it belonged there in |
|
Hey since you're ln a roll you mind reading over this: Does this imply changes for Brain doesn't work properly have some fever lmao Also saw an older pull requests about this to let users pick non-dkms (and not install headers) |
|
Yes it would, I have a branch over in my working repository for changes related to this, just haven't gotten around to finishing them and I think it's time for me to clock out for the day :) I'll probably open a pull request sometime soon (in a couple of days?) as I'm hoping to land them before the January monthly .iso release, discussion can continue there when that happens as to not fill this thread with unrelated discussions 👍 |
| class SysInfo: | ||
| @staticmethod | ||
| def has_battery(): | ||
| for device in os.listdir('/sys/class/power_supply/'): |
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.
Can be simplified with
Path('/sys/class/power_supply/').glob('*/type')
|
As there are alternatives to PPD available https://wiki.archlinux.org/title/CPU_frequency_scaling#Userspace_tools I'd prefer if this is a new option in the |

This pull request adds the power-profiles-daemon package to the desktop profile by default.
I have a feeling that most users probably end up installing this (or something similar such as tuned) after installation or by selecting it in the additional packages menu anyway, especially people doing installations on laptops or other mobile devices, so it may be worth it to just install this by default for people selecting the desktop profile.
This also has the benefit of improving battery life on laptops and other mobile devices for users who may not know they need to install this package to get basic power management functionality.