Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Fork of lwip by
Diff: core/mem.c
- Revision:
- 16:092c37b63ee8
- Parent:
- 10:42a34d63b218
- Child:
- 18:2dd57fc0af78
--- a/core/mem.c Thu Mar 20 15:45:43 2014 +0000 +++ b/core/mem.c Thu Apr 24 10:45:42 2014 +0100 @@ -186,8 +186,10 @@ # else # define ETHMEM_SECTION __attribute__((section("AHBSRAM1"),aligned)) # endif +#elif defined(TARGET_LPC1768) +# define ETHMEM_SECTION __attribute((section("AHBSRAM0"))) #else -# define ETHMEM_SECTION __attribute((section("AHBSRAM0"))) +# define ETHMEM_SECTION #endif /** the heap. we need one struct mem at the end and some room for alignment */ @@ -609,10 +611,10 @@ sys_mutex_unlock(&mem_mutex); LWIP_ASSERT("mem_malloc: allocated memory not above ram_end.", (mem_ptr_t)mem + SIZEOF_STRUCT_MEM + size <= (mem_ptr_t)ram_end); - LWIP_ASSERT("mem_malloc: allocated memory properly aligned.", - ((mem_ptr_t)mem + SIZEOF_STRUCT_MEM) % MEM_ALIGNMENT == 0); + LWIP_ASSERT("mem_malloc: allocated memory properly aligned.", + ((mem_ptr_t)mem + SIZEOF_STRUCT_MEM) % MEM_ALIGNMENT == 0); LWIP_ASSERT("mem_malloc: sanity check alignment", - (((mem_ptr_t)mem) & (MEM_ALIGNMENT-1)) == 0); + (((mem_ptr_t)mem) & (MEM_ALIGNMENT-1)) == 0); return (u8_t *)mem + SIZEOF_STRUCT_MEM; }