Skip to content

Commit bb6972d

Browse files
committed
audio: eap: Add EAP library stub for testing
This is used for CI testing and compiling. Signed-off-by: Daniel Baluta <daniel.baluta@nxp.com>
1 parent 2e876b6 commit bb6972d

File tree

3 files changed

+48
-2
lines changed

3 files changed

+48
-2
lines changed

src/audio/nxp/CMakeLists.txt

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
if(CONFIG_COMP_NXP_EAP)
44
zephyr_library_sources(eap.c)
5-
zephyr_library_import(EAPLibrary
6-
${sof_top_dir}/eap_sdk/EAP_Library/libEAP16_3_0_13_FP1_RT600.a)
5+
if(CONFIG_COMP_NXP_EAP_STUB)
6+
zephyr_library_sources(eap_stub.c)
7+
else()
8+
zephyr_library_import(EAPLibrary
9+
${sof_top_dir}/eap_sdk/EAP_Library/libEAP16_3_0_13_FP1_RT600.a)
10+
endif()
711
endif()

src/audio/nxp/Kconfig

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,10 @@ config COMP_NXP_EAP
77
Select for NXP Essential Audio Processing Component.
88
The EAP is a bundle of audio processing blocks for enhancing the tonal
99
and spatial perception of sound in audio applications.
10+
11+
config COMP_NXP_EAP_STUB
12+
tristate "NXP EAP Component stub"
13+
default n
14+
depends on COMP_NXP_EAP
15+
help
16+
Select for NXP EAP stub support.

src/audio/nxp/eap_stub.c

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
// SPDX-License-Identifier: BSD-3-Clause
2+
//
3+
// Copyright 2025 NXP
4+
5+
#include <sof/audio/nxp/eap/EAP_Includes/EAP16.h>
6+
7+
LVM_ReturnStatus_en LVM_GetVersionInfo(LVM_VersionInfo_st *pVersion)
8+
{
9+
return LVM_SUCCESS;
10+
}
11+
12+
LVM_ReturnStatus_en LVM_GetInstanceHandle(LVM_Handle_t *phInstance,
13+
LVM_MemTab_t *pMemoryTable,
14+
LVM_InstParams_t *pInstParams)
15+
{
16+
return LVM_SUCCESS;
17+
};
18+
19+
LVM_ReturnStatus_en LVM_GetMemoryTable(LVM_Handle_t hInstance, LVM_MemTab_t *pMemoryTable,
20+
LVM_InstParams_t *pInstParams)
21+
{
22+
return LVM_SUCCESS;
23+
}
24+
25+
LVM_ReturnStatus_en LVM_Process(LVM_Handle_t hInstance, const LVM_INT16 *pInData,
26+
LVM_INT16 **pOutData, LVM_UINT16 NumSamples,
27+
LVM_UINT32 AudioTime)
28+
{
29+
return LVM_SUCCESS;
30+
}
31+
32+
LVM_ReturnStatus_en LVM_SetControlParameters(LVM_Handle_t hInstance, LVM_ControlParams_t *pParams)
33+
{
34+
return LVM_SUCCESS;
35+
}

0 commit comments

Comments
 (0)