You are not logged in.
Hi I'm using hyprland and it's my first time to install arch on my laptop(I had arch on my old pc).
When I unplug the AC cable the movement of cursor gets laggy and in btop I can see that cpu frequency drops to 400MH.
Does someone know how I can fix this?
Last edited by ninja8910 (2024-01-16 17:22:04)
Offline
Does pinning the CPU scaling governor to "performance" help?
for i in $(seq 0 $(($(nproc) -1))) ; do echo performance > /sys/devices/system/cpu/cpu$i/cpufreq/scaling_governor ; done
^ Run that from a root shell to test (it won't work if you just prepend `sudo`, use `sudo -i` or `su -` first instead).
I am presuming here that you don't have any power management frameworks such as TLP installed & running. If you're using TLP (or so) then try disabling that first.
Offline
yes I don't have any power management frameworks installed.
Last edited by ninja8910 (2024-01-14 14:51:25)
Offline
I did test the command before posting, are you sure you included all the parentheses? Copy&paste to avoid transcription error.
All it's doing is writing "performance" to /sys/devices/system/cpu/cpu$i/cpufreq/scaling_governor, where "$i" is the CPU thread number.
Offline
I entered the command again and it worked
So what now?
Offline
Does it help at all?
Offline
Nope it didn't change anything
Last edited by ninja8910 (2024-01-14 14:57:43)
Offline
You can set the minimum frequency level higher by altering /sys/devices/system/cpu/cpu$i/cpufreq/scaling_min_freq but it will probably kill your battery life.
Offline
So I can't fix it without killing my battery life?
Offline
That depends on whether the laggy cursor is actually caused by the low CPU frequency. My CPU also throttles to 400MHz but it doesn't make the cursor lag. I do have a pretty powerful CPU though (Ryzen 7735HS).
What is your hardware?
grep 'model name' /proc/cpuinfo | uniq
Offline
My cpu is Intel Core i5-11400H
Offline
Hmm, that's pretty beefy. Perhaps something else is going on here. Is it just the cursor that lags or do you notice any other performance deficiencies?
Offline
The whole laptop gets laggy for example while watching youtube if I unplug the AC cable it starts to drop frames
Offline
You don't have xf86-video-intel installed, do you? You shouldn't with that processor.
Offline
If the laptop has a discrete GPU does disabling it help? Could be that the battery simply can't drive both the CPU and GPU at the same time.
I have a gaming laptop but it's always plugged in for maximum performance and the power supply is 240W (!) compared to 65W for my ThinkPads with just integrated graphics. Even the ThinkPads struggle with games on battery power but work fine when plugged in.
Last edited by Head_on_a_Stick (2024-01-14 16:01:43)
Offline
Hmm that's a good idea. Yes it has a rtx 2050
That could be the cause because I didn't have that issue with windows 11.
Is there any way that I can make it automatically disable dgpu when the AC cable isn't connected and enables the dgpu agin when the cable is connected?
Offline
You don't have xf86-video-intel installed, do you? You shouldn't with that processor.
Yes I have that installed.
Offline
Remove xf86-video-intel. I'm surprised you can get to a desktop at all with that installed.
Is there any way that I can make it automatically disable dgpu when the AC cable isn't connected and enables the dgpu agin when the cable is connected?
Sounds like a job for a udev rule. I'm allergic to NVIDIA but perhaps try something like https://unix.stackexchange.com/question … vidia-gpus.
Offline
Scimmia wrote:You don't have xf86-video-intel installed, do you? You shouldn't with that processor.
Yes I have that installed.
Which means your graphics system is broken and falling back to software rendering. That doesn't work well, and is terrible when the CPU goes to minimum.
Offline
Remove xf86-video-intel. I'm surprised you can get to a desktop at all with that installed.
ninja8910 wrote:Is there any way that I can make it automatically disable dgpu when the AC cable isn't connected and enables the dgpu agin when the cable is connected?
Sounds like a job for a udev rule. I'm allergic to NVIDIA but perhaps try something like https://unix.stackexchange.com/question … vidia-gpus.
Nope disabling dgpu doesn't change anything
Last edited by ninja8910 (2024-01-14 19:28:58)
Offline
ninja8910 wrote:Scimmia wrote:You don't have xf86-video-intel installed, do you? You shouldn't with that processor.
Yes I have that installed.
Which means your graphics system is broken and falling back to software rendering. That doesn't work well, and is terrible when the CPU goes to minimum.
So what should I do?
Offline
As we've both said, get rid of it. You should never have had it installed with that processor at all. If you have any configs in /etc/X11/xorg.conf or /etc/X11/xorg.conf.d/ that specifically reference the intel driver, get rid of those, too or change them to modesetting.
Offline
As we've both said, get rid of it. You should never have had it installed with that processor at all. If you have any configs in /etc/X11/xorg.conf or /etc/X11/xorg.conf.d/ that specifically reference the intel driver, get rid of those, too or change them to modesetting.
I removed it and i also use Hyprland so i have Wayland
Still nothing changed
Last edited by ninja8910 (2024-01-14 19:38:12)
Offline
Ah, I completely missed that you were on Hyprland, my apologies.
Offline
Stuff like this is normally a lower level firmware bug. Check your UEFI whether there's some option to disable aggressive power saving/throttling, maybe check whether there's an UEFI firmware update. If neither is the case the firmware sometimes is in a buggy state. Shut the system down, and hold the power button during startup, that should™ reset the firmware state to something sane.
Offline