diff --git a/mm/mm_heap/mm_initialize.c b/mm/mm_heap/mm_initialize.c index 414aa96f11..676f1901f4 100644 --- a/mm/mm_heap/mm_initialize.c +++ b/mm/mm_heap/mm_initialize.c @@ -65,7 +65,7 @@ static FAR void *mempool_memalign(FAR void *arg, size_t alignment, if (ret) { node = (FAR struct mm_allocnode_s *) - ((FAR char *)ret - MM_SIZEOF_ALLOCNODE); + ((uintptr_t)ret - MM_SIZEOF_ALLOCNODE); node->pid = PID_MM_MEMPOOL; }