Merge 4.9.50 into android-4.9
Changes in 4.9.50 mtd: nand: mxc: Fix mxc_v1 ooblayout mtd: nand: qcom: fix read failure without complete bootchain mtd: nand: qcom: fix config error for BCH nvme-fabrics: generate spec-compliant UUID NQNs btrfs: resume qgroup rescan on rw remount selftests/x86/fsgsbase: Test selectors 1, 2, and 3 mm/memory.c: fix mem_cgroup_oom_disable() call missing locktorture: Fix potential memory leak with rw lock test ALSA: msnd: Optimize / harden DSP and MIDI loops Bluetooth: Properly check L2CAP config option output buffer length ARM64: dts: marvell: armada-37xx: Fix GIC maintenance interrupt ARM: 8692/1: mm: abort uaccess retries upon fatal signal NFS: Fix 2 use after free issues in the I/O code NFS: Sync the correct byte range during synchronous writes xfs: XFS_IS_REALTIME_INODE() should be false if no rt device present Linux 4.9.50 Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
This commit is contained in:
+5
-5
@@ -3596,6 +3596,11 @@ int handle_mm_fault(struct vm_area_struct *vma, unsigned long address,
|
||||
/* do counter updates before entering really critical section. */
|
||||
check_sync_rss_stat(current);
|
||||
|
||||
if (!arch_vma_access_permitted(vma, flags & FAULT_FLAG_WRITE,
|
||||
flags & FAULT_FLAG_INSTRUCTION,
|
||||
flags & FAULT_FLAG_REMOTE))
|
||||
return VM_FAULT_SIGSEGV;
|
||||
|
||||
/*
|
||||
* Enable the memcg OOM handling for faults triggered in user
|
||||
* space. Kernel faults are handled more gracefully.
|
||||
@@ -3603,11 +3608,6 @@ int handle_mm_fault(struct vm_area_struct *vma, unsigned long address,
|
||||
if (flags & FAULT_FLAG_USER)
|
||||
mem_cgroup_oom_enable();
|
||||
|
||||
if (!arch_vma_access_permitted(vma, flags & FAULT_FLAG_WRITE,
|
||||
flags & FAULT_FLAG_INSTRUCTION,
|
||||
flags & FAULT_FLAG_REMOTE))
|
||||
return VM_FAULT_SIGSEGV;
|
||||
|
||||
if (unlikely(is_vm_hugetlb_page(vma)))
|
||||
ret = hugetlb_fault(vma->vm_mm, vma, address, flags);
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user