mman: Check mmap() MAP_SHARED and MAP_PRIVATE flags

Signed-off-by: Pekka Enberg <penberg@cloudius-systems.com>