All of lore.kernel.org
 help / color / mirror / Atom feed
* drivers/iio/accel/adxl372.c:949:3: warning: converting the result of '<<' to a boolean always evaluates to true
@ 2021-01-14 18:19 ` kernel test robot
  0 siblings, 0 replies; 3+ messages in thread
From: kernel test robot @ 2021-01-14 18:19 UTC (permalink / raw)
  To: Stefan Popa
  Cc: kbuild-all, clang-built-linux, linux-kernel, Jonathan Cameron,
	Alexandru Tachici

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

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   65f0d2414b7079556fbbcc070b3d1c9f9587606d
commit: b0fc6783d4ae58f796fb183c40dbc7fa3199d51d iio: accel: adxl372: Add support for FIFO peak mode
date:   4 months ago
config: mips-randconfig-r026-20210114 (attached as .config)
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project 68ff52ffead2ba25cca442778ab19286000daad7)
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://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=b0fc6783d4ae58f796fb183c40dbc7fa3199d51d
        git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
        git fetch --no-tags linus master
        git checkout b0fc6783d4ae58f796fb183c40dbc7fa3199d51d
        # 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 warnings (new ones prefixed by >>):

   In file included from include/linux/interrupt.h:8:
   In file included from include/linux/cpumask.h:13:
   In file included from include/linux/atomic.h:7:
   arch/mips/include/asm/atomic.h:52:1: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
   arch/mips/include/asm/atomic.h:45:9: note: expanded from macro 'ATOMIC_OPS'
           return xchg(&v->counter, n);                                    \
                  ^
   arch/mips/include/asm/cmpxchg.h:102:7: note: expanded from macro 'xchg'
           if (!__SYNC_loongson3_war)                                      \
                ^
   arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
   # define __SYNC_loongson3_war   (1 << 31)
                                      ^
   In file included from drivers/iio/accel/adxl372.c:10:
   In file included from include/linux/interrupt.h:8:
   In file included from include/linux/cpumask.h:13:
   In file included from include/linux/atomic.h:7:
   arch/mips/include/asm/atomic.h:257:1: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
   ATOMIC_SIP_OP(atomic, int, subu, ll, sc)
   ^
   arch/mips/include/asm/atomic.h:251:7: note: expanded from macro 'ATOMIC_SIP_OP'
           if (!__SYNC_loongson3_war)                                      \
                ^
   arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
   # define __SYNC_loongson3_war   (1 << 31)
                                      ^
   In file included from drivers/iio/accel/adxl372.c:10:
   In file included from include/linux/interrupt.h:8:
   In file included from include/linux/cpumask.h:13:
   In file included from include/linux/atomic.h:7:
   arch/mips/include/asm/atomic.h:261:1: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
   ATOMIC_SIP_OP(atomic64, s64, dsubu, lld, scd)
   ^
   arch/mips/include/asm/atomic.h:251:7: note: expanded from macro 'ATOMIC_SIP_OP'
           if (!__SYNC_loongson3_war)                                      \
                ^
   arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
   # define __SYNC_loongson3_war   (1 << 31)
                                      ^
   In file included from drivers/iio/accel/adxl372.c:10:
   In file included from include/linux/interrupt.h:11:
   In file included from include/linux/hardirq.h:5:
   In file included from include/linux/context_tracking_state.h:5:
   In file included from include/linux/percpu.h:7:
   In file included from include/linux/smp.h:15:
   In file included from include/linux/smp_types.h:5:
   include/linux/llist.h:222:9: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
           return xchg(&head->first, NULL);
                  ^
   arch/mips/include/asm/cmpxchg.h:102:7: note: expanded from macro 'xchg'
           if (!__SYNC_loongson3_war)                                      \
                ^
   arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
   # define __SYNC_loongson3_war   (1 << 31)
                                      ^
   In file included from drivers/iio/accel/adxl372.c:10:
   In file included from include/linux/interrupt.h:11:
   In file included from include/linux/hardirq.h:7:
   In file included from include/linux/lockdep.h:27:
   include/linux/debug_locks.h:17:9: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
           return xchg(&debug_locks, 0);
                  ^
   arch/mips/include/asm/cmpxchg.h:102:7: note: expanded from macro 'xchg'
           if (!__SYNC_loongson3_war)                                      \
                ^
   arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
   # define __SYNC_loongson3_war   (1 << 31)
                                      ^
   In file included from drivers/iio/accel/adxl372.c:14:
   In file included from include/linux/spi/spi.h:14:
   In file included from include/linux/scatterlist.h:8:
   In file included from include/linux/mm.h:33:
   In file included from include/linux/pgtable.h:6:
   arch/mips/include/asm/pgtable.h:210:3: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
                   cmpxchg64(&buddy->pte, 0, _PAGE_GLOBAL);
                   ^
   arch/mips/include/asm/cmpxchg.h:220:2: note: expanded from macro 'cmpxchg64'
           cmpxchg((ptr), (o), (n));                                       \
           ^
   arch/mips/include/asm/cmpxchg.h:194:7: note: expanded from macro 'cmpxchg'
           if (!__SYNC_loongson3_war)                                      \
                ^
   arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
   # define __SYNC_loongson3_war   (1 << 31)
                                      ^
   In file included from drivers/iio/accel/adxl372.c:14:
   In file included from include/linux/spi/spi.h:14:
   In file included from include/linux/scatterlist.h:8:
   In file included from include/linux/mm.h:33:
   In file included from include/linux/pgtable.h:6:
   arch/mips/include/asm/pgtable.h:210:3: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
   arch/mips/include/asm/cmpxchg.h:220:2: note: expanded from macro 'cmpxchg64'
           cmpxchg((ptr), (o), (n));                                       \
           ^
   arch/mips/include/asm/cmpxchg.h:204:7: note: expanded from macro 'cmpxchg'
           if (!__SYNC_loongson3_war)                                      \
                ^
   arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
   # define __SYNC_loongson3_war   (1 << 31)
                                      ^
>> drivers/iio/accel/adxl372.c:949:3: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
                   set_mask_bits(&st->int1_bitmask, ADXL372_INT1_MAP_ACT_MSK,
                   ^
   include/linux/bitops.h:269:11: note: expanded from macro 'set_mask_bits'
           } while (cmpxchg(ptr, old__, new__) != old__);          \
                    ^
   arch/mips/include/asm/cmpxchg.h:194:7: note: expanded from macro 'cmpxchg'
           if (!__SYNC_loongson3_war)                                      \
                ^
   arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
   # define __SYNC_loongson3_war   (1 << 31)
                                      ^
>> drivers/iio/accel/adxl372.c:949:3: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
   include/linux/bitops.h:269:11: note: expanded from macro 'set_mask_bits'
           } while (cmpxchg(ptr, old__, new__) != old__);          \
                    ^
   arch/mips/include/asm/cmpxchg.h:204:7: note: expanded from macro 'cmpxchg'
           if (!__SYNC_loongson3_war)                                      \
                ^
   arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
   # define __SYNC_loongson3_war   (1 << 31)
                                      ^
   drivers/iio/accel/adxl372.c:953:3: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
                   set_mask_bits(&st->int1_bitmask, ADXL372_INT1_MAP_INACT_MSK,
                   ^
   include/linux/bitops.h:269:11: note: expanded from macro 'set_mask_bits'
           } while (cmpxchg(ptr, old__, new__) != old__);          \
                    ^
   arch/mips/include/asm/cmpxchg.h:194:7: note: expanded from macro 'cmpxchg'
           if (!__SYNC_loongson3_war)                                      \
                ^
   arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
   # define __SYNC_loongson3_war   (1 << 31)
                                      ^
   drivers/iio/accel/adxl372.c:953:3: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
   include/linux/bitops.h:269:11: note: expanded from macro 'set_mask_bits'
           } while (cmpxchg(ptr, old__, new__) != old__);          \
                    ^
   arch/mips/include/asm/cmpxchg.h:204:7: note: expanded from macro 'cmpxchg'
           if (!__SYNC_loongson3_war)                                      \
                ^
   arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
   # define __SYNC_loongson3_war   (1 << 31)
                                      ^
   16 warnings generated.


vim +949 drivers/iio/accel/adxl372.c

   940	
   941	static int adxl372_write_event_config(struct iio_dev *indio_dev, const struct iio_chan_spec *chan,
   942					      enum iio_event_type type, enum iio_event_direction dir,
   943					      int state)
   944	{
   945		struct adxl372_state *st = iio_priv(indio_dev);
   946	
   947		switch (dir) {
   948		case IIO_EV_DIR_RISING:
 > 949			set_mask_bits(&st->int1_bitmask, ADXL372_INT1_MAP_ACT_MSK,
   950				      ADXL372_INT1_MAP_ACT_MODE(state));
   951			break;
   952		case IIO_EV_DIR_FALLING:
   953			set_mask_bits(&st->int1_bitmask, ADXL372_INT1_MAP_INACT_MSK,
   954				      ADXL372_INT1_MAP_INACT_MODE(state));
   955			break;
   956		default:
   957			return -EINVAL;
   958		}
   959	
   960		return adxl372_set_interrupts(st, st->int1_bitmask, 0);
   961	}
   962	

---
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: 36681 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

* drivers/iio/accel/adxl372.c:949:3: warning: converting the result of '<<' to a boolean always evaluates to true
@ 2021-01-14 18:19 ` kernel test robot
  0 siblings, 0 replies; 3+ messages in thread
From: kernel test robot @ 2021-01-14 18:19 UTC (permalink / raw)
  To: kbuild-all

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

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   65f0d2414b7079556fbbcc070b3d1c9f9587606d
commit: b0fc6783d4ae58f796fb183c40dbc7fa3199d51d iio: accel: adxl372: Add support for FIFO peak mode
date:   4 months ago
config: mips-randconfig-r026-20210114 (attached as .config)
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project 68ff52ffead2ba25cca442778ab19286000daad7)
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://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=b0fc6783d4ae58f796fb183c40dbc7fa3199d51d
        git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
        git fetch --no-tags linus master
        git checkout b0fc6783d4ae58f796fb183c40dbc7fa3199d51d
        # 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 warnings (new ones prefixed by >>):

   In file included from include/linux/interrupt.h:8:
   In file included from include/linux/cpumask.h:13:
   In file included from include/linux/atomic.h:7:
   arch/mips/include/asm/atomic.h:52:1: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
   arch/mips/include/asm/atomic.h:45:9: note: expanded from macro 'ATOMIC_OPS'
           return xchg(&v->counter, n);                                    \
                  ^
   arch/mips/include/asm/cmpxchg.h:102:7: note: expanded from macro 'xchg'
           if (!__SYNC_loongson3_war)                                      \
                ^
   arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
   # define __SYNC_loongson3_war   (1 << 31)
                                      ^
   In file included from drivers/iio/accel/adxl372.c:10:
   In file included from include/linux/interrupt.h:8:
   In file included from include/linux/cpumask.h:13:
   In file included from include/linux/atomic.h:7:
   arch/mips/include/asm/atomic.h:257:1: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
   ATOMIC_SIP_OP(atomic, int, subu, ll, sc)
   ^
   arch/mips/include/asm/atomic.h:251:7: note: expanded from macro 'ATOMIC_SIP_OP'
           if (!__SYNC_loongson3_war)                                      \
                ^
   arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
   # define __SYNC_loongson3_war   (1 << 31)
                                      ^
   In file included from drivers/iio/accel/adxl372.c:10:
   In file included from include/linux/interrupt.h:8:
   In file included from include/linux/cpumask.h:13:
   In file included from include/linux/atomic.h:7:
   arch/mips/include/asm/atomic.h:261:1: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
   ATOMIC_SIP_OP(atomic64, s64, dsubu, lld, scd)
   ^
   arch/mips/include/asm/atomic.h:251:7: note: expanded from macro 'ATOMIC_SIP_OP'
           if (!__SYNC_loongson3_war)                                      \
                ^
   arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
   # define __SYNC_loongson3_war   (1 << 31)
                                      ^
   In file included from drivers/iio/accel/adxl372.c:10:
   In file included from include/linux/interrupt.h:11:
   In file included from include/linux/hardirq.h:5:
   In file included from include/linux/context_tracking_state.h:5:
   In file included from include/linux/percpu.h:7:
   In file included from include/linux/smp.h:15:
   In file included from include/linux/smp_types.h:5:
   include/linux/llist.h:222:9: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
           return xchg(&head->first, NULL);
                  ^
   arch/mips/include/asm/cmpxchg.h:102:7: note: expanded from macro 'xchg'
           if (!__SYNC_loongson3_war)                                      \
                ^
   arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
   # define __SYNC_loongson3_war   (1 << 31)
                                      ^
   In file included from drivers/iio/accel/adxl372.c:10:
   In file included from include/linux/interrupt.h:11:
   In file included from include/linux/hardirq.h:7:
   In file included from include/linux/lockdep.h:27:
   include/linux/debug_locks.h:17:9: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
           return xchg(&debug_locks, 0);
                  ^
   arch/mips/include/asm/cmpxchg.h:102:7: note: expanded from macro 'xchg'
           if (!__SYNC_loongson3_war)                                      \
                ^
   arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
   # define __SYNC_loongson3_war   (1 << 31)
                                      ^
   In file included from drivers/iio/accel/adxl372.c:14:
   In file included from include/linux/spi/spi.h:14:
   In file included from include/linux/scatterlist.h:8:
   In file included from include/linux/mm.h:33:
   In file included from include/linux/pgtable.h:6:
   arch/mips/include/asm/pgtable.h:210:3: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
                   cmpxchg64(&buddy->pte, 0, _PAGE_GLOBAL);
                   ^
   arch/mips/include/asm/cmpxchg.h:220:2: note: expanded from macro 'cmpxchg64'
           cmpxchg((ptr), (o), (n));                                       \
           ^
   arch/mips/include/asm/cmpxchg.h:194:7: note: expanded from macro 'cmpxchg'
           if (!__SYNC_loongson3_war)                                      \
                ^
   arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
   # define __SYNC_loongson3_war   (1 << 31)
                                      ^
   In file included from drivers/iio/accel/adxl372.c:14:
   In file included from include/linux/spi/spi.h:14:
   In file included from include/linux/scatterlist.h:8:
   In file included from include/linux/mm.h:33:
   In file included from include/linux/pgtable.h:6:
   arch/mips/include/asm/pgtable.h:210:3: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
   arch/mips/include/asm/cmpxchg.h:220:2: note: expanded from macro 'cmpxchg64'
           cmpxchg((ptr), (o), (n));                                       \
           ^
   arch/mips/include/asm/cmpxchg.h:204:7: note: expanded from macro 'cmpxchg'
           if (!__SYNC_loongson3_war)                                      \
                ^
   arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
   # define __SYNC_loongson3_war   (1 << 31)
                                      ^
>> drivers/iio/accel/adxl372.c:949:3: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
                   set_mask_bits(&st->int1_bitmask, ADXL372_INT1_MAP_ACT_MSK,
                   ^
   include/linux/bitops.h:269:11: note: expanded from macro 'set_mask_bits'
           } while (cmpxchg(ptr, old__, new__) != old__);          \
                    ^
   arch/mips/include/asm/cmpxchg.h:194:7: note: expanded from macro 'cmpxchg'
           if (!__SYNC_loongson3_war)                                      \
                ^
   arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
   # define __SYNC_loongson3_war   (1 << 31)
                                      ^
>> drivers/iio/accel/adxl372.c:949:3: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
   include/linux/bitops.h:269:11: note: expanded from macro 'set_mask_bits'
           } while (cmpxchg(ptr, old__, new__) != old__);          \
                    ^
   arch/mips/include/asm/cmpxchg.h:204:7: note: expanded from macro 'cmpxchg'
           if (!__SYNC_loongson3_war)                                      \
                ^
   arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
   # define __SYNC_loongson3_war   (1 << 31)
                                      ^
   drivers/iio/accel/adxl372.c:953:3: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
                   set_mask_bits(&st->int1_bitmask, ADXL372_INT1_MAP_INACT_MSK,
                   ^
   include/linux/bitops.h:269:11: note: expanded from macro 'set_mask_bits'
           } while (cmpxchg(ptr, old__, new__) != old__);          \
                    ^
   arch/mips/include/asm/cmpxchg.h:194:7: note: expanded from macro 'cmpxchg'
           if (!__SYNC_loongson3_war)                                      \
                ^
   arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
   # define __SYNC_loongson3_war   (1 << 31)
                                      ^
   drivers/iio/accel/adxl372.c:953:3: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
   include/linux/bitops.h:269:11: note: expanded from macro 'set_mask_bits'
           } while (cmpxchg(ptr, old__, new__) != old__);          \
                    ^
   arch/mips/include/asm/cmpxchg.h:204:7: note: expanded from macro 'cmpxchg'
           if (!__SYNC_loongson3_war)                                      \
                ^
   arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
   # define __SYNC_loongson3_war   (1 << 31)
                                      ^
   16 warnings generated.


vim +949 drivers/iio/accel/adxl372.c

   940	
   941	static int adxl372_write_event_config(struct iio_dev *indio_dev, const struct iio_chan_spec *chan,
   942					      enum iio_event_type type, enum iio_event_direction dir,
   943					      int state)
   944	{
   945		struct adxl372_state *st = iio_priv(indio_dev);
   946	
   947		switch (dir) {
   948		case IIO_EV_DIR_RISING:
 > 949			set_mask_bits(&st->int1_bitmask, ADXL372_INT1_MAP_ACT_MSK,
   950				      ADXL372_INT1_MAP_ACT_MODE(state));
   951			break;
   952		case IIO_EV_DIR_FALLING:
   953			set_mask_bits(&st->int1_bitmask, ADXL372_INT1_MAP_INACT_MSK,
   954				      ADXL372_INT1_MAP_INACT_MODE(state));
   955			break;
   956		default:
   957			return -EINVAL;
   958		}
   959	
   960		return adxl372_set_interrupts(st, st->int1_bitmask, 0);
   961	}
   962	

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

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

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: drivers/iio/accel/adxl372.c:949:3: warning: converting the result of '<<' to a boolean always evaluates to true
  2021-01-14 18:19 ` kernel test robot
  (?)
@ 2021-01-14 18:24 ` Nathan Chancellor
  -1 siblings, 0 replies; 3+ messages in thread
From: Nathan Chancellor @ 2021-01-14 18:24 UTC (permalink / raw)
  To: kernel test robot
  Cc: Stefan Popa, kbuild-all, clang-built-linux, linux-kernel,
	Jonathan Cameron, Alexandru Tachici

On Fri, Jan 15, 2021 at 02:19:41AM +0800, kernel test robot wrote:
> tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
> head:   65f0d2414b7079556fbbcc070b3d1c9f9587606d
> commit: b0fc6783d4ae58f796fb183c40dbc7fa3199d51d iio: accel: adxl372: Add support for FIFO peak mode
> date:   4 months ago
> config: mips-randconfig-r026-20210114 (attached as .config)
> compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project 68ff52ffead2ba25cca442778ab19286000daad7)
> 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://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=b0fc6783d4ae58f796fb183c40dbc7fa3199d51d
>         git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
>         git fetch --no-tags linus master
>         git checkout b0fc6783d4ae58f796fb183c40dbc7fa3199d51d
>         # 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 warnings (new ones prefixed by >>):
> 
>    In file included from include/linux/interrupt.h:8:
>    In file included from include/linux/cpumask.h:13:
>    In file included from include/linux/atomic.h:7:
>    arch/mips/include/asm/atomic.h:52:1: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
>    arch/mips/include/asm/atomic.h:45:9: note: expanded from macro 'ATOMIC_OPS'
>            return xchg(&v->counter, n);                                    \
>                   ^
>    arch/mips/include/asm/cmpxchg.h:102:7: note: expanded from macro 'xchg'
>            if (!__SYNC_loongson3_war)                                      \
>                 ^
>    arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
>    # define __SYNC_loongson3_war   (1 << 31)
>                                       ^

Sorry for the noise, I have sent a patch to fix this:

https://lore.kernel.org/lkml/20210114173416.738455-1-natechancellor@gmail.com/

Cheers,
Nathan

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-01-14 18:25 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-01-14 18:19 drivers/iio/accel/adxl372.c:949:3: warning: converting the result of '<<' to a boolean always evaluates to true kernel test robot
2021-01-14 18:19 ` kernel test robot
2021-01-14 18:24 ` Nathan Chancellor

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.