forked from thesofproject/sof
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
f93f7d4
commit f254c7c
Showing
7 changed files
with
70 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
cmake_minimum_required(VERSION 3.20.0) | ||
|
||
project(virtualmemoryheaps) | ||
|
||
message(PROJECT_SOURCE_DIR="${PROJECT_SOURCE_DIR}") | ||
|
||
include_directories("${PROJECT_SOURCE_DIR}/../../../zephyr/include") | ||
message(!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!SANITY1545) | ||
include_directories("${PROJECT_SOURCE_DIR}/../../../zephyr/include/sof/lib") | ||
include_directories("${PROJECT_SOURCE_DIR}/../../../src/include") | ||
include_directories("${PROJECT_SOURCE_DIR}/../../../posix/include") | ||
|
||
|
||
find_package(Zephyr COMPONENTS unittest REQUIRED HINTS $ENV{ZEPHYR_BASE}) | ||
|
||
target_compile_definitions(testbinary PRIVATE -D CONFIG_ZTEST=1) | ||
|
||
target_sources(testbinary PRIVATE ../../../zephyr/lib/regions_mm.c main.c) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
//#include "sof/lib/regions_mm.h" | ||
#include <zephyr/fff.h> | ||
#include <zephyr/ztest.h> | ||
#include "regions_mm.h" | ||
#include "vmh_test_helper.h" | ||
|
||
ZTEST(vmh_heaps, test_basic_memory_heap) | ||
{ | ||
struct vmh_heap* test_heap = vmh_init_heap(NULL,0, 0, true); | ||
|
||
zexpect_true(test_heap); | ||
} | ||
|
||
ZTEST_SUITE(vmh_heap, NULL, NULL, NULL, NULL, NULL); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
CONFIG_ZTEST=y |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
common: | ||
tags: vmh | ||
|
||
tests: | ||
vmh_heap: | ||
platform_allow: | ||
intel_adsp_cavs25 intel_adsp_ace15_mtpm intel_adsp_ace20_lnl | ||
nxp_adsp_imx8 nxp_adsp_imx8x nxp_adsp_imx8m | ||
tags: vmh | ||
integration_platforms: | ||
- intel_adsp_cavs25 # TGL | ||
- intel_adsp_ace15_mtpm # MTL | ||
- intel_adsp_ace20_lnl | ||
- nxp_adsp_imx8 | ||
- nxp_adsp_imx8x | ||
- nxp_adsp_imx8m | ||
- nxp_adsp_imx8ulp |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
#include <stdlib.h> | ||
|
||
void* rzalloc(int zone, int unused , int caps, size_t size) | ||
{ | ||
return malloc(size); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,8 +5,6 @@ | |
* Author: Jakub Dabek <[email protected]> | ||
*/ | ||
|
||
#include <zephyr/init.h> | ||
|
||
#include <sof/lib/regions_mm.h> | ||
|
||
/* list of vmh_heap objects created */ | ||
|