GPU memory in megabytes. This sets the memory split between the CPU and GPU; the CPU gets the remaining memory. Minimum value is
16; maximum value is
944, depending on whether you are using a 256M, 512MB, or 1024MB Pi. The default value is
gpu_mem to low values may automatically disable certain firmware features, as there are some things the GPU cannot do if it has access to too little memory. So if a feature you are trying to use isn't working, try setting a larger GPU memory split.
gpu_mem_1024 allows you to swap the same SD card between 256MB, 512MB, and 1024MB Pis without having to edit
config.txt each time:
gpu_mem_256 command sets the GPU memory in megabytes for the 256MB Raspberry Pi (it is ignored if memory size is not 256MB). This overrides
gpu_mem. The maximum value is
192 and the default is not set.
gpu_mem_512 command sets the GPU memory in megabytes for the 512MB Raspberry Pi (it is ignored if memory size is not 512MB). This overrides
gpu_mem. The maximum value is
448 and the default is not set.
gpu_mem_1024 command sets the GPU memory in megabytes for the 1024MB Raspberry Pi 2 (it is ignored if memory size is not 1024MB). This overrides
gpu_mem. The maximum value is
944 and the default is not set.
Setting this to
1 disables the CPU's access to the GPU's L2 cache, and requires a corresponding L2 disabled kernel. Default value on BCM2835 is
0. On BCM2836 and BCM2837 the ARMs have their own L2 cache and therefore the default is
1. The standard Pi kernel.img and kernel7.img builds reflect this difference in cache setting.
Licence key and codec options
Hardware decoding of additional codecs can be enabled by purchasing a licence that is locked to the CPU serial number of your Raspberry Pi.
decode_MPG2 is a licence key to allow hardware MPEG-2 decoding, e.g.
decode_WVC1 is a licence key to allow hardware VC-1 decoding, e.g.
If you have multiple Raspberry Pis and you've bought a codec licence for each of them, you can list up to eight licence keys in a single
config.txt, for example
decode_MPG2=0x12345678,0xabcdabcd,0x87654321. This enables you to swap the same SD card between the different Pis without having to edit
config.txt each time.
gpio directive allows GPIO pins to be set to specific modes and values at boot time in a way that would previously have needed a custom
dt-blob.bin file. Each line applies the same settings (or at least makes the same changes) to a set of pins, either a single pin (
3), a range of pins (
3-4), or a comma-separated list of either (
3-4,6,8). The pin set is followed by an
= and one or more comma-separated attributes from this list:
dh- Driving high (for outputs)
dl- Driving low (for outputs)
pu- Pull up
pd- Pull down
pn/np- No pull
gpio settings are applied in order, so those appearing later override those appearing earlier.
# Select Alt2 for GPIO pins 0 to 27 (for DPI24) gpio=0-27=a2 # Set GPIO12 to be an output set to 1 gpio=12=op,dh # Change the pull on (input) pins 18 and 20 gpio=18,20=pu # Make pins 17 to 21 inputs gpio=17-21=ip
gpio directive respects the "[...]" section headers in
config.txt, so it is possible to use different settings based on the model, serial number, and EDID.
GPIO changes made through this mechanism do not have any direct effect on the kernel — they don't cause GPIO pins to be exported to the sysfs interface, and they can be overridden by pinctrl entries in the Device Tree as well as utilities like
Note also that there is a delay of a few seconds between power being applied and the changes taking effect — longer if booting over the network or from a USB mass storage device.
|arm_freq||Frequency of the ARM CPU in MHz. The default value is |
|core_freq||Frequency of the GPU processor core in MHz. It has an impact on CPU performance because it drives the L2 cache and memory bus. The default value is |
|h264_freq||Frequency of the hardware video block in MHz. Individual override of the |
|isp_freq||Frequency of the image sensor pipeline block in MHz. Individual override of the |
|v3d_freq||Frequency of the 3D block in MHz. Individual override of the |
|sdram_freq||Frequency of the SDRAM in MHz. The default value is |
|over_voltage||CPU/GPU core voltage adjustment. [-16,8] equates to [0.8V,1.4V] with 0.025V steps. In other words, specifying -16 will give 0.8V as the GPU/core voltage, and specifying 8 will give 1.4V. For defaults see table below. Values above 6 are only allowed when |
|over_voltage_sdram_c||SDRAM controller voltage adjustment. [-16,8] equates to [0.8V,1.4V] with 0.025V steps. The default value is |
|over_voltage_sdram_i||SDRAM I/O voltage adjustment. [-16,8] equates to [0.8V,1.4V] with 0.025V steps. The default value is |
|over_voltage_sdram_p||SDRAM phy voltage adjustment. [-16,8] equates to [0.8V,1.4V] with 0.025V steps. The default value is |
|force_turbo||Forces turbo mode frequencies even when the ARM cores are not busy. Enabling this may set the warranty bit if |
|initial_turbo||Enables turbo mode from boot for the given value in seconds, or until cpufreq sets a frequency. For more information see here. The default value is |
|arm_freq_min||Minimum value of arm_freq used for dynamic frequency clocking. The default value is |
|core_freq_min||Minimum value of |
|gpu_freq_min||Minimum value of |
|h264_freq_min||Minimum value of |
|isp_freq_min||Minimum value of |
|v3d_freq_min||Minimum value of |
|sdram_freq_min||Minimum value of |
|over_voltage_min||Minimum value of |
|temp_limit||Overheat protection. This sets the clocks and voltages to default when the SoC reaches this value in Celsius. The default value is 85. Values over 85 are clamped to 85.|
|temp_soft_limit||3B+ only. CPU speed throttle control. This sets the temperature at which the CPU clock speed throttling system activates. At this temperature, the clock speed is reduced from 1400Mhz to 1200Mhz. Defaults to |
This table describes the overvoltage settings for the various Pi models. The firmware uses Adaptive Voltage Scaling (AVS) to determine the optimum voltage to set. Note that for each integer rise in over_voltage, the voltage will be 25mV higher.
By default (f
orce_turbo=0) the "On Demand" CPU frequency driver will raise clocks to their maximum frequencies when the ARM cores are busy and will lower them to the minimum frequencies when the ARM cores are idle.
force_turbo=1 overrides this behaviour and forces maximum frequencies even when the ARM cores are not busy.
Sets a bit in the OTP memory (one time programmable) that prevents the device from being overvoltaged. This is intended to lock the device down so the warranty bit cannot be set either inadvertently or maliciously by using an invalid overvoltage.
On the Pi 2/Pi 3, setting this flag will disable the GPU from moving into turbo mode, which it can do in particular load cases.