zephyr/tests/lib
Henri Xavier 1a276d0ac6 ring_buffer: Introduce RING_BUF_ITEM_SIZEOF
Currently, to compute the 'item' size in a ring buffer, we have
`SIZE32_OF`.

Several issues with this:
- `SIZE32_OF` only works on variables, not types, due to an extra
 parenthesis pair. Indeed, `sizeof((int))` is not valid C, whereas
 `sizeof((my_var))` is.
- `SIZE32_OF` is not a proper public API
- `SIZE32_OF` rounds down if the argument size is not a multiple
 of 4 bytes.

Thus, we introduce a proper `RING_BUF_ITEM_SIZEOF`, fixing the
aforementioned issues.

Signed-off-by: Henri Xavier <datacomos@huawei.com>
2022-09-20 09:08:14 +00:00
..
c_lib ztest: remove the obsolete NULL appended to zassert macros 2022-09-09 07:05:38 -04:00
cbprintf_fp tests: Add picolibc tests 2022-06-22 13:15:55 +02:00
cbprintf_package lib: os: cbprintf: Mechanism for detecting %p in static package 2022-09-19 10:14:23 +00:00
cmsis_dsp tests: lib: move the cmsis_dsp transform test to new ztest API 2022-09-14 07:22:09 -04:00
cmsis_nn includes: prefer <zephyr/kernel.h> over <zephyr/zephyr.h> 2022-09-05 16:31:47 +02:00
devicetree tests: devicetree: add bits to test multi-bus nodes 2022-09-09 17:42:33 -04:00
fdtable ztest: remove the obsolete NULL appended to zassert macros 2022-09-09 07:05:38 -04:00
gui/lvgl tests: lib: gui: lvgl: Switch to FIXED_PARTITION_ macros 2022-09-06 09:56:37 +02:00
heap includes: prefer <zephyr/kernel.h> over <zephyr/zephyr.h> 2022-09-05 16:31:47 +02:00
heap_align includes: prefer <zephyr/kernel.h> over <zephyr/zephyr.h> 2022-09-05 16:31:47 +02:00
json test: fix more legacy #include paths 2022-08-02 16:41:41 +01:00
mem_alloc includes: prefer <zephyr/kernel.h> over <zephyr/zephyr.h> 2022-09-05 16:31:47 +02:00
mem_blocks includes: prefer <zephyr/kernel.h> over <zephyr/zephyr.h> 2022-09-05 16:31:47 +02:00
mem_blocks_stats includes: prefer <zephyr/kernel.h> over <zephyr/zephyr.h> 2022-09-05 16:31:47 +02:00
mpsc_pbuf ztest: improve some tests 2022-09-09 07:05:38 -04:00
newlib includes: prefer <zephyr/kernel.h> over <zephyr/zephyr.h> 2022-09-05 16:31:47 +02:00
notify test: fix more legacy #include paths 2022-08-02 16:41:41 +01:00
onoff test: fix more legacy #include paths 2022-08-02 16:41:41 +01:00
p4workq includes: prefer <zephyr/kernel.h> over <zephyr/zephyr.h> 2022-09-05 16:31:47 +02:00
ringbuffer ring_buffer: Introduce RING_BUF_ITEM_SIZEOF 2022-09-20 09:08:14 +00:00
smf includes: prefer <zephyr/kernel.h> over <zephyr/zephyr.h> 2022-09-05 16:31:47 +02:00
sprintf tests: lib: sprintf: migrating lib tests to new ZTEST API 2022-08-19 20:45:19 +00:00
spsc_pbuf ztest: remove the obsolete NULL appended to zassert macros 2022-09-09 07:05:38 -04:00
sys_util tests: lib: sysutil: migrating lib tests to new ZTEST API 2022-08-19 20:45:19 +00:00
time test: fix more legacy #include paths 2022-08-02 16:41:41 +01:00
uoscore includes: prefer <zephyr/kernel.h> over <zephyr/zephyr.h> 2022-09-05 16:31:47 +02:00