From 452211586e62770cb59e754d1ceaa3d034ef0f6f Mon Sep 17 00:00:00 2001 From: ligd Date: Wed, 31 May 2023 18:29:39 +0800 Subject: [PATCH] xtensa: fix compile miss file comiple xtensa_mpu.c Signed-off-by: ligd --- arch/xtensa/src/common/Make.defs | 11 ++++++----- arch/xtensa/src/common/xtensa_mpu.c | 4 ++++ 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/arch/xtensa/src/common/Make.defs b/arch/xtensa/src/common/Make.defs index 2ea5b56ff81..53e0c183f64 100644 --- a/arch/xtensa/src/common/Make.defs +++ b/arch/xtensa/src/common/Make.defs @@ -27,11 +27,12 @@ HEAD_ASRC += xtensa_int_handlers.S xtensa_user_handler.S CMN_ASRCS = xtensa_context.S xtensa_cpuint.S xtensa_panic.S -CMN_CSRCS = xtensa_assert.c xtensa_cpenable.c xtensa_cpuinfo.c -CMN_CSRCS += xtensa_createstack.c xtensa_exit.c xtensa_getintstack.c -CMN_CSRCS += xtensa_initialize.c xtensa_initialstate.c xtensa_irqdispatch.c -CMN_CSRCS += xtensa_lowputs.c xtensa_modifyreg8.c xtensa_modifyreg16.c -CMN_CSRCS += xtensa_modifyreg32.c xtensa_mdelay.c xtensa_nputs.c xtensa_perf.c +CMN_CSRCS = xtensa_assert.c xtensa_cache.c xtensa_cpenable.c +CMN_CSRCS += xtensa_cpuinfo.c xtensa_createstack.c xtensa_exit.c +CMN_CSRCS += xtensa_getintstack.c xtensa_initialize.c xtensa_initialstate.c +CMN_CSRCS += xtensa_irqdispatch.c xtensa_lowputs.c xtensa_mdelay.c +CMN_CSRCS += xtensa_modifyreg8.c xtensa_modifyreg16.c xtensa_modifyreg32.c +CMN_CSRCS += xtensa_mpu.c xtensa_nputs.c xtensa_oneshot.c xtensa_perf.c CMN_CSRCS += xtensa_releasestack.c xtensa_registerdump.c xtensa_sigdeliver.c CMN_CSRCS += xtensa_switchcontext.c xtensa_swint.c xtensa_stackframe.c CMN_CSRCS += xtensa_saveusercontext.c xtensa_schedsigaction.c xtensa_udelay.c diff --git a/arch/xtensa/src/common/xtensa_mpu.c b/arch/xtensa/src/common/xtensa_mpu.c index ea40bc960fe..338dce8642c 100644 --- a/arch/xtensa/src/common/xtensa_mpu.c +++ b/arch/xtensa/src/common/xtensa_mpu.c @@ -26,6 +26,8 @@ #include "mpu.h" +#if defined(XCHAL_MPU_ENTRIES) && XCHAL_MPU_ENTRIES > 0 + /**************************************************************************** * Private Data ****************************************************************************/ @@ -136,3 +138,5 @@ void mpu_configure_region(uintptr_t base, size_t size, xtensa_mpu_base[region] = base; } + +#endif /* defined(XCHAL_MPU_ENTRIES) && XCHAL_MPU_ENTRIES > 0 */