mbed-os/platform
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
..
bare_metal Addressed review comments, in particular: 2019-08-01 12:42:24 +01:00
cxxsupport mstd_iterator: correct comments 2019-08-27 14:37:07 +03:00
internal Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
source Tighten GCC 2-region _sbrk 2019-10-16 11:53:52 +01:00
ATCmdParser.h ATCmdParser doxygen header's documentation scanf 2019-10-16 11:53:52 +01:00
CThunk.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
CallChain.h Upstream PR #11073 review request changes (#11135) 2019-08-02 12:32:40 +01:00
Callback.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
CircularBuffer.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
CriticalSectionLock.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
DeepSleepLock.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
DirHandle.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
FileBase.h Change Doxygen groups structure, splitting first by Public/Internal (#11105) 2019-08-02 12:23:47 +01:00
FileHandle.h Change Doxygen groups structure, splitting first by Public/Internal (#11105) 2019-08-02 12:23:47 +01:00
FileLike.h Change Doxygen groups structure, splitting first by Public/Internal (#11105) 2019-08-02 12:23:47 +01:00
FilePath.h Change Doxygen groups structure, splitting first by Public/Internal (#11105) 2019-08-02 12:23:47 +01:00
FileSystemHandle.h Change Doxygen groups structure, splitting first by Public/Internal (#11105) 2019-08-02 12:23:47 +01:00
FileSystemLike.h Change Doxygen groups structure, splitting first by Public/Internal (#11105) 2019-08-02 12:23:47 +01:00
FunctionPointer.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
LocalFileSystem.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
NonCopyable.h Fix Coverity issue: Initialize FlashIAP non-static member in constructor 2019-10-16 11:53:52 +01:00
PlatformMutex.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
ScopedLock.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
ScopedRamExecutionLock.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
ScopedRomWriteLock.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
SharedPtr.h Assembler atomics 2019-04-26 13:12:35 +03:00
SingletonPtr.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
Span.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
Stream.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
Transaction.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
astyle-branch.out platform: astyle update 2018-06-29 10:38:44 +01:00
critical.h Renamed files in platform to match source names 2017-02-22 18:17:54 -06:00
mbed_application.h Add bootloader support for the LPC55S69 board 2019-03-16 00:13:40 +02:00
mbed_assert.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
mbed_atomic.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
mbed_critical.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
mbed_debug.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
mbed_error.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
mbed_interface.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
mbed_lib.json minimal-printf: Disable floating point support by default 2019-09-12 17:18:37 +01:00
mbed_mem_trace.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
mbed_mktime.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
mbed_mpu_mgmt.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
mbed_poll.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
mbed_power_mgmt.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
mbed_preprocessor.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
mbed_retarget.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
mbed_rtc_time.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
mbed_semihost_api.h Platform: Separate internal APIs from public APIs 2019-08-02 12:23:47 +01:00
mbed_sleep.h Fix merge conflict mishap 2018-03-01 17:33:21 +00:00
mbed_stats.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
mbed_thread.h Move source files and add Doxygen labels 2019-09-12 17:18:37 +01:00
mbed_toolchain.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
mbed_version.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
mbed_wait_api.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
platform.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
rtc_time.h Renamed files in platform to match source names 2017-02-22 18:17:54 -06:00
semihost_api.h Renamed files in platform to match source names 2017-02-22 18:17:54 -06:00
sleep.h Add system_reset() function to Mbed OS 2018-02-28 16:42:34 +00:00
toolchain.h Harmonise Doxygen comments in drivers, events, platform and rtos dirs 2019-10-16 11:53:52 +01:00
wait_api.h Renamed files in platform to match source names 2017-02-22 18:17:54 -06:00