linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/4] Clean up hugetlb boot command line processing
@ 2020-04-01 18:38 Mike Kravetz
  2020-04-01 18:38 ` [PATCH v2 1/4] hugetlbfs: add arch_hugetlb_valid_size Mike Kravetz
                   ` (3 more replies)
  0 siblings, 4 replies; 13+ messages in thread
From: Mike Kravetz @ 2020-04-01 18:38 UTC (permalink / raw)
  To: linux-mm, linux-kernel, linux-arm-kernel, linuxppc-dev,
	linux-riscv, linux-s390, sparclinux, linux-doc
  Cc: Catalin Marinas, Will Deacon, Benjamin Herrenschmidt,
	Paul Mackerras, Paul Walmsley, Palmer Dabbelt, Albert Ou,
	Heiko Carstens, Vasily Gorbik, Christian Borntraeger,
	David S . Miller, Thomas Gleixner, Ingo Molnar, Dave Hansen,
	Jonathan Corbet, Longpeng, Christophe Leroy, Mina Almasry,
	Andrew Morton, Mike Kravetz

v2 -
   Fix build errors with patch 1 (Will)
   Change arch_hugetlb_valid_size arg to unsigned long and remove
     irrelevant 'extern' keyword (Christophe)
   Documentation and other misc changes (Randy, Christophe, Mina)
   Do not process command line options if !hugepages_supported()
     (Dave, but it sounds like we may want to additional changes to
      hugepages_supported() for x86?  If that is needed I would prefer
      a separate patch.)

Longpeng(Mike) reported a weird message from hugetlb command line processing
and proposed a solution [1].  While the proposed patch does address the
specific issue, there are other related issues in command line processing.
As hugetlbfs evolved, updates to command line processing have been made to
meet immediate needs and not necessarily in a coordinated manner.  The result
is that some processing is done in arch specific code, some is done in arch
independent code and coordination is problematic.  Semantics can vary between
architectures.

The patch series does the following:
- Define arch specific arch_hugetlb_valid_size routine used to validate
  passed huge page sizes.
- Move hugepagesz= command line parsing out of arch specific code and into
  an arch independent routine.
- Clean up command line processing to follow desired semantics and
  document those semantics.

[1] https://lore.kernel.org/linux-mm/20200305033014.1152-1-longpeng2@huawei.com

Mike Kravetz (4):
  hugetlbfs: add arch_hugetlb_valid_size
  hugetlbfs: move hugepagesz= parsing to arch independent code
  hugetlbfs: remove hugetlb_add_hstate() warning for existing hstate
  hugetlbfs: clean up command line processing

 .../admin-guide/kernel-parameters.txt         |  35 +++--
 Documentation/admin-guide/mm/hugetlbpage.rst  |  44 ++++++
 arch/arm64/include/asm/hugetlb.h              |   2 +
 arch/arm64/mm/hugetlbpage.c                   |  30 +---
 arch/powerpc/include/asm/hugetlb.h            |   3 +
 arch/powerpc/mm/hugetlbpage.c                 |  30 ++--
 arch/riscv/include/asm/hugetlb.h              |   3 +
 arch/riscv/mm/hugetlbpage.c                   |  24 +--
 arch/s390/include/asm/hugetlb.h               |   3 +
 arch/s390/mm/hugetlbpage.c                    |  24 +--
 arch/sparc/include/asm/hugetlb.h              |   3 +
 arch/sparc/mm/init_64.c                       |  43 ++----
 arch/x86/include/asm/hugetlb.h                |   5 +
 arch/x86/mm/hugetlbpage.c                     |  23 +--
 include/linux/hugetlb.h                       |   8 +-
 mm/hugetlb.c                                  | 141 ++++++++++++++----
 16 files changed, 252 insertions(+), 169 deletions(-)

-- 
2.25.1



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

end of thread, other threads:[~2020-04-14 15:28 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-01 18:38 [PATCH v2 0/4] Clean up hugetlb boot command line processing Mike Kravetz
2020-04-01 18:38 ` [PATCH v2 1/4] hugetlbfs: add arch_hugetlb_valid_size Mike Kravetz
2020-04-10 19:16   ` Peter Xu
2020-04-13 17:04     ` Mike Kravetz
2020-04-01 18:38 ` [PATCH v2 2/4] hugetlbfs: move hugepagesz= parsing to arch independent code Mike Kravetz
2020-04-10 19:26   ` Peter Xu
2020-04-01 18:38 ` [PATCH v2 3/4] hugetlbfs: remove hugetlb_add_hstate() warning for existing hstate Mike Kravetz
2020-04-10 19:34   ` Peter Xu
2020-04-01 18:38 ` [PATCH v2 4/4] hugetlbfs: clean up command line processing Mike Kravetz
2020-04-01 18:55   ` Randy Dunlap
2020-04-10 20:37   ` Peter Xu
2020-04-13 17:59     ` Mike Kravetz
2020-04-14 15:27       ` Peter Xu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).