newlib: treat x86 as the special case

Although it's unclear why x86 has a different naming convention,
this scales better.

Change-Id: I939b9d4d04b1833391304700a7c12c9c8607192f
Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
This commit is contained in:
Andrew Boie 2016-05-06 10:59:10 -07:00 committed by Benjamin Walsh
parent e91f7101c6
commit 3395211a0b

View file

@ -21,12 +21,12 @@
#include <misc/util.h>
#define USED_RAM_END_ADDR POINTER_TO_UINT(&_end)
#if defined(CONFIG_ARM) || defined(CONFIG_ARC)
#define USED_RAM_SIZE (USED_RAM_END_ADDR - CONFIG_SRAM_BASE_ADDRESS)
#define MAX_HEAP_SIZE ((KB(CONFIG_SRAM_SIZE)) - USED_RAM_SIZE)
#else /* X86 */
#if CONFIG_X86
#define USED_RAM_SIZE (USED_RAM_END_ADDR - CONFIG_PHYS_RAM_ADDR)
#define MAX_HEAP_SIZE ((KB(CONFIG_RAM_SIZE)) - USED_RAM_SIZE)
#else
#define USED_RAM_SIZE (USED_RAM_END_ADDR - CONFIG_SRAM_BASE_ADDRESS)
#define MAX_HEAP_SIZE ((KB(CONFIG_SRAM_SIZE)) - USED_RAM_SIZE)
#endif
static unsigned char *heap_base = UINT_TO_POINTER(USED_RAM_END_ADDR);