diff --git a/mm/map/vm_region.c b/mm/map/vm_region.c index 0c94c74de4..9029742c45 100644 --- a/mm/map/vm_region.c +++ b/mm/map/vm_region.c @@ -125,7 +125,7 @@ FAR void *vm_map_region(uintptr_t paddr, size_t size) } } - return vaddr + (MM_PGMASK & paddr); + return (FAR void *)((uintptr_t)vaddr + (MM_PGMASK & paddr)); error: if (i) /* undo alway mapped pages */