diff options
author | Andrew Morton <akpm@linux-foundation.org> | 2022-09-26 22:13:15 +0200 |
---|---|---|
committer | Andrew Morton <akpm@linux-foundation.org> | 2022-09-26 22:13:15 +0200 |
commit | 6d751329e761338faa9c24c2c9736f27bc54282b (patch) | |
tree | 6e1778a7448552c58d12da88f70f6ad2718d55da /mm/madvise.c | |
parent | mm: fix PageAnonExclusive clearing racing with concurrent RCU GUP-fast (diff) | |
parent | x86/uaccess: avoid check_object_size() in copy_from_user_nmi() (diff) | |
download | linux-6d751329e761338faa9c24c2c9736f27bc54282b.tar.xz linux-6d751329e761338faa9c24c2c9736f27bc54282b.zip |
Merge branch 'mm-hotfixes-stable' into mm-stable
Diffstat (limited to 'mm/madvise.c')
-rw-r--r-- | mm/madvise.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/mm/madvise.c b/mm/madvise.c index af97100a0727..4f86eb7f554d 100644 --- a/mm/madvise.c +++ b/mm/madvise.c @@ -452,8 +452,11 @@ regular_page: continue; } - /* Do not interfere with other mappings of this page */ - if (page_mapcount(page) != 1) + /* + * Do not interfere with other mappings of this page and + * non-LRU page. + */ + if (!PageLRU(page) || page_mapcount(page) != 1) continue; VM_BUG_ON_PAGE(PageTransCompound(page), page); |