All of lore.kernel.org
 help / color / mirror / Atom feed
* [Patch v2 0/4] mm/mremap: cleanup move_page_tables() a little
@ 2020-01-29  0:26 Wei Yang
  2020-01-29  0:26 ` [Patch v2 1/4] mm/mremap: format the check in move_normal_pmd() same as move_huge_pmd() Wei Yang
                   ` (4 more replies)
  0 siblings, 5 replies; 7+ messages in thread
From: Wei Yang @ 2020-01-29  0:26 UTC (permalink / raw)
  To: akpm, aneesh.kumar, kirill, dan.j.williams, yang.shi, thellstrom,
	richardw.yang
  Cc: linux-kernel, linux-mm, digetx

move_page_tables() tries to move page table by PMD or PTE.

The root reason is if it tries to move PMD, both old and new range should
be PMD aligned. But current code calculate old range and new range
separately.  This leads to some redundant check and calculation.

This cleanup tries to consolidate the range check in one place to reduce
some extra range handling.

v2:
  * remove 3rd patch which doesn't work on ARM platform. Thanks report from
    Dmitry Osipenko

Wei Yang (4):
  mm/mremap: format the check in move_normal_pmd() same as
    move_huge_pmd()
  mm/mremap: it is sure to have enough space when extent meets
    requirement
  mm/mremap: calculate extent in one place
  mm/mremap: start addresses are properly aligned

 include/linux/huge_mm.h |  2 +-
 mm/huge_memory.c        |  8 +-------
 mm/mremap.c             | 17 ++++++-----------
 3 files changed, 8 insertions(+), 19 deletions(-)

-- 
2.17.1


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2020-01-30 23:04 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-01-29  0:26 [Patch v2 0/4] mm/mremap: cleanup move_page_tables() a little Wei Yang
2020-01-29  0:26 ` [Patch v2 1/4] mm/mremap: format the check in move_normal_pmd() same as move_huge_pmd() Wei Yang
2020-01-29  0:26 ` [Patch v2 2/4] mm/mremap: it is sure to have enough space when extent meets requirement Wei Yang
2020-01-29  0:26 ` [Patch v2 3/4] mm/mremap: calculate extent in one place Wei Yang
2020-01-29  0:26 ` [Patch v2 4/4] mm/mremap: start addresses are properly aligned Wei Yang
2020-01-30 22:18 ` [Patch v2 0/4] mm/mremap: cleanup move_page_tables() a little Dmitry Osipenko
2020-01-30 23:05   ` Wei Yang

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.