mirror of
https://github.com/espressif/esp-idf.git
synced 2025-07-31 11:17:20 +02:00
Merge branch 'feat/newlib-add-aligned-alloc_v5.1' into 'release/v5.1'
feat(newlib): Add definition of aligned_alloc to heap.c (backport v5.1) See merge request espressif/esp-idf!29471
This commit is contained in:
@ -74,6 +74,11 @@ void* memalign(size_t alignment, size_t n)
|
|||||||
return heap_caps_aligned_alloc(alignment, n, MALLOC_CAP_DEFAULT);
|
return heap_caps_aligned_alloc(alignment, n, MALLOC_CAP_DEFAULT);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void* aligned_alloc(size_t alignment, size_t n)
|
||||||
|
{
|
||||||
|
return heap_caps_aligned_alloc(alignment, n, MALLOC_CAP_DEFAULT);
|
||||||
|
}
|
||||||
|
|
||||||
int posix_memalign(void **out_ptr, size_t alignment, size_t size)
|
int posix_memalign(void **out_ptr, size_t alignment, size_t size)
|
||||||
{
|
{
|
||||||
if (size == 0) {
|
if (size == 0) {
|
||||||
|
Reference in New Issue
Block a user