diff options
author | Ahmad Fatoum <a.fatoum@pengutronix.de> | 2020-11-24 11:24:30 +0100 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2020-11-30 09:41:20 +0100 |
commit | f382be77f8c02cbaa94dc2664c3ab0d46775cab9 (patch) | |
tree | 76127cdc37396acf6801b43e957b6093a6dd1dba /common/Kconfig | |
parent | 1ac440d8149184f3de289e8596bfa516b8a65d66 (diff) | |
download | barebox-f382be77f8c02cbaa94dc2664c3ab0d46775cab9.tar.gz barebox-f382be77f8c02cbaa94dc2664c3ab0d46775cab9.tar.xz |
boot: introduce option to pass barebox-enabled watchdog to systemd
Like Linux, barebox supports co-existence of multiple watchdog
devices. On boot, barebox enables only the default watchdog, which
is defined as the watchdog with highest non-zero priority.
The kernel handles all watchdogs the same and defers to userspace,
which watchdogs to service. It can be useful to have barebox tell
the system, which watchdog it activated, so it can service the same.
Having this feature behind a global variable adds 354 bytes to a
LZO compressed THUMB2 barebox. Users can opt out by toggling the
Kconfig option, which defaults to off.
Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'common/Kconfig')
-rw-r--r-- | common/Kconfig | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/common/Kconfig b/common/Kconfig index ffdce2f96c..d1baee60e6 100644 --- a/common/Kconfig +++ b/common/Kconfig @@ -1007,6 +1007,16 @@ config MACHINE_ID Note: if no hashable information is available no machine id will be passed to the kernel. +config SYSTEMD_OF_WATCHDOG + bool "inform devicetree-enabled kernel of used watchdog" + depends on WATCHDOG && OFTREE && FLEXIBLE_BOOTARGS + help + Sets the linux.bootargs.dyn.watchdog global variable with a value of + systemd.watchdog-device=/dev/WDOG if barebox succeeded in enabling + the watchdog WDOG prior to boot. WDOG is the alias of the watchdog + in the kernel device tree. If the kernel is booted without a device + tree or with one that lacks aliases, nothing is added. + menu "OP-TEE loading" config OPTEE_SIZE |