param: add dev_add_param_tristate(_ro) helpers
This is can be considered an extension to the dev_add_param_bool
interfaces with a third value that's "unknown".
This can be used for cases, where barebox can flip a bit somewhere,
but it has no way of knowing what the initial state of the bit was,
e.g. turn on/off the watchdog, but no watchdog status.
Turn on/off a co-processor, but no co-processor online status.
And so on. Not providing a way to customize the "unknown" string
is a deliberate choice, so future device parameters follow the same
naming scheme.

Signed-off-by: Ahmad Fatoum <ahmad@a3f.at>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
1 parent 1d86578 commit 713a601bde07bb498f99bc6288d0c10ddcbe2e0a
@Ahmad Fatoum Ahmad Fatoum authored on 21 Nov 2019
Sascha Hauer committed on 5 Dec 2019
Showing 2 changed files
View
include/param.h
View
lib/parameter.c