Re: [PATCH] mm: fixmap: convert __set_fixmap_offset() to an inline function

From: kbuild test robot
Date: Sat Nov 09 2019 - 17:40:52 EST


Hi Masahiro,

I love your patch! Perhaps something to improve:

[auto build test WARNING on mmotm/master]
[also build test WARNING on v5.4-rc6 next-20191108]
[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/Masahiro-Yamada/mm-fixmap-convert-__set_fixmap_offset-to-an-inline-function/20191110-045158
base: git://git.cmpxchg.org/linux-mmotm.git master
config: powerpc-allnoconfig (attached as .config)
compiler: powerpc-linux-gcc (GCC) 7.4.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=7.4.0 make.cross ARCH=powerpc

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

All warnings (new ones prefixed by >>):

In file included from arch/powerpc/include/asm/fixmap.h:75:0,
from arch/powerpc/include/asm/book3s/32/pgtable.h:149,
from arch/powerpc/include/asm/book3s/pgtable.h:8,
from arch/powerpc/include/asm/pgtable.h:18,
from arch/powerpc/include/asm/kup.h:30,
from arch/powerpc/include/asm/uaccess.h:9,
from include/linux/uaccess.h:11,
from include/linux/crypto.h:21,
from include/crypto/hash.h:11,
from include/linux/uio.h:10,
from include/linux/socket.h:8,
from include/linux/compat.h:15,
from arch/powerpc/kernel/asm-offsets.c:14:
include/asm-generic/fixmap.h: In function '__set_fixmap_offset':
include/asm-generic/fixmap.h:78:2: error: implicit declaration of function '__set_fixmap'; did you mean 'set_fixmap'? [-Werror=implicit-function-declaration]
__set_fixmap(idx, phys, flags);
^~~~~~~~~~~~
set_fixmap
In file included from arch/powerpc/include/asm/book3s/32/pgtable.h:149:0,
from arch/powerpc/include/asm/book3s/pgtable.h:8,
from arch/powerpc/include/asm/pgtable.h:18,
from arch/powerpc/include/asm/kup.h:30,
from arch/powerpc/include/asm/uaccess.h:9,
from include/linux/uaccess.h:11,
from include/linux/crypto.h:21,
from include/crypto/hash.h:11,
from include/linux/uio.h:10,
from include/linux/socket.h:8,
from include/linux/compat.h:15,
from arch/powerpc/kernel/asm-offsets.c:14:
arch/powerpc/include/asm/fixmap.h: At top level:
>> arch/powerpc/include/asm/fixmap.h:77:20: warning: conflicting types for '__set_fixmap'
static inline void __set_fixmap(enum fixed_addresses idx,
^~~~~~~~~~~~
arch/powerpc/include/asm/fixmap.h:77:20: error: static declaration of '__set_fixmap' follows non-static declaration
In file included from arch/powerpc/include/asm/fixmap.h:75:0,
from arch/powerpc/include/asm/book3s/32/pgtable.h:149,
from arch/powerpc/include/asm/book3s/pgtable.h:8,
from arch/powerpc/include/asm/pgtable.h:18,
from arch/powerpc/include/asm/kup.h:30,
from arch/powerpc/include/asm/uaccess.h:9,
from include/linux/uaccess.h:11,
from include/linux/crypto.h:21,
from include/crypto/hash.h:11,
from include/linux/uio.h:10,
from include/linux/socket.h:8,
from include/linux/compat.h:15,
from arch/powerpc/kernel/asm-offsets.c:14:
include/asm-generic/fixmap.h:78:2: note: previous implicit declaration of '__set_fixmap' was here
__set_fixmap(idx, phys, flags);
^~~~~~~~~~~~
cc1: some warnings being treated as errors
make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1
make[2]: Target '__build' not remade because of errors.
make[1]: *** [prepare0] Error 2
make[1]: Target 'prepare' not remade because of errors.
make: *** [sub-make] Error 2
17 real 5 user 2 sys 44.62% cpu make prepare

vim +/__set_fixmap +77 arch/powerpc/include/asm/fixmap.h

2c419bdeca1d95 include/asm-powerpc/fixmap.h Kumar Gala 2008-04-23 76
4cfac2f9c7f116 arch/powerpc/include/asm/fixmap.h Christophe Leroy 2017-08-02 @77 static inline void __set_fixmap(enum fixed_addresses idx,
4cfac2f9c7f116 arch/powerpc/include/asm/fixmap.h Christophe Leroy 2017-08-02 78 phys_addr_t phys, pgprot_t flags)
4cfac2f9c7f116 arch/powerpc/include/asm/fixmap.h Christophe Leroy 2017-08-02 79 {
c766ee72235d09 arch/powerpc/include/asm/fixmap.h Christophe Leroy 2018-10-09 80 map_kernel_page(fix_to_virt(idx), phys, flags);
4cfac2f9c7f116 arch/powerpc/include/asm/fixmap.h Christophe Leroy 2017-08-02 81 }
4cfac2f9c7f116 arch/powerpc/include/asm/fixmap.h Christophe Leroy 2017-08-02 82

:::::: The code at line 77 was first introduced by commit
:::::: 4cfac2f9c7f116af8516d0b3d0e7383189eca376 powerpc/mm: Simplify __set_fixmap()

:::::: TO: Christophe Leroy <christophe.leroy@xxxxxx>
:::::: CC: Michael Ellerman <mpe@xxxxxxxxxxxxxx>

---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx Intel Corporation

Attachment: .config.gz
Description: application/gzip