Skip to content

Commit d1df94e

Browse files
authored
Add more information about DVFS (#1906)
* Add more information about DVFS Information added in this commit is from - Own experimentation - Forum post https://www.raspberrypi.org/forums/viewtopic.php?p=1804133#p1804133 * Typo * Style guide edit * Raspberry Pi 4 devices reference style * `cpufrequtils` usage style * Minor sentance structure * Specify default DVFS setting
1 parent 6a60c2b commit d1df94e

File tree

1 file changed

+15
-2
lines changed

1 file changed

+15
-2
lines changed

hardware/raspberrypi/frequency-management.md

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,27 @@ For Raspberry Pi 3 Model B+, the PCB technology has been changed to provide bett
88

99
The Raspberry Pi 4 Model B continues with the same PCB technology as the Raspberry Pi 3B+ to help dissipate excess heat. There is currently no soft limit defined.
1010

11-
### DVFS on the Raspberry Pi 4B
11+
### DVFS on the Raspberry Pi 4 (4B, 400 and CM4)
1212

13-
On Raspberry Pi 4 Model B, firmware from late November 2019 onwards implements Dynamic Voltage and Frequency Scaling. This technique (outlined on Wikipedia [here](https://en.wikipedia.org/wiki/Dynamic_voltage_scaling)) allows Raspberry Pi 4B to run at lower temperatures whilst still providing the same performance.
13+
Raspberry Pi 4 devices implement Dynamic Voltage and Frequency Scaling (DVFS). This technique (outlined on Wikipedia [here](https://en.wikipedia.org/wiki/Dynamic_voltage_scaling)) allows Raspberry Pi 4 devices to run at lower temperatures whilst still providing the same performance.
1414

1515
Various clocks (e.g. ARM, Core, V3D, ISP, H264, HEVC) inside the SoC are monitored by the firmware, and whenever they are not running at full speed, the voltage supplied to the particular part of the chip driven by the clock is reduced relative to the reduction from full speed. In effect, only enough voltage is supplied to keep the block running correctly at the specific speed at which it is running. This can result in significant reductions in power used by the SoC, and therefore in the overall heat being produced.
1616

17+
Due to possible system stability problems involved with running an undervoltage, especially when using undervoltaged fixed clock peripherals (eg. PCIe), two DVFS modes are available and can be configured in `/boot/config.txt` with the below properties. GUI desktop systems should use `dvfs=2`, headless systems may benefit from `dvfs=1` provided peripheral use is managed.
18+
19+
| property=value | Description |
20+
|----------------|------------------------------|
21+
| dvfs=1 | allow under-voltage |
22+
| dvfs=2 | no under-voltage (default) |
23+
1724
In addition, a more stepped CPU governor is also used to produce finer-grained control of ARM core frequencies, which means the DVFS is more effective. The steps are now 1500MHz, 1000MHz, 750MHz, and 600MHz. These steps can also help when the SoC is being throttled, and mean that throttling all the way back to 600MHz is much less likely, giving an overall increase in fully loaded performance.
1825

26+
The default CPU governor is `ondemand`, the governor can be manually changed with the `cpufreq-set` command (from the `cpufrequtils` package) to reduce idle power consumption:
27+
```
28+
sudo apt install cpufrequtils
29+
sudo cpufreq-set -g powersave
30+
```
31+
1932
### Heatsinks
2033

2134
Whilst heatsinks are not necessary to prevent overheating damage to the SoC (the thermal throttling mechanism handles that), a heatsink or small fan will help if you wish to reduce the amount of thermal throttling that takes place. Depending on the exact circumstances, mounting the Pi vertically can also help with heat dissipation, as doing so can improve air flow.

0 commit comments

Comments
 (0)