2024-08-08 09:02:42 +08:00
|
|
|
{pkgs, ...}: {
|
2024-04-01 10:04:20 +08:00
|
|
|
# Our custom power state
|
|
|
|
environment.etc = {
|
2024-08-11 08:08:11 +08:00
|
|
|
"default/amdgpu-custom-states.card1" = {
|
2024-04-01 10:04:20 +08:00
|
|
|
text = ''
|
|
|
|
# For Navi (and Radeon7) we can only set highest SCLK & MCLK, "state 1":
|
|
|
|
OD_SCLK:
|
|
|
|
1: 1800MHz
|
|
|
|
OD_MCLK:
|
|
|
|
1: 875MHz
|
|
|
|
# More fine-grain control of clocks and voltages are done with VDDC curve:
|
|
|
|
OD_VDDC_CURVE:
|
2024-12-27 21:16:56 +08:00
|
|
|
0: 800MHz @ 700mV
|
2024-04-01 10:04:20 +08:00
|
|
|
1: 1450MHz @ 795mV
|
|
|
|
2: 1800MHz @ 950mV
|
|
|
|
# Force power limit (in micro watts):
|
|
|
|
FORCE_POWER_CAP: 200000000
|
|
|
|
FORCE_PERF_LEVEL: manual
|
|
|
|
'';
|
|
|
|
|
|
|
|
# The UNIX file mode bits
|
|
|
|
mode = "0440";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
# Install our overclocking script.
|
2024-08-08 09:02:42 +08:00
|
|
|
environment.systemPackages = with pkgs; [amdgpu-clocks];
|
2024-04-01 10:04:20 +08:00
|
|
|
}
|