The patch titled
fix mprotect vma_wants_writenotify prot
has been removed from the -mm tree. Its filename was
fix-mprotect-vma_wants_writenotify-prot.patch
This patch was dropped because it was merged into mainline or a subsystem tree
------------------------------------------------------
Subject: fix mprotect vma_wants_writenotify prot
From: Hugh Dickins <[EMAIL PROTECTED]>
Fix mprotect bug in recent commit 3ed75eb8f1cd89565966599c4f77d2edb086d5b0
(setup vma->vm_page_prot by vm_get_page_prot()): the vma_wants_writenotify
case was setting the same prot as when not.
Nothing wrong with the use of protection_map[] in mmap_region(),
but use vm_get_page_prot() there too in the same ~VM_SHARED way.
Signed-off-by: Hugh Dickins <[EMAIL PROTECTED]>
Cc: Coly Li <[EMAIL PROTECTED]>
Cc: Tony Luck <[EMAIL PROTECTED]>
Signed-off-by: Andrew Morton <[EMAIL PROTECTED]>
---
mm/mmap.c | 3 +--
mm/mprotect.c | 2 +-
2 files changed, 2 insertions(+), 3 deletions(-)
diff -puN mm/mmap.c~fix-mprotect-vma_wants_writenotify-prot mm/mmap.c
--- a/mm/mmap.c~fix-mprotect-vma_wants_writenotify-prot
+++ a/mm/mmap.c
@@ -1171,8 +1171,7 @@ munmap_back:
vm_flags = vma->vm_flags;
if (vma_wants_writenotify(vma))
- vma->vm_page_prot =
- protection_map[vm_flags & (VM_READ|VM_WRITE|VM_EXEC)];
+ vma->vm_page_prot = vm_get_page_prot(vm_flags & ~VM_SHARED);
if (!file || !vma_merge(mm, prev, addr, vma->vm_end,
vma->vm_flags, NULL, file, pgoff, vma_policy(vma))) {
diff -puN mm/mprotect.c~fix-mprotect-vma_wants_writenotify-prot mm/mprotect.c
--- a/mm/mprotect.c~fix-mprotect-vma_wants_writenotify-prot
+++ a/mm/mprotect.c
@@ -194,7 +194,7 @@ success:
vma->vm_flags = newflags;
vma->vm_page_prot = vm_get_page_prot(newflags);
if (vma_wants_writenotify(vma)) {
- vma->vm_page_prot = vm_get_page_prot(newflags);
+ vma->vm_page_prot = vm_get_page_prot(newflags & ~VM_SHARED);
dirty_accountable = 1;
}
_
Patches currently in -mm which might be from [EMAIL PROTECTED] are
swapin_readahead-excise-numa-bogosity.patch
swapin_readahead-move-and-rearrange-args.patch
swapin-needs-gfp_mask-for-loop-on-tmpfs.patch
shmem-sgp_quick-and-sgp_fault-redundant.patch
shmem_getpage-return-page-locked.patch
shmem_file_write-is-redundant.patch
swapin-fix-valid_swaphandles-defect.patch
memory-controller-memory-accounting-v7.patch
prio_tree-debugging-patch.patch
-
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html