As some of you have been able to read in the forum, I had proposed to install my hybrid graphics (ATI / Intel) in some of the many distributions that exist, since those of you who know this evil, you will know that the system leaves both graphics on even if it only uses one of the two, thus reducing battery life significantly, and giving your PC a new super power, that of frying eggs on top of it.
Much to my regret, I had to give up that end, since, in none of the distributions I tested (Debian, OpenSuse, Xubuntu y Linux Mint) I got some good results. This led to another statement of the problem:
How to get one of the two graphs, in my case the ATI, remains off?
The solution, as you will see below, is implemented in the core of our favorite distribution and is called vgaswitcheroo. And below you have the process, in which we assume that the package firmware-linux-nonfree is installed, for your use and enjoyment:
First we must find out if our core you have the option to use vgaswitcheroo:
$ grep -i switcheroo / boot / config- *
What will return a line in our terminal like this:
CONFIG_VGA_SWITCHEROO = y
If the output is different, you have to recompile the core to add the option to vgaswitcheroo. Second, we see if the file «/ sys / kernel / debug / vgaswitcheroo / switch » exists. At this point a distinction must be made:
To always have the folder accessible and to be able to access the file Switch, we must mount the debug folder as follows (always from superuser):
# mountpoint -q / sys / kernel / debug
# mount -t debugfs none / sys / kernel / debug
# echo "none / sys / kernel / debug debugfs defaults 0 0" >> / etc / fstab
Step 3 we can do it manually. It's about adding the line none / sys / kernel / debug debugfs defaults 0 0 to file / etc / fstab so that the vgaswitcheroo folder is always accessible even after a reboot.
Once this is done we can check our file Switch inside the folder vgaswitcheroo, through:
# cat / sys / kernel / debug / vgaswitcheroo / switch
and this returns an output like the one in the image:
Your output can be differences (All are in Pwr mode, for example). In this file we have several things to comment. The term DIS corresponds to the dedicated graphic (in my case, the ATI). The term IGD corresponds to the integrated graphics on the CPU (the Intel). The cross, +, check the print shop It is using at the time. And finally, the end Pwr o off, refer to graphics status.
With this, we can deactivate or activate the graph that we want through some commands:
- Turn off the dedicated graph:
# echo OFF> / sys / kernel / debug / vgaswitcheroo / switch
- Turn on the dedicated graph:
# echo ON> / sys / kernel / debug / vgaswitcheroo / switch
- Switch between integrated and dedicated:
# echo DIGD> / sys / kernel / debug / vgaswitcheroo / switch # echo DDIS> / sys / kernel / debug / vgaswitcheroo / switch
Finally, to grant permits to our usual user and thus be able to execute scripts at the beginning, for example, we will have to execute:
# chmod -R 705 / sys / kernel / debug # chown -R user: user / sys / kernel / debug / vgaswitcheroo
I hope it helps you to squeeze a little better the performance of your laptops or at least reduce the heat they give off.