linux/drivers/interconnect
Kees Cook 6f0c60f146 interconnect: Annotate struct icc_path with __counted_by
Prepare for the coming implementation by GCC and Clang of the __counted_by
attribute. Flexible array members annotated with __counted_by can have
their accesses bounds-checked at run-time checking via CONFIG_UBSAN_BOUNDS
(for array indexing) and CONFIG_FORTIFY_SOURCE (for strcpy/memcpy-family
functions).

As found with Coccinelle[1], add __counted_by for struct icc_path.

[1] https://github.com/kees/kernel-tools/blob/trunk/coccinelle/examples/counted_by.cocci

Cc: Georgi Djakov <djakov@kernel.org>
Cc: linux-pm@vger.kernel.org
Signed-off-by: Kees Cook <keescook@chromium.org>
Reviewed-by: Gustavo A. R. Silva <gustavoars@kernel.org>
Link: https://lore.kernel.org/r/20230817204144.never.605-kees@kernel.org
Signed-off-by: Georgi Djakov <djakov@kernel.org>
2023-08-22 01:11:22 +03:00
..
imx interconnect: Explicitly include correct DT includes 2023-07-16 18:27:27 +03:00
qcom Merge branch 'icc-qcm2290' into icc-next 2023-08-22 01:02:15 +03:00
samsung interconnect: exynos: drop redundant link destroy 2023-03-13 21:13:48 +02:00
bulk.c interconnect: add device managed bulk API 2022-07-04 16:14:29 +03:00
core.c interconnect: drop unused icc_get() interface 2023-05-30 22:04:46 +03:00
icc-clk.c interconnect: icc-clk: Annotate struct icc_clk_provider with __counted_by 2023-08-22 01:11:09 +03:00
internal.h interconnect: Annotate struct icc_path with __counted_by 2023-08-22 01:11:22 +03:00
Kconfig interconnect: add clk-based icc provider support 2023-05-18 19:02:23 +03:00
Makefile interconnect: add clk-based icc provider support 2023-05-18 19:02:23 +03:00
trace.h interconnect: Add basic tracepoints 2019-12-16 09:25:23 +02:00