diff options
author | Alistair Popple <alistair@popple.id.au> | 2020-09-05 01:35:58 +0200 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2020-09-05 21:14:30 +0200 |
commit | ebdf8321eeeb623aed60f7ed16f7445363230118 (patch) | |
tree | 3cb82fcd0eeeda39054b3a59223336c2830c3ba8 /mm/rmap.c | |
parent | mm: madvise: fix vma user-after-free (diff) | |
download | linux-ebdf8321eeeb623aed60f7ed16f7445363230118.tar.xz linux-ebdf8321eeeb623aed60f7ed16f7445363230118.zip |
mm/migrate: fixup setting UFFD_WP flag
Commit f45ec5ff16a75 ("userfaultfd: wp: support swap and page migration")
introduced support for tracking the uffd wp bit during page migration.
However the non-swap PTE variant was used to set the flag for zone device
private pages which are a type of swap page.
This leads to corruption of the swap offset if the original PTE has the
uffd_wp flag set.
Fixes: f45ec5ff16a75 ("userfaultfd: wp: support swap and page migration")
Signed-off-by: Alistair Popple <alistair@popple.id.au>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Reviewed-by: Peter Xu <peterx@redhat.com>
Cc: Jérôme Glisse <jglisse@redhat.com>
Cc: John Hubbard <jhubbard@nvidia.com>
Cc: Ralph Campbell <rcampbell@nvidia.com>
Link: https://lkml.kernel.org/r/20200825064232.10023-1-alistair@popple.id.au
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm/rmap.c')
0 files changed, 0 insertions, 0 deletions