Note: this is an ongoing process which I'm documenting here. Semi-experimental, but this is my daily driver machine since September 2021 (work included), so I'm aiming for stability (hence why I'm not using the recommended Fedora 39 Beta).
Upgraded from an Intel i7-1165G7 to AMD 7080U mainboard:
- 64GB (2x32GB) G.Skill F5-5600S4040A32GX2-RS
- Have an SK Hynix 16GB (2x8GB) 4800MHz (HMCG66MEBSA095N BA) kit that I'll test just to see power draw difference.
- SK hynix Gold P31 2TB PCIe NVMe Gen3 M.2 2280
These notes are for Fedora 38 6.5.8-200.fc38.x86_64 with SwayWM.
Booted into Fedora with BIOS 3.02 and seemed fine. First thing I did was upgrade to 3.03.
I plan on installing PTM7950, but initial thermals seem very good so it may not be worth it?
Remove flags from bootloader:
nvme.noacpi=1
- It's for SSD suspend power savings, but apparently for Intel not AMD. There are reports of that breaking suspend. It broke suspend on mine. To remove:
- `sudo grubby --update-kernel=ALL --remove-args="nvme.noacpi=1"``
modprobe.blacklist=intel_ish_ipc
- I have had this blacklisted for a long time since this would cause hibernation to fail to resume on the i7-11165G7. Since it's obviously for Intel, to remove:
sudo grubby --update-kernel=ALL --remove-args="modprobe.blacklist=intel_ish_ipc"
- It's for SSD suspend power savings, but apparently for Intel not AMD. There are reports of that breaking suspend. It broke suspend on mine. To remove:
- Had to turn off UEFI Secure Boot as (I had before) to support
suspend-then-hibernate
. Journal logs said:Call to SuspendThenHibernate failed: Sleep verb "suspend-then-hibernate" not supported
kernel: Lockdown: systemd-logind: hibernation is restricted; see man kernel_lockdown.7
The latest version of TLP is 1.6.1 and at least 1.6.0 is needed for CPU_ENERGY_PERF_POLICY_ON_AC/BAT_: now supports AMD Zen 2 or newer CPUs (requires _amd-pstate_ driver as of kernel 6.3)
, but only 1.5.0 is out currently on Fedora 38. However, there's a 1.6.0 build on Koji.
Edit (2023-11-24):
I upgraded to Fedora 39 and there is no >1.6.0 build available so I installed from source:
https://linrunner.de/tlp/installation/others.html
Installing only tlp
and not tlp-rdw
:
sudo make install-tlp
sudo make install-man-tlp
sudo systemctl enable tlp.service
Remember to uninstall when it's available with:
sudo make uninstall-tlp
sudo make uninstall-man-tlp
sudo systemctl remove tlp.service
Useful:
- https://koji.fedoraproject.org/koji/packageinfo?packageID=18453
- https://blog.packagecloud.io/working-with-source-rpms/
To install TLP 1.6.0:
- Download
tlp-1.6.0-1.fc38.noarch.rpm
from https://koji.fedoraproject.org/koji/buildinfo?buildID=2308060. - Install:
sudo dnf in tlp-1.6.0-1.fc38.noarch.rpm
- Reconfigure TLP using the default 1.6.0 version:
/etc/tlp.conf.rpmnew
By default, /sys/module/workqueue/parameters/power_efficient
is set to N
. I wonder if I should set to Y
, but cursory research leads me to believe it's not worth it.
My TLP config is down below.
Notable info:
- 5% brightness
- No peripherals, webcam/mic switches off, keyboard lights off
- Just a USB-C expansion card in top left and top right port
- intel AX210
- Not stock Fedora 38/SwayWM. This is a daily driven work/personal installation has that started from Fedora 33 (Gnome).
idling around ~3.6W. Big Buck Bunny (1080P) on mpv: ~6.15W, with or without VAAPI for some reason.
Previous ~/.config/mpv/mpv.conf
:
vo=gpu
hwdec=vaapi
Current ~/.config/mpv/mpv.conf
:
hwdec=auto
Oddly I get Cannot load libcuda.so.1
in journald logs when turning HW decode on.
Useful:
- https://wiki.archlinux.org/title/AMDGPU
- https://wiki.archlinux.org/title/Hardware_video_acceleration
I removed intel-media-driver
. After running doing the steps from:
- https://fedoraproject.org/wiki/Firefox_Hardware_acceleration#Configure_VA-API_Video_decoding_on_AMD
- https://rpmfusion.org/Howto/Multimedia My power consumption went drastically up to ~5W idle, ~8W Big Buck Bunny. I couldn't figure out why the entire day (hardware acceleration is still pretty messy). Puzzling, but I managed to pin it down to to a few things:
I was getting these errors in journald logs occasionally:
kernel: i2c_hid_acpi i2c-FRMW0005:00: i2c_hid_get_input: incomplete report (7/65535)
kernel: i2c_designware AMDI0010:00: i2c_dw_handle_tx_abort: lost arbitration
Which I thought prevented the system from idling. I found this for the incomplete report
error. Apparently that solution (which does not work and will break/keep the display brightness at 100%) was adding acpi_osi=
to kernel params. Which reminded me and led me to this.
I did this:
sudo grubby --update-kernel=ALL --args='"acpi_osi=!Windows 2020"'`
and rebooted, and my idle power consumption finally went back down to ~3.7W...but it didn't fix the errors, and I didn't have that before so I removed/reverted it. And it continued to idle at ~3.7W, so not I'm sure what happened. So in the end, I do not have and would not add "acpi_osi=!Windows 2020"
.
But I do know that with wifi power management:
- off (TLP
WIFI_PWR_ON_BAT=off
): ~4.5W idle - on (TLP
WIFI_PWR_ON_BAT=on
): ~3.7W idle
So I might have just had wifi power management off at the time.
The Hardware codecs with AMD (mesa)
section of https://rpmfusion.org/Howto/Multimedia says to run:
sudo dnf swap mesa-va-drivers mesa-va-drivers-freeworld
sudo dnf swap mesa-vdpau-drivers mesa-vdpau-drivers-freeworld
Which installed these freeworld drivers:
mesa-va-drivers-freeworld-23.1.9-1.fc38.x86_64
mesa-vdpau-drivers-freeworld-23.1.9-1.fc38.x86_64
That increased Big Buck Bunny to ~7.2W with VAAPI HW decode on. With it off, it decreased down to ~6.1W. So for some reason, HW decoding with the freeworld drivers is using more power.
So I reverted the freeworld drivers to:
mesa-vdpau-drivers-23.1.9-1.fc38.x86_64
mesa-va-drivers-23.1.9-1.fc38.x86_64
This is an easy way to do it.
Without the non-freeworld drivers, for Big Buck Bunny, VAAPI hwdec on or off doesn't make a difference in power consumption (not sure why).
Also notably for Firefox YouTube 1080P:
- freeworld: ~11.6W
- non-freeworld: ~8.7W So the freeworld drivers seem to be causing excessive power use.
I also noticed that video playback power consumption was slightly higher when I had set display fractional scaling to 1.25
in SwayWM. Currently sway-1.8.1-1.fc38.x86_64
with wlroots-0.16.2-2.fc38.x86_64
. This might be fixed with newer versions and wp-fractional-scale-v1
? Will try later in Fedora 39 when it's stable to upgrade to. For Firefox YouTube 1080P:
- No scaling: ~8.7W
- 1.25x scaling: ~9.2W
The ffmpeg
and gstreamer1-plugins-bad-freeworld
seems fine.
I added the nodiscard
mount option to /etc/fstab
to disable discard=async
because I was seeing btrfs_discard_workfn
occasionally pop up in powertop
and it would cause a spike in power usage from 1W to a few W.
And am using the default fstrim.timer
that executes fstrim.service
weekly. How to test it's working setup/working correctly: https://fedoraproject.org/wiki/Changes/EnableFSTrimTimer#How_To_Test
See:
- https://wiki.archlinux.org/title/btrfs#Constant_drive_activity
- https://www.reddit.com/r/btrfs/comments/12ygwkz/should_i_disable_btrfs_discard_on_kernel_62_and/?rdt=54887
- https://discussion.fedoraproject.org/t/btrfs-async-discard-leads-to-higher-power-consumption/81006
- Idle: ~3.6W
- Big Buck Bunny 1080P VAAPI HW decode: ~6.2W (has gone down to ~5.9W)
- Big Buck Bunny 1080P no HW decode: ~6.2W
- Firefox YouTube 1080p: ~8.7W
I also tested power-profiles-daemon
set to power-saver
profile.
> powerprofilesctl set power-saver
> powerprofilesctl get
power-saver
Note: I did not try this, but apparently leads to increased power savings paired with PPD. Numbers below are just stock PPD:
Idle: ~4.6W, but strangely after trying again it went down to ~3.7W
Big Buck Bunny: ~7.75W, but strangely after trying again it went down to ~7.1W
YouTube 1080P Firefox: 11.3W
The repo is archived now? Also, don't think PPD is using the lowest power consumption GPU profile, which may explain the higher video playback numbers?
Just saw this proposal today to replace PPD with tuned
for Fedora 40: https://fedoraproject.org/wiki/Changes/TunedReplacesPower-profiles-daemon
Compared to my i7-1165G7, idle and video playback numbers are about the same (I expected much lower, but still a good sign since it's still early on since kernel/firmware/software/etc. optimizations will come). However, in actual mixed usage, it seems like average power usage is noticeably lower, while being noticeably faster (the core count and compilation speeds, giggity). Will see exactly by how much with further usage.
With these video playback numbers, it would last less than the 13th gen Intel, though I expect this will improve with optimized drivers et al.
Tip: using powertop
and setting it to update every 10 seconds instead of default 20 (press s
key, type in 10
, then press enter) IME gives quick enough feedback. I set a stopwatch on my phone so I know when every 10 seconds is so I can see the updates/commit to my memory/write them down. Default 20 seconds is fine, and longer durations may be better to get closer to true idle numbers since updates take some amount of CPU, but 10 second updates IME is long enough. Anyway, there will be lots of staring at your screen to wait for numbers to stabilize. I've settled on measuring at ~2 minutes with keeping an eye on it occasionally before -- usually things settle in ~1 minute.
- 0% brightness no longer turns the screen fully off?
- No longer hear a beep from the headphone jack whenever the audio card goes to sleep. I experienced this with the Tempo audio chip on my previous replacement mainboard. Did not experience this on the first Realtek audio chip mainboard, and am glad that I don't experience it on this AMD mainboard.
- It would be nice if Battery Care support was added to TLP for Framework devices which should be possible because charge limits can be set in the BIOS. There are some issues/commits/pull requests for other brands that can be looked at to see how (and there are many). I may investigate further when time permits.
It seems like hibernation/resume (suspend to disk with 64GB) is much faster (DDR5 vs DDR4? Faster CPU?). Haven't thoroughly tested though, it was just from only a few GB used in RAM.Nevermind, might be faster? but still takes a while. The SSD is probably the bottleneck since it's writing up to 64GB to disk.- New BIOS UI is much nicer!
- IIRC, Framework has tuned the audio circuitry for the AMD mainboard for the original speakers, and there was a user report of improvement. I don't want to swap in my old mainboard back to test yet but may in the future to compare some things. On my not-80-db kit, 100% audio now seems much louder while maintaining fidelity. Very nice.
I'm getting these errors in journald/dmesg:
When resuming from hibernation:
kernel: ucsi_acpi USBC000:00: ucsi_handle_connector_change: ACK failed (-110)
though it seems to be working fine (which I've had setup before from this.
I'm also getting these occasionally:
kernel: i2c_hid_acpi i2c-FRMW0005:00: i2c_hid_get_input: incomplete report (7/65535)
kernel: i2c_designware AMDI0010:00: i2c_dw_handle_tx_abort: lost arbitration
I don't know if it's affecting anything.
Maybe helpful:
- For
incomplete report
: https://askubuntu.com/questions/1365175/var-system-journal-logs-flooded-with-i2c-hid-i2c-hid-get-input-incomplete-repor (says that settingacpi=""
fixed, but I tried it and 1. it didn't fix it and 2. display brightness was stuck at 100%). - For
lost arbitration
: https://lore.kernel.org/lkml/1443085614-101362-1-git-send-email-mika.westerberg@linux.intel.com/
I received these notable updates today 2023-11-02:
amd-gpu-firmware noarch 20231030-1.fc38 updates 19 M
iwlwifi-dvm-firmware noarch 20231030-1.fc38 updates 1.8 M
iwlwifi-mvm-firmware noarch 20231030-1.fc38 updates 46 M
linux-firmware noarch 20231030-1.fc38
And I haven't seen those errors yet. Though, I did get two amdgpu crashes while playing a YouTube video and hooked up to my monitor. Once time it crashed out SwayWM, the other time the screen went black and came back. Similar issues happened early on with my previous Intel, so I expect this to be fixed sooner or later.
Amazing work, thank you!
I haven't done a full battery life test yet but playing a 1080p YouTube video has gone from about
3h 45m
to around5h 10m
using the freeworld drivers for more supported codecsI did some benchmarks to compare performance:
TLP
Single:
4919.94
Multi:
32348.29
HOLY SHIT
Power Profiles PowerSaver
Single:
2770.16
Multi:
15524.03
Power Profiles Balanced
Single:
4922.95
Multi:
38566.32
Power Profiles Performance
SIngle:
4927.50
Multi:
41922.37