Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 130531
b: refs/heads/master
c: 33bfad5
h: refs/heads/master
i:
  130529: dab2817
  130527: 675d6ec
v: v3
  • Loading branch information
Linus Torvalds committed Jan 30, 2009
1 parent 4fb2d96 commit 0a6dbcc
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: c01a25e7cf6dcb0fa69c155706d5dd1e76e53796
refs/heads/master: 33bfad54b58cf05cfe6678c3ec9235d4bc8db4c2
5 changes: 4 additions & 1 deletion trunk/mm/mmap.c
Original file line number Diff line number Diff line change
Expand Up @@ -658,14 +658,17 @@ again: remove_next = 1 + (end > next->vm_end);
validate_mm(mm);
}

/* Flags that can be inherited from an existing mapping when merging */
#define VM_MERGEABLE_FLAGS (VM_CAN_NONLINEAR)

/*
* If the vma has a ->close operation then the driver probably needs to release
* per-vma resources, so we don't attempt to merge those.
*/
static inline int is_mergeable_vma(struct vm_area_struct *vma,
struct file *file, unsigned long vm_flags)
{
if (vma->vm_flags != vm_flags)
if ((vma->vm_flags ^ vm_flags) & ~VM_MERGEABLE_FLAGS)
return 0;
if (vma->vm_file != file)
return 0;
Expand Down

0 comments on commit 0a6dbcc

Please sign in to comment.