Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions documentation/asciidoc/computers/config_txt/conditional.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -171,6 +171,26 @@ sudo vcmailbox 0x0003008c 8 8 1 0
----
The value of the `boot_arg1` variable when the OS was started can be read via xref:configuration.adoc#part4[device-tree] at `/proc/device-tree/chosen/bootloader/arg1`

==== `bootvar0`
Raspberry Pi 5 and newer devices only.

The `bootvar0` variable is a 32-bit user defined value which is set through rpi-eeprom-config, and then can be used as a conditional variable in config.txt.

For example, setting `bootvar0` to 42 via `rpi-eeprom-config`:
[source,ini]
----
BOOTVAR0=42
----

and then using it conditionally in `config.txt`:
[source,ini]
----
[bootvar0=42]
arm_freq=1000
----

This allows a common image (i.e. with the same config.txt file) to support different configurations based on the persistent rpi-eeprom-config settings.

==== `boot_count`
Raspberry Pi 5 and newer devices only.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -568,6 +568,13 @@ During the "partition walk" `autoboot.txt` files are not processed to avoid cycl

Default: `0`

[[BOOTVAR0]]
==== `BOOTVAR0`

Allows setting the conditional variable bootvar0 used by `config.txt`. See xref:config_txt.adoc#bootvar0[bootvar0].

Default: `0`

[[PSU_MAX_CURRENT]]
==== `PSU_MAX_CURRENT`

Expand Down