Hprofile

is a little application that can be used to manage multiple profiles be it hardware or software. The following subsection are just examples on what could be done with hprofile.

To be able to to go further, one should, of course, merge the package.

Power
When thinking a better to have different dynamic power profiles that could dynamically switched depending on hardware of software state is not straightforward especially for power management which could depend on many software e.g., , to name a few. So how could you get hardware profiles and switch between them dynamically? And how to get everything together? How many deamons to start depending on what hardware or software state?

That sum up quite a few considerations to what a user can face when trying to build a nice setup with power management in mind. [S]he can remember of Windows(tm) days power management profiles if [s]he ever used it. Or else, [s]he did not any thought about it because [s]he used to run a GNU Linux or BSD based distribution with everything putted together and does not know how to begin with if [s]he is not satisfied with what [s]he gets.

Now -2 grew up to be quite a good piece of software. If you're runnng an Intel based platform, you can get access to pretty much everything one would expect if trying to build power manager profiles. But the package does not ship with a daemon nor with a configuration or profile file which PowerTOP could pick up when launched in the next restart. One has to launch it again and again in a terminal and enable power management for every power manageable hardware.

Now, it will a bit long to go pick enough power management tuning that a software like PowerTOP use to be able to manage almost everything. This is just a beginning to that. One can use [[ACPI]d to switch between different hardware profiles depending on hardware state.

This basic profile will try to implement Hprofile, CPU (see Hprofile, network interfaces and ALSA drivers power saving capabilities.

One would need the following files to set up basic power management profiles.

I have a battery runlevel, a copycat of default runlevel, that is dynamically switched if AC power is unplugged. See ACPI article for more info. That's not enough? Do you want more tunings? Expand the article then! I wish PowerTOP implement a daemon-ish profile-able application which is the right sport for Intel based hardware.

RFKill
This hardware profile subsection could be beneficial to the previous section, but killing radio of devices can be quite troublesome which require hard reboot and removing battery/AC power for a few second to be able to get back usable wireless interfaces again. This happen on my Intel GM45 based laptop. Luckily there is a physical switch to kill bluetooth and wifi radio.

There's no much consideration for this section, if your hardware support RFKill, add it to your hardware profile!

VGA
I use to manage VGA profile to my laptop and my desktop. On my desktop, I use hprofile to switch between nvidia-drivers, nouveau and nv when the previous profiles do no work; and to switch radeon and intel on my laptop which has switchable graphics via VGASwitcheroo.

Just be sure to built kernel modules about everything — at least i9{1,6}5, nouveau, radeon, ttm, drm, and optionally (?) ac, button, video, i2c-algo-bit — to avoid useless hassles.

Create the necessaries folder /etc/hprofile/profiles/vga/{scripts,files/etc/X11/xorg.conf.d} and add the following files.

And with that, you should be able to switch vga profile as you like without needing an extra kernel and setup.

The ptest script will just look if VGASwitcheroo is available and which driver is loaded and then start the appropriate profile. One can black list a module and leave the other un-black listed to be able to chose ...a default VGA profile. Or else, use of `/etc/hprofile/profiles/vga/default' file.

Hard disk
A disk profile is even straightforward because there fewer issue to keep in mind. So this section will be short and straightforward. Additionally, one need.

External resources

 * Power management/Processor - See that article for CPU power management insight.