On Sat, 2003-08-23 at 02:22, Hugh Dickins wrote: > Good idea. It's VM_MAYSHARE you need to check for. OK, to get all this to work, there's a corner case in do_mremap() that I need to be fixed: When choosing the flags for the new area, it keys off VM_SHARED to determine whether MAP_SHARED is passed to the mapping. It has to key of VM_MAYSHARE to preserve VM_MAYSHARE on the new mapping. Patch below. James