diff options
author | Matthew Wilcox (Oracle) <willy@infradead.org> | 2020-10-16 05:05:46 +0200 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2020-10-16 20:11:15 +0200 |
commit | 5eaf35ab1275c4048d5c64b7bd9e982af9ea6b9f (patch) | |
tree | d4daef3ac388626801adb0ac9a6bbe207e0841a4 /mm/vmscan.c | |
parent | mm/huge_memory: fix can_split_huge_page assumption of THP size (diff) | |
download | linux-5eaf35ab1275c4048d5c64b7bd9e982af9ea6b9f.tar.xz linux-5eaf35ab1275c4048d5c64b7bd9e982af9ea6b9f.zip |
mm/rmap: fix assumptions of THP size
Ask the page what size it is instead of assuming it's PMD size. Do this
for anon pages as well as file pages for when someone decides to support
that. Leave the assumption alone for pages which are PMD mapped; we don't
currently grow THPs beyond PMD size, so we don't need to change this code
yet.
Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Reviewed-by: SeongJae Park <sjpark@amazon.de>
Acked-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>
Cc: Huang Ying <ying.huang@intel.com>
Link: https://lkml.kernel.org/r/20200908195539.25896-9-willy@infradead.org
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm/vmscan.c')
0 files changed, 0 insertions, 0 deletions