Re: [PATCH v1 5/5] mm: ptep_deref() conversion

From: kernel test robot
Date: Fri May 12 2023 - 06:37:16 EST


Hi Ryan,

kernel test robot noticed the following build errors:

[auto build test ERROR on akpm-mm/mm-everything]

url: https://github.com/intel-lab-lkp/linux/commits/Ryan-Roberts/mm-damon-must-atomically-clear-young-on-ptes-and-pmds/20230511-215947
base: https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-everything
patch link: https://lore.kernel.org/r/20230511125848.78621-6-ryan.roberts%40arm.com
patch subject: [PATCH v1 5/5] mm: ptep_deref() conversion
config: m68k-randconfig-r002-20230511 (https://download.01.org/0day-ci/archive/20230512/202305121818.hTDtbbPW-lkp@xxxxxxxxx/config)
compiler: m68k-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://github.com/intel-lab-lkp/linux/commit/2d5aca0fcce58b92572fc59bee59a4c5588f2af8
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review Ryan-Roberts/mm-damon-must-atomically-clear-young-on-ptes-and-pmds/20230511-215947
git checkout 2d5aca0fcce58b92572fc59bee59a4c5588f2af8
# 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=m68k olddefconfig
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=m68k SHELL=/bin/bash

If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@xxxxxxxxx>
| Link: https://lore.kernel.org/oe-kbuild-all/202305121818.hTDtbbPW-lkp@xxxxxxxxx/

All errors (new ones prefixed by >>):

In file included from kernel/fork.c:52:
include/linux/hugetlb.h: In function 'huge_ptep_clear_flush':
>> include/linux/hugetlb.h:1203:16: error: implicit declaration of function 'ptep_deref' [-Werror=implicit-function-declaration]
1203 | return ptep_deref(ptep);
| ^~~~~~~~~~
>> include/linux/hugetlb.h:1203:16: error: incompatible types when returning type 'int' but 'pte_t' was expected
1203 | return ptep_deref(ptep);
| ^~~~~~~~~~~~~~~~
kernel/fork.c: At top level:
kernel/fork.c:164:13: warning: no previous prototype for 'arch_release_task_struct' [-Wmissing-prototypes]
164 | void __weak arch_release_task_struct(struct task_struct *tsk)
| ^~~~~~~~~~~~~~~~~~~~~~~~
kernel/fork.c:991:20: warning: no previous prototype for 'arch_task_cache_init' [-Wmissing-prototypes]
991 | void __init __weak arch_task_cache_init(void) { }
| ^~~~~~~~~~~~~~~~~~~~
kernel/fork.c:1086:12: warning: no previous prototype for 'arch_dup_task_struct' [-Wmissing-prototypes]
1086 | int __weak arch_dup_task_struct(struct task_struct *dst,
| ^~~~~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
--
In file included from kernel/sysctl.c:45:
include/linux/hugetlb.h: In function 'huge_ptep_clear_flush':
>> include/linux/hugetlb.h:1203:16: error: implicit declaration of function 'ptep_deref' [-Werror=implicit-function-declaration]
1203 | return ptep_deref(ptep);
| ^~~~~~~~~~
>> include/linux/hugetlb.h:1203:16: error: incompatible types when returning type 'int' but 'pte_t' was expected
1203 | return ptep_deref(ptep);
| ^~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors


vim +/ptep_deref +1203 include/linux/hugetlb.h

1199
1200 static inline pte_t huge_ptep_clear_flush(struct vm_area_struct *vma,
1201 unsigned long addr, pte_t *ptep)
1202 {
> 1203 return ptep_deref(ptep);
1204 }
1205

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