From 7b557d5d1f632884f648ac04c766f9a0e2716f3e Mon Sep 17 00:00:00 2001 From: Adrian Bonislawski Date: Tue, 7 Apr 2026 08:51:06 +0200 Subject: [PATCH] zephyr: alloc: add 32K virtual heap bucket The original virtual heap layout used the full 0x100000 region and forced 24 KB DMA buffers to consume 64 KB blocks. Increase the virtual heap region size to 0x140000 and add a 32 KB block pool so medium-sized DMA buffers no longer deplete the 64 KB entries. Signed-off-by: Adrian Bonislawski --- zephyr/Kconfig | 2 +- zephyr/lib/alloc.c | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/zephyr/Kconfig b/zephyr/Kconfig index 1d02868fd5ca..cb925fc8e4db 100644 --- a/zephyr/Kconfig +++ b/zephyr/Kconfig @@ -93,7 +93,7 @@ config SOF_ZEPHYR_VIRTUAL_HEAP_SIZE config SOF_ZEPHYR_VIRTUAL_HEAP_REGION_SIZE hex "Size in bytes of virtual memory region for virtual heap shared for all cores" depends on MM_DRV_INTEL_ADSP_MTL_TLB - default 0x100000 + default 0x140000 help This config defines size of virtual heap region shared between all cores diff --git a/zephyr/lib/alloc.c b/zephyr/lib/alloc.c index f95f66fbdb7f..f55460418a1b 100644 --- a/zephyr/lib/alloc.c +++ b/zephyr/lib/alloc.c @@ -344,6 +344,7 @@ static const struct vmh_heap_config static_hp_buffers = { { 2048, 8}, { 4096, 11}, { 8192, 10}, + { 32768, 8}, { 65536, 3}, { 131072, 1}, { 524288, 1} /* buffer for kpb */