mm: Fix VMR merge issues
authorBarret Rhoden <brho@cs.berkeley.edu>
Tue, 1 Aug 2017 21:01:13 +0000 (17:01 -0400)
committerBarret Rhoden <brho@cs.berkeley.edu>
Mon, 14 Aug 2017 21:02:19 +0000 (17:02 -0400)
commit99f9da5dd7ab1716d707ff2de59d3e7ff0e9232d
tree0ef1ef9d11ea4fceed77f639ce7e6b5e63e810c9
parentd0db00caa73f8a014e7599fbb46fceb02d86859a
mm: Fix VMR merge issues

First, mprotect wasn't merging at all.  Glibc actually uses this a lot when
we allocate TLSs (grep grow_heap() and ignore that it is static).

Also we were failing to merge some mappings since we were keeping track of
useless flags.  For instance, MAP_POPULATE only matters when we create the
mapping.  We don't need to track that later on.  Flags like that were
preventing mergers.

Signed-off-by: Barret Rhoden <brho@cs.berkeley.edu>
kern/src/mm.c