Re: [PATCH v1 39/46] powerpc/8xx: Add a function to early map kernel via huge pages

From: kbuild test robot
Date: Mon Mar 16 2020 - 21:40:32 EST


Hi Christophe,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on next-20200316]
[cannot apply to powerpc/next v5.6-rc6 v5.6-rc5 v5.6-rc4 v5.6-rc6]
[if your patch is applied to the wrong git tree, please drop us a note to help
improve the system. BTW, we also suggest to use '--base' option to specify the
base tree in git format-patch, please see https://stackoverflow.com/a/37406982]

url: https://github.com/0day-ci/linux/commits/Christophe-Leroy/Use-hugepages-to-map-kernel-mem-on-8xx/20200317-065610
base: 8548fd2f20ed19b0e8c0585b71fdfde1ae00ae3c
config: powerpc-tqm8xx_defconfig (attached as .config)
compiler: powerpc-linux-gcc (GCC) 9.2.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
GCC_VERSION=9.2.0 make.cross ARCH=powerpc

If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp@xxxxxxxxx>

All errors (new ones prefixed by >>):

In file included from arch/powerpc/mm/fault.c:33:
include/linux/hugetlb.h: In function 'hstate_inode':
>> include/linux/hugetlb.h:522:9: error: implicit declaration of function 'HUGETLBFS_SB'; did you mean 'HUGETLBFS_MAGIC'? [-Werror=implicit-function-declaration]
522 | return HUGETLBFS_SB(i->i_sb)->hstate;
| ^~~~~~~~~~~~
| HUGETLBFS_MAGIC
>> include/linux/hugetlb.h:522:30: error: invalid type argument of '->' (have 'int')
522 | return HUGETLBFS_SB(i->i_sb)->hstate;
| ^~
cc1: all warnings being treated as errors
--
In file included from arch/powerpc/mm/mem.c:30:
include/linux/hugetlb.h: In function 'hstate_inode':
>> include/linux/hugetlb.h:522:9: error: implicit declaration of function 'HUGETLBFS_SB' [-Werror=implicit-function-declaration]
522 | return HUGETLBFS_SB(i->i_sb)->hstate;
| ^~~~~~~~~~~~
>> include/linux/hugetlb.h:522:30: error: invalid type argument of '->' (have 'int')
522 | return HUGETLBFS_SB(i->i_sb)->hstate;
| ^~
cc1: all warnings being treated as errors
--
In file included from arch/powerpc/mm/nohash/8xx.c:12:
include/linux/hugetlb.h: In function 'hstate_inode':
>> include/linux/hugetlb.h:522:9: error: implicit declaration of function 'HUGETLBFS_SB' [-Werror=implicit-function-declaration]
522 | return HUGETLBFS_SB(i->i_sb)->hstate;
| ^~~~~~~~~~~~
>> include/linux/hugetlb.h:522:30: error: invalid type argument of '->' (have 'int')
522 | return HUGETLBFS_SB(i->i_sb)->hstate;
| ^~
At top level:
arch/powerpc/mm/nohash/8xx.c:73:18: error: '__early_map_kernel_hugepage' defined but not used [-Werror=unused-function]
73 | static int __ref __early_map_kernel_hugepage(unsigned long va, phys_addr_t pa,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
--
In file included from arch/powerpc//mm/nohash/8xx.c:12:
include/linux/hugetlb.h: In function 'hstate_inode':
>> include/linux/hugetlb.h:522:9: error: implicit declaration of function 'HUGETLBFS_SB' [-Werror=implicit-function-declaration]
522 | return HUGETLBFS_SB(i->i_sb)->hstate;
| ^~~~~~~~~~~~
>> include/linux/hugetlb.h:522:30: error: invalid type argument of '->' (have 'int')
522 | return HUGETLBFS_SB(i->i_sb)->hstate;
| ^~
At top level:
arch/powerpc//mm/nohash/8xx.c:73:18: error: '__early_map_kernel_hugepage' defined but not used [-Werror=unused-function]
73 | static int __ref __early_map_kernel_hugepage(unsigned long va, phys_addr_t pa,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
--
In file included from include/linux/migrate.h:8,
from kernel///sched/sched.h:53,
from kernel///sched/loadavg.c:9:
include/linux/hugetlb.h: In function 'hstate_inode':
>> include/linux/hugetlb.h:522:9: error: implicit declaration of function 'HUGETLBFS_SB'; did you mean 'HUGETLBFS_MAGIC'? [-Werror=implicit-function-declaration]
522 | return HUGETLBFS_SB(i->i_sb)->hstate;
| ^~~~~~~~~~~~
| HUGETLBFS_MAGIC
>> include/linux/hugetlb.h:522:30: error: invalid type argument of '->' (have 'int')
522 | return HUGETLBFS_SB(i->i_sb)->hstate;
| ^~
cc1: some warnings being treated as errors

vim +522 include/linux/hugetlb.h

a5516438959d90 Andi Kleen 2008-07-23 519
a137e1cc6d6e7d Andi Kleen 2008-07-23 520 static inline struct hstate *hstate_inode(struct inode *i)
a5516438959d90 Andi Kleen 2008-07-23 521 {
7fab358d90e6ba Chen Gang 2016-05-20 @522 return HUGETLBFS_SB(i->i_sb)->hstate;
a5516438959d90 Andi Kleen 2008-07-23 523 }
a5516438959d90 Andi Kleen 2008-07-23 524

:::::: The code at line 522 was first introduced by commit
:::::: 7fab358d90e6ba9d9cb702bee0c8a5f5c13bb6df include/linux/hugetlb*.h: clean up code

:::::: TO: Chen Gang <gang.chen.5i5j@xxxxxxxxx>
:::::: CC: Linus Torvalds <torvalds@xxxxxxxxxxxxxxxxxxxx>

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx

Attachment: .config.gz
Description: application/gzip