git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@9225 35acf78f-673a-0410-8e92-d51de3d6d3f4

master
Giovanni Di Sirio 2016-04-02 17:08:20 +00:00
parent 71f174d00d
commit ab2638e9a2
1 changed files with 5 additions and 6 deletions

View File

@ -82,15 +82,14 @@ void _core_init(void) {
extern uint8_t __heap_end__[];
/*lint -save -e9033 [10.8] Required cast operations.*/
nextmem = (uint8_t *)MEM_ALIGN_NEXT(__heap_base__, PORT_NATURAL_ALIGN);
endmem = (uint8_t *)MEM_ALIGN_PREV(__heap_end__, PORT_NATURAL_ALIGN);
nextmem = __heap_base__;
endmem = __heap_end__;
/*lint restore*/
#else
static uint8_t default_heap[MEM_ALIGN_NEXT(CH_CFG_MEMCORE_SIZE,
PORT_NATURAL_ALIGN)];
static uint8_t static_heap[CH_CFG_MEMCORE_SIZE];
nextmem = (uint8_t *)MEM_ALIGN_NEXT(default_heap, PORT_NATURAL_ALIGN);
endmem = (uint8_t *)MEM_ALIGN_PREV(default_heap, PORT_NATURAL_ALIGN);
nextmem = &static_heap[0];
endmem = &static_heap[CH_CFG_MEMCORE_SIZE];
#endif
}