zephyr/tests/lib
Martí Bolívar 869ae2b5ac devicetree.h: add DT_NODE_CHILD_IDX
It can be useful to know what a node's index is in its parent's list
of children. This information is now available to C via
gen_defines.py, but no user-facing macros are available to access it.

Add a macro which exposes this information to users via devicetree.h.

Some APIs want to build on devicetree.h by creating some derived
structure for each of a node's children. It can therefore be
convenient to use each child's index in the list of children as an
identifier for the child.

Some concrete and common examples are "gpio-keys" and "gpio-leds",
which allow you to define arbitrary numbers of keys and LEDs as child
nodes of nodes with those compatibles. Derived APIs can use a key or
LED node's index in its list of parents as a way to identify which of
several structures is relevant to a particular controlled key or LED.

These are just examples, though -- the feature added here makes no
assumptions about where it's being used.

Signed-off-by: Martí Bolívar <marti.bolivar@nordicsemi.no>
2022-03-24 10:48:40 +01:00
..
c_lib kconfig: Rename the TEST_EXTRA stack size option to align with the rest 2022-02-22 08:23:05 -05:00
cbprintf_fp cmake: increase minimal required version to 3.20.0 2021-08-20 09:47:34 +02:00
cbprintf_package everywhere: fix typos 2022-03-18 13:24:08 -04:00
cmsis_dsp tests: cmsis_dsp: matrix: Disable FP16 tests for POSIX arch 2022-03-16 07:32:19 -04:00
cmsis_nn tests: lib: cmsis: add CMSIS-NN integration tests 2022-03-22 12:56:02 +01:00
devicetree devicetree.h: add DT_NODE_CHILD_IDX 2022-03-24 10:48:40 +01:00
fdtable kconfig: Rename the TEST_EXTRA stack size option to align with the rest 2022-02-22 08:23:05 -05:00
gui/lvgl lvgl: change the prefix of Zephyr-specific LVGL config options 2022-02-24 11:51:33 +01:00
heap tests: lib/heap: add test for heap listeners 2022-01-10 10:28:04 -05:00
heap_align everywhere: fix typos 2022-03-18 13:24:08 -04:00
icmsg tests: lib: Add ipc_icmsg_buf unit tests 2022-03-22 12:36:39 +01:00
json kconfig: Rename the ZTEST stack size option to align with the rest 2022-02-22 08:23:05 -05:00
mem_alloc cmake: increase minimal required version to 3.20.0 2021-08-20 09:47:34 +02:00
mem_blocks tests: lib/mem_blocks: add test for heap listeners 2022-01-11 16:10:53 -05:00
mpsc_pbuf everywhere: fix typos 2022-03-18 13:24:08 -04:00
newlib kconfig: Rename the TEST_EXTRA stack size option to align with the rest 2022-02-22 08:23:05 -05:00
notify cmake: increase minimal required version to 3.20.0 2021-08-20 09:47:34 +02:00
onoff everywhere: fix typos 2022-03-18 13:24:08 -04:00
p4workq everywhere: fix typos 2022-03-18 13:24:08 -04:00
ringbuffer everywhere: fix typos 2022-03-18 13:24:08 -04:00
smf everywhere: fix typos 2022-03-18 13:24:08 -04:00
sprintf tests: remove @return doc for void functions 2022-01-12 16:02:16 -05:00
sys_util sys_util: wait_for, spin on an expression 2022-03-11 09:46:47 -05:00
time tests: m2gl025_miv: exclude slow platform from some tests 2021-11-29 19:39:38 -05:00