projects
/
platform
/
kernel
/
linux-starfive.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
820c4e2
)
mm/vmscan: Optimise shrink_page_list for non-PMD-sized folios
author
Matthew Wilcox (Oracle)
<willy@infradead.org>
Sat, 15 Aug 2020 23:28:51 +0000
(19:28 -0400)
committer
Matthew Wilcox (Oracle)
<willy@infradead.org>
Mon, 21 Mar 2022 17:01:35 +0000
(13:01 -0400)
A large folio which is smaller than a PMD does not need to do the extra
work in try_to_unmap() of trying to split a PMD entry.
Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
mm/vmscan.c
patch
|
blob
|
history
diff --git
a/mm/vmscan.c
b/mm/vmscan.c
index
d15a9f0
..
8243437
100644
(file)
--- a/
mm/vmscan.c
+++ b/
mm/vmscan.c
@@
-1765,7
+1765,8
@@
retry:
enum ttu_flags flags = TTU_BATCH_FLUSH;
bool was_swapbacked = PageSwapBacked(page);
- if (unlikely(PageTransHuge(page)))
+ if (PageTransHuge(page) &&
+ thp_order(page) >= HPAGE_PMD_ORDER)
flags |= TTU_SPLIT_HUGE_PMD;
try_to_unmap(folio, flags);