mbed-os/platform/source
Kevin Bracey 0a58c80b56 Tighten GCC 2-region _sbrk
When moving to the second heap region due to overflowing the first
region, the `_sbrk` implementation assumed the allocation would fit in
the second region, and didn't check for that overflowing too.

Problem revealed in `stats_heap` test with GCC 8 on K64F - the allocation
attempt for 1GiB crashed, as `_sbrk` indicated 1GiB was available at the
start of the second region.
second region.

Presumably older versions of newlib fault that allocation attempt before
passing to `_sbrk`.

While there, adjust the code to not use a separate static `bool`, saving
RAM. We can track with just one pointer, as order of the two regions is
fixed, and already relied on by newlib.
2019-10-16 11:53:52 +01:00
..
TARGET_CORTEX_M mbed fault handler: changed the 2nd parameter type. 2019-08-21 17:02:34 +08:00
minimal-printf Minimal-printf: Remove file printing in README and update tables 2019-10-16 11:53:52 +01:00
ATCmdParser.cpp ATCmdParser doxygen header's documentation scanf 2019-10-16 11:53:52 +01:00
CThunkBase.cpp Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
CallChain.cpp Upstream PR #11073 review request changes (#11135) 2019-08-02 12:32:40 +01:00
CriticalSectionLock.cpp Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
DeepSleepLock.cpp Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
FileBase.cpp Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
FileHandle.cpp Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
FilePath.cpp Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
FileSystemHandle.cpp Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
LocalFileSystem.cpp Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
Stream.cpp Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
SysTimer.cpp Fix Coverity issues 2019-10-16 11:53:52 +01:00
SysTimer.h Move source files and add Doxygen labels 2019-09-12 17:18:37 +01:00
mbed_alloc_wrappers.cpp Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
mbed_application.c Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
mbed_assert.c Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
mbed_atomic_impl.c Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
mbed_board.c Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
mbed_crash_data_offsets.h Change Doxygen groups structure, splitting first by Public/Internal (#11105) 2019-08-02 12:23:47 +01:00
mbed_critical.c Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
mbed_error.c Use PRIu32 to print uint32_t variable 2019-10-16 11:53:52 +01:00
mbed_error_hist.c Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
mbed_error_hist.h Change Doxygen groups structure, splitting first by Public/Internal (#11105) 2019-08-02 12:23:47 +01:00
mbed_interface.c Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
mbed_mem_trace.cpp Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
mbed_mktime.c Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
mbed_mpu_mgmt.c Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
mbed_os_timer.cpp Move source files and add Doxygen labels 2019-09-12 17:18:37 +01:00
mbed_os_timer.h Move source files and add Doxygen labels 2019-09-12 17:18:37 +01:00
mbed_poll.cpp Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
mbed_power_mgmt.c Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
mbed_retarget.cpp Tighten GCC 2-region _sbrk 2019-10-16 11:53:52 +01:00
mbed_rtc_time.cpp Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
mbed_sdk_boot.c Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
mbed_semihost_api.c Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
mbed_stats.c Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
mbed_thread.cpp Move source files and add Doxygen labels 2019-09-12 17:18:37 +01:00
mbed_wait_api_no_rtos.c Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
mbed_wait_api_rtos.cpp Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00