Now I am making a mental note of when it occurs, it could be soon after plugging in a usb-c power supply of which I use 2 in different locations, a UGREEN 65W USB C Charger Plug 2-Port GaN Type C and an ASUS USB C that came with an ASUS ZenBook.
The other result of the lagging is after the reboot, the screen brightness is set at its lowest. This could be a result of the auto brightness not take effect during the “laggy” period and its just a cumulative result of not being able to be set or something else.
Anything else you can think of I can attempt to run during a “laggy” phase to help diagnose?
You can add the patches for the cros-ec driver and then use the EC tool to get an EC console log when this occurs and share that with Framework support.
Can you direct me to where to find instructions for that.
Also, this morning Fedora 39 upgraded to Linux 6.7.9-200.fc39.x86_64, I was on 6.7.7 before when I experienced the lagging. So have experienced the lagging on both kernel versions at least.
If you haven’t already I suggest installing the bios 3.03b which has an updated EC. Its conceivable to be a similar manifestation as the DPC violation in windows which was fixed in 3.03b.
Ok, given I don’t have the mental capacity to handle the EC tool scenario and I only want to change one thing at a time in the spirit of the scientific method I decided to try the 3.03b, will report back should the laggyness emerge.
I plan to go on the Fedora 40 Beta once that is released, its pretty soon, but I haven’t got my head around the Fedora Schedule as it looks like the Beta date has been moved a few times.
For reference this is what s-tui looks like when its running normally:
It would be a pity to lose the history that built up over time, so I guess that keeping the discussion going on here is the best course of action and also avoids wasting precious MOD time to move messages to another thread. —
@Matt_Hartley I would just kindly ask, if possible, to copy paste this message at the beginning of my OP, for new visitors/Googlers to see, and rename to somethink like [FW 13 AMD 7840U] Cores stuck at low frequency and system lag. Thanks!
It’s been a week and I’ve upgraded to Fedora 40 Beta with 6.8 kernel (Linux 6.8.1-300.fc40.x86_64) on Friday 22nd (a bit early, but honestly Fedora Betas are more stable that most production OSes).
No sign of the “lagging”, as I think about it I wonder if its related to “Suspend”. The only occassion I see Suspend happen is when I haven’t explicitly triggered it is after a reboot and I haven’t logged in… I’ve disabled close lid suspend.
So potentially the issue is caused by a post unsuspeded state after I’ve absent mindedly logged in… not the greatest scientific data, apologies.
Immediately post install of the 3.05 bios I had the “lagging”.
I’m going to do a fresh install of Fedora 40 once that is out of the beta.
My concern is some of the recommended tweaks for the things like sg_display and mesa drivers are too many variables to make for a fair clean reproducible test.
I try not to get too gnarley with my linux configs & tweaks, and I do like to track them, the only other slightly off piste thing I do is configure the laptop not to sleep when closing the lid which is controlled here /etc/systemd/login.conf I can’t imagine that has any impact, but given the tapestry of libraries and configs I can’t be sure.
This behavior was sort of fixed for me for a while, but it’s back now (or at least a similar behavior). Frequency is not hard capped this time, but will stay below 1 GHz generally, with short spikes to up to 1.7 GHz. Power as measured by ryzenadj does not exceed 11.7 W. I’m using ryzenadj to monitor only, I’m not actually tweaking anything. Needless to say, performance is badly capped in this state.
It’s difficult for me to pinpoint which change brought this behavior back. I am on OpenSUSE Tumbleweed, so I get regular kernel updates. I also moved to PPD not so long ago and upgraded the FW. PPD definitely had a beneficial effect on battery life and in general works well. The system only seems to gets stuck in this low-power state after suspend-resume cycles.
To get the system unstuck, I tried changing the power profile, stopping or re-starting the PPD service, setting scaling_governor (this used to fix it for me) or energy_performance_preference manually, plugging or un-plugging power supply, suspending and resuming (both on AC and on battery), to no avail.
This is and AMD FW13 (7840U) on Kernel 6.8.8, power-profiles-deamon 0.21, FW 3.05.
Any hints on what to try to get the system unstuck? I know a reboot will fix it, but that’s not an acceptable solution while working. Hibernating and waking the system back up works to fix the frequency scaling, but then Wifi is broken…
I’m using ryzenadj to monitor only, I’m not actually tweaking anything. Needless to say, performance is badly capped in this state.
Can you specifically try comparing /sys/kernel/debug/amd_pmf/current_power_limits in a failure vs non failure? That would help confirm if there is an EC bug with a power limiter.
It’s difficult for me to pinpoint which change brought this behavior back.
I think a likely cause is the EC triggering thermal throttling; but I don’t have a good way to prove that by reading any registers or so. Maybe if you can monitor the EC debug log in one tab you can check the last messages it emits?
To get the system unstuck, I tried changing the power profile, stopping or re-starting the PPD service, setting scaling_governor (this used to fix it for me) or energy_performance_preference manually, plugging or un-plugging power supply, suspending and resuming (both on AC and on battery), to no avail.
None of those things working really does make me suspect thermal throttling by the EC as well…
By chance - did you happen to unplug the power adapter while in suspend when this issue happened? I’m aware of a bug report in kernel bugzilla with another manufacturer that has a bug with this. It LOOKS like a thermal event sequencing problem with that manufacturer, but if you can confirm the same thing is happening on your Framework 13 that would be a really interesting data point.
Any hints on what to try to get the system unstuck?
If it’s the same thing as that other manufacturer and caused by power adapter changes while in suspend, plug in and then unplug the power adapter after you’ve resumed. See if that brings it back to normal.
Thanks for your quick reply! My system is unstuck again for now (hibernate / resume / unload wifi kernel module / reinsert kernel module), but I’ll check these as soon as I get a chance.
I don’t remember for sure, but this might be the case. I’ll try that this weekend, to see if I can reproduce this.
So far, I haven’t been able to reproduce the behavior.
I’m pretty sure the power limits shown by ryzenadj were not lowered when the system was stuck. The power consumption stayed way below the limits I could see (was running watch -n 1 ryzenadj in a terminal while the system was stuck. I didn’t take a screenshot though).
FWIW I don’t think it’s just you. I think it’s probably your combination of devices/chargers triggering a bug somewhere. My educated guess from these kinds of bugs is that it’s most likely in the EC or PD controller.
Note down EXACT order of events and what devices caused it. Did you have it plugged in before suspend, did you unplug during suspend? How did you wake it? Did you have a dock connected, is it tied to that?
If you can reproduce it at will with a sequence of events and devices then it’s more likely Framweork support can too and then they can capture debug information to fix it!