diff options
author | Linus Torvalds <torvalds@g5.osdl.org> | 2005-12-16 13:21:23 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2005-12-16 13:21:23 -0500 |
commit | 4d7672b46244abffea1953e55688c0ea143dd617 (patch) | |
tree | 9f3bdf438bcb0d5f6e723665ced23308fffb8368 /mm/mmap.c | |
parent | 281ab031a8c9e5b593142eb4ec59a87faae8676a (diff) |
Make sure we copy pages inserted with "vm_insert_page()" on fork
The logic that decides that a fork() might be able to avoid copying a VM
area when it can be re-created by page faults didn't know about the new
vm_insert_page() case.
Also make some things a bit more anal wrt VM_PFNMAP.
Pointed out by Hugh Dickins <hugh@veritas.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'mm/mmap.c')
-rw-r--r-- | mm/mmap.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -611,7 +611,7 @@ again: remove_next = 1 + (end > next->vm_end); | |||
611 | * If the vma has a ->close operation then the driver probably needs to release | 611 | * If the vma has a ->close operation then the driver probably needs to release |
612 | * per-vma resources, so we don't attempt to merge those. | 612 | * per-vma resources, so we don't attempt to merge those. |
613 | */ | 613 | */ |
614 | #define VM_SPECIAL (VM_IO | VM_DONTCOPY | VM_DONTEXPAND | VM_RESERVED) | 614 | #define VM_SPECIAL (VM_IO | VM_DONTCOPY | VM_DONTEXPAND | VM_RESERVED | VM_PFNMAP) |
615 | 615 | ||
616 | static inline int is_mergeable_vma(struct vm_area_struct *vma, | 616 | static inline int is_mergeable_vma(struct vm_area_struct *vma, |
617 | struct file *file, unsigned long vm_flags) | 617 | struct file *file, unsigned long vm_flags) |