Skip to content

Commit

Permalink
doc: dts: Linkify Kconfig syms and explain a Kconfig reference gotcha
Browse files Browse the repository at this point in the history
Turn the CONFIG_* identifiers in the /chosen table into links to the
Kconfig reference.

Also explain why devicetree information doesn't show up in the Kconfig
reference.

Signed-off-by: Ulf Magnusson <[email protected]>
ulfalizer authored and carlescufi committed Jan 9, 2020
1 parent 5b497cf commit 0ce04d6
Showing 1 changed file with 23 additions and 8 deletions.
31 changes: 23 additions & 8 deletions doc/guides/dts/index.rst
Original file line number Diff line number Diff line change
@@ -478,6 +478,21 @@ identifiers that start with ``CONFIG_*`` are generated from Kconfig symbols
that reference devicetree data via the :ref:`Kconfig preprocessor
<kconfig-functions>`.

.. note::

Since the particular devicetree isn't known while generating Kconfig
documentation, the Kconfig symbol reference pages linked below do not
include information derived from devicetree. Instead, you might see e.g. an
empty default:

.. code-block:: none
default "" if HAS_DTS
To see how the preprocessor is used for a symbol, look it up directly in the
:file:`Kconfig` file where it is defined instead. The reference page for the
symbol gives the definition location.

.. list-table::
:header-rows: 1

@@ -489,27 +504,27 @@ that reference devicetree data via the :ref:`Kconfig preprocessor
* - ``zephyr,code-partition``
- ``DT_CODE_PARTITION_OFFSET``/``DT_CODE_PARTITION_SIZE``
* - ``zephyr,sram``
- ``CONFIG_SRAM_BASE_ADDRESS``/``CONFIG_SRAM_SIZE``
- :option:`CONFIG_SRAM_BASE_ADDRESS`/:option:`CONFIG_SRAM_SIZE`
* - ``zephyr,ccm``
- ``DT_CCM_BASE_ADDRESS``/``DT_CCM_SIZE``
* - ``zephyr,dtcm``
- ``DT_DTCM_BASE_ADDRESS``/``DT_DTCM_SIZE``
* - ``zephyr,ipc_shm``
- ``DT_IPC_SHM_BASE_ADDRESS``/``DT_IPC_SHM_SIZE``
* - ``zephyr,console``
- ``CONFIG_UART_CONSOLE_ON_DEV_NAME``
- :option:`CONFIG_UART_CONSOLE_ON_DEV_NAME`
* - ``zephyr,shell-uart``
- ``CONFIG_UART_SHELL_ON_DEV_NAME``
- :option:`CONFIG_UART_SHELL_ON_DEV_NAME`
* - ``zephyr,bt-uart``
- ``CONFIG_BT_UART_ON_DEV_NAME``
- :option:`CONFIG_BT_UART_ON_DEV_NAME`
* - ``zephyr,uart-pipe``
- ``CONFIG_UART_PIPE_ON_DEV_NAME``
- :option:`CONFIG_UART_PIPE_ON_DEV_NAME`
* - ``zephyr,bt-mon-uart``
- ``CONFIG_BT_MONITOR_ON_DEV_NAME``
- :option:`CONFIG_BT_MONITOR_ON_DEV_NAME`
* - ``zephyr,bt-c2h-uart``
- ``CONFIG_BT_CTLR_TO_HOST_UART_DEV_NAME``
- :option:`CONFIG_BT_CTLR_TO_HOST_UART_DEV_NAME`
* - ``zephyr,uart-mcumgr``
- ``CONFIG_UART_MCUMGR_ON_DEV_NAME``
- :option:`CONFIG_UART_MCUMGR_ON_DEV_NAME`


Adding support for devicetree in drivers

0 comments on commit 0ce04d6

Please sign in to comment.