Linux-mm Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [linux-next:master 10221/10910] include/linux/mmzone.h:94:34: error: 'PUD_SHIFT' undeclared here (not in a function); did you mean 'NMI_SHIFT'?
@ 2026-09-26 18:30 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2026-09-26 18:30 UTC (permalink / raw)
  To: Muchun Song; +Cc: oe-kbuild-all, Andrew Morton, Linux Memory Management List

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head:   f5f84daefcd92d7a630066635ecea1433ed5eac7
commit: 90506255be6d7481d4141e51dbbe11d7800e9e75 [10221/10910] mm-sparse-vmemmap-introduce-config_vmemmap_optimization-fix
config: riscv-randconfig-1001-20260927 (https://download.01.org/0day-ci/archive/20260927/202609270240.3jTO1ZSC-lkp@intel.com/config)
compiler: riscv64-linux-gcc (GCC) 16.1.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260927/202609270240.3jTO1ZSC-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202609270240.3jTO1ZSC-lkp@intel.com/

All errors (new ones prefixed by >>):

   In file included from include/linux/gfp.h:7,
                    from include/linux/mm.h:8,
                    from arch/riscv/kernel/asm-offsets.c:9:
>> include/linux/mmzone.h:94:34: error: 'PUD_SHIFT' undeclared here (not in a function); did you mean 'NMI_SHIFT'?
      94 | #define MAX_FOLIO_ORDER         (PUD_SHIFT - PAGE_SHIFT)
         |                                  ^~~~~~~~~
   include/linux/mmzone.h:117:10: note: in expansion of macro 'MAX_FOLIO_ORDER'
     117 |         (MAX_FOLIO_ORDER - VMEMMAP_OPTIMIZATION_MIN_ORDER + 1)
         |          ^~~~~~~~~~~~~~~
   include/linux/mmzone.h:119:11: note: in expansion of macro '__VMEMMAP_OPTIMIZATION_NR_ORDERS'
     119 |         ((__VMEMMAP_OPTIMIZATION_NR_ORDERS > 0 &&       \
         |           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/mmzone.h:1160:36: note: in expansion of macro 'VMEMMAP_OPTIMIZATION_NR_ORDERS'
    1160 |         struct page *vmemmap_tails[VMEMMAP_OPTIMIZATION_NR_ORDERS];
         |                                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   make[3]: *** [scripts/Makefile.build:185: arch/riscv/kernel/asm-offsets.s] Error 1 shuffle=3113152511
   make[3]: Target 'prepare' not remade because of errors.
   make[2]: *** [Makefile:1425: prepare0] Error 2 shuffle=3113152511
   make[2]: Target 'prepare' not remade because of errors.
   make[1]: *** [Makefile:248: __sub-make] Error 2 shuffle=3113152511
   make[1]: Target 'prepare' not remade because of errors.
   make: *** [Makefile:248: __sub-make] Error 2 shuffle=3113152511
   make: Target 'prepare' not remade because of errors.


vim +94 include/linux/mmzone.h

5ad333eb66ff1e Andy Whitcroft  2007-07-17  64  
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  65  #if !defined(CONFIG_HAVE_GIGANTIC_FOLIOS)
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  66  /*
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  67   * We don't expect any folios that exceed buddy sizes (and consequently
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  68   * memory sections).
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  69   */
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  70  #define MAX_FOLIO_ORDER		MAX_PAGE_ORDER
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  71  #elif defined(CONFIG_SPARSEMEM) && !defined(CONFIG_SPARSEMEM_VMEMMAP)
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  72  /*
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  73   * Only pages within a single memory section are guaranteed to be
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  74   * contiguous. By limiting folios to a single memory section, all folio
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  75   * pages are guaranteed to be contiguous.
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  76   */
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  77  #define MAX_FOLIO_ORDER		PFN_SECTION_SHIFT
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  78  #elif defined(CONFIG_HUGETLB_PAGE)
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  79  /*
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  80   * There is no real limit on the folio size. We limit them to the maximum we
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  81   * currently expect (see CONFIG_HAVE_GIGANTIC_FOLIOS): with hugetlb, we expect
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  82   * no folios larger than 16 GiB on 64bit and 1 GiB on 32bit.
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  83   */
622026e87c4019 Kiryl Shutsemau 2026-02-27  84  #ifdef CONFIG_64BIT
622026e87c4019 Kiryl Shutsemau 2026-02-27  85  #define MAX_FOLIO_ORDER		(ilog2(SZ_16G) - PAGE_SHIFT)
622026e87c4019 Kiryl Shutsemau 2026-02-27  86  #else
622026e87c4019 Kiryl Shutsemau 2026-02-27  87  #define MAX_FOLIO_ORDER		(ilog2(SZ_1G) - PAGE_SHIFT)
622026e87c4019 Kiryl Shutsemau 2026-02-27  88  #endif
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  89  #else
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  90  /*
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  91   * Without hugetlb, gigantic folios that are bigger than a single PUD are
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  92   * currently impossible.
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  93   */
622026e87c4019 Kiryl Shutsemau 2026-02-27 @94  #define MAX_FOLIO_ORDER		(PUD_SHIFT - PAGE_SHIFT)
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  95  #endif
a2c77ec320a995 Kiryl Shutsemau 2026-02-27  96  

:::::: The code at line 94 was first introduced by commit
:::::: 622026e87c4019e609010811757e31193cc23847 mm/hugetlb: remove fake head pages

:::::: TO: Kiryl Shutsemau <kas@kernel.org>
:::::: CC: Andrew Morton <akpm@linux-foundation.org>

--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2026-09-26 18:31 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-09-26 18:30 [linux-next:master 10221/10910] include/linux/mmzone.h:94:34: error: 'PUD_SHIFT' undeclared here (not in a function); did you mean 'NMI_SHIFT'? kernel test robot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox