diff --git a/include/zephyr/toolchain/common.h b/include/zephyr/toolchain/common.h index cf2dce5676..3dd1f4ee90 100644 --- a/include/zephyr/toolchain/common.h +++ b/include/zephyr/toolchain/common.h @@ -197,7 +197,7 @@ */ /** - * @brief Defines a new iterable section. + * @brief Defines a new element for an iterable section. * * @details * Convenience helper combining __in_section() and Z_DECL_ALIGN(). @@ -206,13 +206,16 @@ * * In the linker script, create output sections for these using * ITERABLE_SECTION_ROM() or ITERABLE_SECTION_RAM(). + * + * @note In order to store the element in ROM, a const specifier has to + * be added to the declaration: const STRUCT_SECTION_ITERABLE(...); */ #define STRUCT_SECTION_ITERABLE(struct_type, name) \ Z_DECL_ALIGN(struct struct_type) name \ __in_section(_##struct_type, static, name) __used __noasan /** - * @brief Defines an alternate data type iterable section. + * @brief Defines a new element of alternate data type for an iterable section. * * @details * Special variant of STRUCT_SECTION_ITERABLE(), for placing alternate