All of lore.kernel.org
 help / color / mirror / Atom feed
* [norov:find_bit_static 8/8] include/asm-generic/bitops/le.h:49:13: error: implicit declaration of function 'swap'
@ 2021-01-25 12:43 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2021-01-25 12:43 UTC (permalink / raw)
  To: kbuild-all

[-- Attachment #1: Type: text/plain, Size: 7728 bytes --]

tree:   https://github.com/norov/linux find_bit_static
head:   9647d9f4cd1b259c620e06337010396d5a324f79
commit: 9647d9f4cd1b259c620e06337010396d5a324f79 [8/8] fix next
config: mips-randconfig-r031-20210125 (attached as .config)
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project 12d0753aca22896fda2cf76781b0ee0524d55065)
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
        # install mips cross compiling tool for clang build
        # apt-get install binutils-mips-linux-gnu
        # https://github.com/norov/linux/commit/9647d9f4cd1b259c620e06337010396d5a324f79
        git remote add norov https://github.com/norov/linux
        git fetch --no-tags norov find_bit_static
        git checkout 9647d9f4cd1b259c620e06337010396d5a324f79
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=mips 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

All errors (new ones prefixed by >>):

   In file included from kernel/bounds.c:10:
   In file included from include/linux/page-flags.h:10:
   In file included from include/linux/bug.h:5:
   In file included from arch/mips/include/asm/bug.h:42:
   In file included from include/asm-generic/bug.h:20:
   In file included from include/linux/kernel.h:11:
   In file included from include/linux/bitops.h:50:
   In file included from arch/mips/include/asm/bitops.h:458:
   include/asm-generic/bitops/le.h:45:15: error: invalid operands to binary expression ('const void' and 'unsigned long')
                   val = *addr | ~BITMAP_FIRST_WORD_MASK(offset);
                         ~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> include/asm-generic/bitops/le.h:49:13: error: implicit declaration of function 'swap' [-Werror,-Wimplicit-function-declaration]
                   idx = ffz(swap(val));
                             ^
   include/asm-generic/bitops/le.h:69:15: error: invalid operands to binary expression ('const void' and 'unsigned long')
                   val = *addr & BITMAP_FIRST_WORD_MASK(offset)
                         ~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   3 errors generated.
--
   In file included from kernel//locking/test-ww_mutex.c:6:
   In file included from include/linux/kernel.h:11:
   In file included from include/linux/bitops.h:50:
   In file included from arch/mips/include/asm/bitops.h:458:
   include/asm-generic/bitops/le.h:45:15: error: invalid operands to binary expression ('const void' and 'unsigned long')
                   val = *addr | ~BITMAP_FIRST_WORD_MASK(offset);
                         ~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> include/asm-generic/bitops/le.h:49:13: error: implicit declaration of function 'swap' [-Werror,-Wimplicit-function-declaration]
                   idx = ffz(swap(val));
                             ^
   include/asm-generic/bitops/le.h:69:15: error: invalid operands to binary expression ('const void' and 'unsigned long')
                   val = *addr & BITMAP_FIRST_WORD_MASK(offset)
                         ~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   In file included from kernel//locking/test-ww_mutex.c:11:
   In file included from include/linux/module.h:16:
   In file included from include/linux/kmod.h:9:
   In file included from include/linux/umh.h:4:
   In file included from include/linux/gfp.h:6:
   In file included from include/linux/mmzone.h:19:
   include/linux/page-flags-layout.h:6:10: fatal error: 'generated/bounds.h' file not found
   #include <generated/bounds.h>
            ^~~~~~~~~~~~~~~~~~~~
   4 errors generated.
--
   In file included from kernel/bounds.c:10:
   In file included from include/linux/page-flags.h:10:
   In file included from include/linux/bug.h:5:
   In file included from arch/mips/include/asm/bug.h:42:
   In file included from include/asm-generic/bug.h:20:
   In file included from include/linux/kernel.h:11:
   In file included from include/linux/bitops.h:50:
   In file included from arch/mips/include/asm/bitops.h:458:
   include/asm-generic/bitops/le.h:45:15: error: invalid operands to binary expression ('const void' and 'unsigned long')
                   val = *addr | ~BITMAP_FIRST_WORD_MASK(offset);
                         ~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> include/asm-generic/bitops/le.h:49:13: error: implicit declaration of function 'swap' [-Werror,-Wimplicit-function-declaration]
                   idx = ffz(swap(val));
                             ^
   include/asm-generic/bitops/le.h:69:15: error: invalid operands to binary expression ('const void' and 'unsigned long')
                   val = *addr & BITMAP_FIRST_WORD_MASK(offset)
                         ~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   3 errors generated.
   make[2]: *** [scripts/Makefile.build:117: kernel/bounds.s] Error 1
   make[2]: Target '__build' not remade because of errors.
   make[1]: *** [Makefile:1220: prepare0] Error 2
   make[1]: Target 'modules_prepare' not remade because of errors.
   make: *** [Makefile:185: __sub-make] Error 2
   make: Target 'modules_prepare' not remade because of errors.
--
   In file included from kernel/bounds.c:10:
   In file included from include/linux/page-flags.h:10:
   In file included from include/linux/bug.h:5:
   In file included from arch/mips/include/asm/bug.h:42:
   In file included from include/asm-generic/bug.h:20:
   In file included from include/linux/kernel.h:11:
   In file included from include/linux/bitops.h:50:
   In file included from arch/mips/include/asm/bitops.h:458:
   include/asm-generic/bitops/le.h:45:15: error: invalid operands to binary expression ('const void' and 'unsigned long')
                   val = *addr | ~BITMAP_FIRST_WORD_MASK(offset);
                         ~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> include/asm-generic/bitops/le.h:49:13: error: implicit declaration of function 'swap' [-Werror,-Wimplicit-function-declaration]
                   idx = ffz(swap(val));
                             ^
   include/asm-generic/bitops/le.h:69:15: error: invalid operands to binary expression ('const void' and 'unsigned long')
                   val = *addr & BITMAP_FIRST_WORD_MASK(offset)
                         ~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   3 errors generated.
   make[2]: *** [scripts/Makefile.build:117: kernel/bounds.s] Error 1
   make[2]: Target '__build' not remade because of errors.
   make[1]: *** [Makefile:1220: prepare0] Error 2
   make[1]: Target 'prepare' not remade because of errors.
   make: *** [Makefile:185: __sub-make] Error 2
   make: Target 'prepare' not remade because of errors.


vim +/swap +49 include/asm-generic/bitops/le.h

    33	
    34	#ifndef find_next_zero_bit_le
    35	static __always_inline
    36	unsigned long find_next_zero_bit_le(const void *addr, unsigned
    37			long size, unsigned long offset)
    38	{
    39		if (small_const_nbits(size)) {
    40			unsigned long val, idx;
    41	
    42			if (unlikely(offset >= size))
    43				return size;
    44	
    45			val = *addr | ~BITMAP_FIRST_WORD_MASK(offset);
    46			if (val == ~0UL)
    47				return size;
    48	
  > 49			idx = ffz(swap(val));
    50	
    51			return idx < size ? idx : size;
    52		}
    53	
    54		return _find_next_bit(addr, NULL, size, offset, ~0UL, 1);
    55	}
    56	#endif
    57	

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

[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 28346 bytes --]

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

only message in thread, other threads:[~2021-01-25 12:43 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-01-25 12:43 [norov:find_bit_static 8/8] include/asm-generic/bitops/le.h:49:13: error: implicit declaration of function 'swap' kernel test robot

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.