From d37d55b5bddb3391d38c1ac2e9af05490f25ecd2 Mon Sep 17 00:00:00 2001 From: Andreas Moltumyr Date: Fri, 4 Oct 2024 16:12:28 +0200 Subject: [PATCH] lib: nrf_modem_lib: set data cache alignment to 32 bytes The nRF9230 application core has data cache with a cache line width of 32 bytes. Set the dcache alignment of ICMsg pbuf to 32 bytes to align. Signed-off-by: Andreas Moltumyr (cherry picked from commit 6a08601d3a49a52f310a271eac148edb5ac81a7b) --- lib/nrf_modem_lib/nrf_modem_os_rpc.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/nrf_modem_lib/nrf_modem_os_rpc.c b/lib/nrf_modem_lib/nrf_modem_os_rpc.c index e6a1bb1740d2..033299e4f9e7 100644 --- a/lib/nrf_modem_lib/nrf_modem_os_rpc.c +++ b/lib/nrf_modem_lib/nrf_modem_os_rpc.c @@ -18,7 +18,9 @@ #include #include -#define DCACHE_LINE_SIZE 0 +#define DCACHE_LINE_SIZE (CONFIG_DCACHE_LINE_SIZE) +BUILD_ASSERT(DCACHE_LINE_SIZE == 32 + "Unexpected data cache line size " STRINGIFY(DCACHE_LINE_SIZE) ", expected 32"); /** Structure to hold pbuf configuration and data. */ struct nrf_modem_pbuf {