Index: kernel/generic/src/mm/as.c
===================================================================
--- kernel/generic/src/mm/as.c	(revision 88cc71c0ffcc673db06571f653009d2efacb8326)
+++ kernel/generic/src/mm/as.c	(revision d9d0088ab6bc13dc60f19b86e9279a8caaf0b3b1)
@@ -403,5 +403,11 @@
 	}
 
-	/* Next area, if any, is the first with base > than our base address */
+	/*
+	 * Next area, if any, is the first with base > than our base address.
+	 * If there was no area with <= base, we need to look at the first area.
+	 */
+	if (odlink == NULL)
+		odlink = odict_first(&as->as_areas);
+
 	if (odlink != NULL) {
 		as_area_t *area = odict_get_instance(odlink, as_area_t,
@@ -487,5 +493,5 @@
 		mutex_lock(&area->lock);
 
-		addr = ALIGN_UP(area->base + P2SZ(area->pages), PAGE_SIZE);
+		addr = area->base + P2SZ(area->pages);
 
 		if (guarded || area->flags & AS_AREA_GUARD) {
