summaryrefslogtreecommitdiff
path: root/drivers/media
diff options
context:
space:
mode:
authorNadav Amit <namit@vmware.com>2021-11-21 12:40:08 -0800
committerLinus Torvalds <torvalds@linux-foundation.org>2021-11-22 11:36:46 -0800
commit13e4ad2ce8df6e058ef482a31fdd81c725b0f7ea (patch)
treef299abe211d8fdb36b2134fc739fbb5880cebacb /drivers/media
parenta4a118f2eead1d6c49e00765de89878288d4b890 (diff)
hugetlbfs: flush before unlock on move_hugetlb_page_tables()
We must flush the TLB before releasing i_mmap_rwsem to avoid the potential reuse of an unshared PMDs page. This is not true in the case of move_hugetlb_page_tables(). The last reference on the page table can therefore be dropped before the TLB flush took place. Prevent it by reordering the operations and flushing the TLB before releasing i_mmap_rwsem. Fixes: 550a7d60bd5e ("mm, hugepages: add mremap() support for hugepage backed vma") Signed-off-by: Nadav Amit <namit@vmware.com> Reviewed-by: Mike Kravetz <mike.kravetz@oracle.com> Cc: Mina Almasry <almasrymina@google.com> Cc: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/media')
0 files changed, 0 insertions, 0 deletions