Skip to content

Commit aaa3bcc

Browse files
committed
zephyr: sof/lib/mm_heap.h added Zephyr version
Definitions of mm_heap.h interface are not needed in Zephyr builds. To avoid pulling in XTOS definitions when building with CONFIG_SOF_ZEPHYR_STRICT_HEADERS=n, add a no-op version for Zephyr. Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
1 parent 707c0c5 commit aaa3bcc

File tree

2 files changed

+15
-0
lines changed

2 files changed

+15
-0
lines changed

xtos/include/sof/lib/mm_heap.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@
99
#ifndef __SOF_LIB_MM_HEAP_H__
1010
#define __SOF_LIB_MM_HEAP_H__
1111

12+
#ifdef __ZEPHYR__
13+
#error "Please use zephyr/include/sof/lib/mm_heap.h instead"
14+
#endif
15+
1216
#include <sof/common.h>
1317
#include <rtos/alloc.h>
1418
#include <rtos/cache.h>

zephyr/include/sof/lib/mm_heap.h

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
/* SPDX-License-Identifier: BSD-3-Clause
2+
*
3+
* Copyright(c) 2024 Intel Corporation.
4+
*/
5+
6+
#ifndef __SOF_LIB_MM_HEAP_H__
7+
#define __SOF_LIB_MM_HEAP_H__
8+
9+
/* no-op on Zephyr */
10+
11+
#endif /* __SOF_LIB_MM_HEAP_H__ */

0 commit comments

Comments
 (0)