kconfig: Convert device tree chosen properties to new kconfigfunctions
Convert how we get the various chosen properties like "zephyr,console" to use the new kconfig functions like dt_chosen_to_label. Because of how kconfig parses things we define a set of variables of the form DT_CHOSEN_Z_<PROP> since comma's are parsed as field seperators in macros. This conversion allows us to remove code in gen_defines.py for the following chosen properties: zephyr,console zephyr,shell-uart zephyr,bt-uart zephyr,uart-pipe zephyr,bt-mon-uart zephyr,uart-mcumgr zephyr,bt-c2h-uart Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
This commit is contained in:
parent
5735397b9b
commit
8ce0cf0126
11 changed files with 59 additions and 47 deletions
|
@ -30,9 +30,12 @@ config SHELL_PROMPT_UART
|
|||
help
|
||||
Displayed prompt name for UART backend.
|
||||
|
||||
# Workaround for not being able to have commas in macro arguments
|
||||
DT_CHOSEN_Z_SHELL_UART := zephyr,shell-uart
|
||||
|
||||
config UART_SHELL_ON_DEV_NAME
|
||||
string "Device Name of UART Device for SHELL_BACKEND_SERIAL"
|
||||
default "$(dt_str_val,DT_UART_SHELL_ON_DEV_NAME)" if HAS_DTS
|
||||
default "$(dt_chosen_label,$(UART_SHELL_ON_DEV_NAME))" if HAS_DTS
|
||||
default "UART_0"
|
||||
help
|
||||
This option specifies the name of UART device to be used for the
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue