Hi Masahiro, FYI, the error/warning still remains. tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master head: d635f6cc934bcd467c5d67148ece74632fd96abf commit: 80b6093b55e31c2c40ff082fb32523d4e852954f kbuild: add -Wundef to KBUILD_CPPFLAGS for W=1 builds date: 5 months ago config: arm64-randconfig-r005-20230520 compiler: aarch64-linux-gcc (GCC) 12.1.0 reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=80b6093b55e31c2c40ff082fb32523d4e852954f git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git git fetch --no-tags linus master git checkout 80b6093b55e31c2c40ff082fb32523d4e852954f # save the config file mkdir build_dir && cp config build_dir/.config COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=arm64 olddefconfig COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=arm64 SHELL=/bin/bash If you fix the issue, kindly add following tag where applicable | Reported-by: kernel test robot | Closes: https://lore.kernel.org/oe-kbuild-all/202305201926.3oEwKwvf-lkp@intel.com/ All warnings (new ones prefixed by >>): In file included from arch/arm64/include/asm/assembler.h:25, from arch/arm64/include/asm/linkage.h:5, from include/linux/linkage.h:8, from arch/arm64/kernel/entry.S:12: >> arch/arm64/include/asm/pgtable-hwdef.h:82:64: warning: "PMD_SHIFT" is not defined, evaluates to 0 [-Wundef] 82 | #define CONT_PMD_SHIFT (CONFIG_ARM64_CONT_PMD_SHIFT + PMD_SHIFT) | ^~~~~~~~~ arch/arm64/include/asm/kernel-pgtable.h:133:41: note: in expansion of macro 'CONT_PMD_SHIFT' 133 | #define ARM64_MEMSTART_SHIFT CONT_PMD_SHIFT | ^~~~~~~~~~~~~~ arch/arm64/include/asm/kernel-pgtable.h:144:5: note: in expansion of macro 'ARM64_MEMSTART_SHIFT' 144 | #if ARM64_MEMSTART_SHIFT < SECTION_SIZE_BITS | ^~~~~~~~~~~~~~~~~~~~ vim +/PMD_SHIFT +82 arch/arm64/include/asm/pgtable-hwdef.h e676594115f0bc Gavin Shan 2020-09-10 81 e676594115f0bc Gavin Shan 2020-09-10 @82 #define CONT_PMD_SHIFT (CONFIG_ARM64_CONT_PMD_SHIFT + PMD_SHIFT) a1634a542f7430 Gavin Shan 2020-06-30 83 #define CONT_PMDS (1 << (CONT_PMD_SHIFT - PMD_SHIFT)) 66b3923a1a0f77 David Woods 2015-12-17 84 #define CONT_PMD_SIZE (CONT_PMDS * PMD_SIZE) 66b3923a1a0f77 David Woods 2015-12-17 85 #define CONT_PMD_MASK (~(CONT_PMD_SIZE - 1)) ecf35a237a85d7 Jeremy Linton 2015-10-07 86 :::::: The code at line 82 was first introduced by commit :::::: e676594115f0bcc12d4791f9ee919e20d8d750ee arm64/mm: Unify CONT_PMD_SHIFT :::::: TO: Gavin Shan :::::: CC: Will Deacon -- 0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki