repair the debug info of memory manege;repair value definition of msgqueue;add lwip path for imxrt1176-sbc board

This commit is contained in:
Wang_Weigen 2022-09-07 10:59:53 +08:00
parent 7c709bfe9f
commit 85ed3a2c10
3 changed files with 12 additions and 8 deletions

View File

@ -33,7 +33,7 @@ struct MsgQueue
{
struct IdNode id;
void *msg_buf;
uint16 index;
int16 index;
uint16 num_msgs;
uint16 each_len;
uint16 max_msgs;

View File

@ -393,7 +393,7 @@ static void* BigMemMalloc(struct DynamicBuddyMemory *dynamic_buddy, x_size_t siz
/* failure allocation */
if(result == NONE) {
#ifndef MEM_EXTERN_SRAM
KPrintf("%s: allocation failed, size %d.\n", __func__,allocsize);
KPrintf("%s: allocation failed, size %d.\n", __func__,size);
#endif
return result;
}
@ -527,7 +527,7 @@ static void SmallMemInit(struct ByteMemory *byte_memory)
#ifdef MEM_STATS
/* statistic static memory information */
byte_memory->dynamic_buddy_manager.static_memory = SMALL_SIZE_64B(SIZEOF_64B) + SMALL_SIZE_32B(SIZEOF_32B);
byte_memory->dynamic_buddy_manager.static_memory = SMALL_NUMBER_64B * SIZEOF_64B + SMALL_NUMBER_32B * SIZEOF_32B;
#endif
}
@ -1174,10 +1174,10 @@ void ShowMemory(void);
void ShowMemory(void)
{
int i = 0;
KPrintf("total memory: %d\n", ByteManager.dynamic_buddy_manager.dynamic_buddy_end - ByteManager.dynamic_buddy_manager.dynamic_buddy_start);
KPrintf("total memory: %d\n", ByteManager.dynamic_buddy_manager.dynamic_buddy_end - ByteManager.dynamic_buddy_manager.dynamic_buddy_start - SIZEOF_32B);
KPrintf("used memory : %d\n", ByteManager.dynamic_buddy_manager.active_memory);
KPrintf("maximum allocated memory: %d\n", ByteManager.dynamic_buddy_manager.max_ever_usedmem);
KPrintf("total cache szie: %d, %d/%d[32B],%d/%d[64B]\n", ByteManager.dynamic_buddy_manager.static_memory,ByteManager.static_manager[0].block_free_count,SMALL_NUMBER_32B,ByteManager.static_manager[1].block_free_count,SMALL_NUMBER_64B);
KPrintf("total cache size: %d, %d/%d[32B],%d/%d[64B]\n", ByteManager.dynamic_buddy_manager.static_memory,ByteManager.static_manager[0].block_free_count,SMALL_NUMBER_32B,ByteManager.static_manager[1].block_free_count,SMALL_NUMBER_64B);
#ifdef MEM_EXTERN_SRAM
for(i = 0; i < EXTSRAM_MAX_NUM; i++) {
if(NONE != ExtByteManager[i].done){

View File

@ -289,7 +289,12 @@ KERNELPATHS += \
-I$(BSP_ROOT)/third_party_driver \
-I$(BSP_ROOT)/third_party_driver/include \
-I$(BSP_ROOT)/third_party_driver/CMSIS/Include \
-I$(BSP_ROOT)/xip \
-I$(KERNEL_ROOT)/include \
-I$(KERNEL_ROOT)/resources/include \
ifeq ($(CONFIG_RESOURCES_LWIP),y)
KERNELPATHS += \
-I$(KERNEL_ROOT)/resources/ethernet/LwIP \
-I$(KERNEL_ROOT)/resources/ethernet/LwIP/include \
-I$(KERNEL_ROOT)/resources/ethernet/LwIP/include/compat \
@ -298,9 +303,8 @@ KERNELPATHS += \
-I$(KERNEL_ROOT)/resources/ethernet/LwIP/include/lwip/apps \
-I$(KERNEL_ROOT)/resources/ethernet/LwIP/include/lwip/priv \
-I$(KERNEL_ROOT)/resources/ethernet/LwIP/include/lwip/prot \
-I$(KERNEL_ROOT)/resources/ethernet/LwIP/arch \
-I$(KERNEL_ROOT)/resources/include \
-I$(BSP_ROOT)/xip #
-I$(KERNEL_ROOT)/resources/ethernet/LwIP/arch
endif
endif
ifeq ($(BSP_ROOT),$(KERNEL_ROOT)/board/stm32f103-nano)