[<prev] [next>] [day] [month] [year] [list]
Message-ID: <202008111703.yZg3Boam%lkp@intel.com>
Date: Tue, 11 Aug 2020 17:17:10 +0800
From: kernel test robot <lkp@...el.com>
To: Andrew Murray <andrew.murray@....com>
Cc: kbuild-all@...ts.01.org, linux-kernel@...r.kernel.org,
Will Deacon <will@...nel.org>
Subject: include/linux/rwlock_api_smp.h:226:9: sparse: sparse: context
imbalance in 'raw_seq_stop' - unexpected unlock
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 00e4db51259a5f936fec1424b884f029479d3981
commit: addfc38672c73efd5c4e559a2e455b086e3e20c5 arm64: atomics: avoid out-of-line ll/sc atomics
date: 12 months ago
config: arm64-randconfig-s032-20200811 (attached as .config)
compiler: aarch64-linux-gcc (GCC) 9.3.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# apt-get install sparse
# sparse version: v0.6.2-168-g9554805c-dirty
git checkout addfc38672c73efd5c4e559a2e455b086e3e20c5
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=arm64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@...el.com>
sparse warnings: (new ones prefixed by >>)
net/ipv4/raw.c: note: in included file (through include/net/checksum.h, include/linux/skbuff.h, include/linux/pim.h, ...):
arch/arm64/include/asm/checksum.h:34:27: sparse: sparse: incorrect type in argument 1 (different base types) @@ expected restricted __wsum [usertype] csum @@ got unsigned int [usertype] @@
arch/arm64/include/asm/checksum.h:34:27: sparse: expected restricted __wsum [usertype] csum
arch/arm64/include/asm/checksum.h:34:27: sparse: got unsigned int [usertype]
net/ipv4/raw.c:1041:21: sparse: sparse: context imbalance in 'raw_seq_start' - wrong count at exit
net/ipv4/raw.c: note: in included file (through include/linux/spinlock_api_smp.h, include/linux/spinlock.h, include/linux/wait.h, ...):
>> include/linux/rwlock_api_smp.h:226:9: sparse: sparse: context imbalance in 'raw_seq_stop' - unexpected unlock
--
net/ipv6/anycast.c: note: in included file (through include/linux/spinlock_api_smp.h, include/linux/spinlock.h, include/linux/seqlock.h, ...):
>> include/linux/rwlock_api_smp.h:250:9: sparse: sparse: context imbalance in 'ac6_get_next' - unexpected unlock
net/ipv6/anycast.c:530:9: sparse: sparse: context imbalance in 'ac6_get_idx' - wrong count at exit
net/ipv6/anycast.c: note: in included file (through include/linux/rbtree.h, include/linux/mm_types.h, include/linux/mmzone.h, ...):
include/linux/rcupdate.h:644:9: sparse: sparse: context imbalance in 'ac6_seq_stop' - unexpected unlock
--
net/ipv6/mcast.c:259:25: sparse: sparse: context imbalance in 'ip6_mc_find_dev_rcu' - different lock contexts for basic block
net/ipv6/mcast.c: note: in included file (through include/linux/spinlock_api_smp.h, include/linux/spinlock.h, include/linux/seqlock.h, ...):
>> include/linux/rwlock_api_smp.h:250:9: sparse: sparse: context imbalance in 'ip6_mc_source' - unexpected unlock
>> include/linux/rwlock_api_smp.h:250:9: sparse: sparse: context imbalance in 'ip6_mc_msfilter' - unexpected unlock
>> include/linux/rwlock_api_smp.h:250:9: sparse: sparse: context imbalance in 'ip6_mc_msfget' - unexpected unlock
>> include/linux/rwlock_api_smp.h:250:9: sparse: sparse: context imbalance in 'igmp6_mc_get_next' - unexpected unlock
net/ipv6/mcast.c:2725:9: sparse: sparse: context imbalance in 'igmp6_mc_get_idx' - wrong count at exit
net/ipv6/mcast.c:2752:9: sparse: sparse: context imbalance in 'igmp6_mc_seq_stop' - unexpected unlock
net/ipv6/mcast.c:2824:31: sparse: sparse: context imbalance in 'igmp6_mcf_get_next' - unexpected unlock
net/ipv6/mcast.c:2856:9: sparse: sparse: context imbalance in 'igmp6_mcf_get_idx' - wrong count at exit
net/ipv6/mcast.c:2873:9: sparse: sparse: context imbalance in 'igmp6_mcf_seq_next' - wrong count at exit
>> include/linux/rwlock_api_smp.h:250:9: sparse: sparse: context imbalance in 'igmp6_mcf_seq_stop' - unexpected unlock
--
fs/btrfs/locking.c: note: in included file (through include/linux/spinlock_api_smp.h, include/linux/spinlock.h, include/linux/wait.h, ...):
>> include/linux/rwlock_api_smp.h:226:9: sparse: sparse: context imbalance in 'btrfs_set_lock_blocking_read' - unexpected unlock
fs/btrfs/locking.c:115:17: sparse: sparse: context imbalance in 'btrfs_set_lock_blocking_write' - unexpected unlock
fs/btrfs/locking.c:122:6: sparse: sparse: context imbalance in 'btrfs_clear_lock_blocking_read' - different lock contexts for basic block
fs/btrfs/locking.c:140:6: sparse: sparse: context imbalance in 'btrfs_clear_lock_blocking_write' - different lock contexts for basic block
fs/btrfs/locking.c:162:6: sparse: sparse: context imbalance in 'btrfs_tree_read_lock' - different lock contexts for basic block
fs/btrfs/locking.c:201:5: sparse: sparse: context imbalance in 'btrfs_tree_read_lock_atomic' - different lock contexts for basic block
fs/btrfs/locking.c:221:5: sparse: sparse: context imbalance in 'btrfs_try_tree_read_lock' - different lock contexts for basic block
fs/btrfs/locking.c:243:5: sparse: sparse: context imbalance in 'btrfs_try_tree_write_lock' - different lock contexts for basic block
>> include/linux/rwlock_api_smp.h:226:9: sparse: sparse: context imbalance in 'btrfs_tree_read_unlock' - unexpected unlock
fs/btrfs/locking.c:326:9: sparse: sparse: context imbalance in 'btrfs_tree_lock' - wrong count at exit
fs/btrfs/locking.c:356:17: sparse: sparse: context imbalance in 'btrfs_tree_unlock' - unexpected unlock
vim +/raw_seq_stop +226 include/linux/rwlock_api_smp.h
6b6b4792f89346 Thomas Gleixner 2009-11-16 222
9c1721aa4994f6 Thomas Gleixner 2009-12-03 223 static inline void __raw_read_unlock(rwlock_t *lock)
6b6b4792f89346 Thomas Gleixner 2009-11-16 224 {
6b6b4792f89346 Thomas Gleixner 2009-11-16 225 rwlock_release(&lock->dep_map, 1, _RET_IP_);
9828ea9d75c38f Thomas Gleixner 2009-12-03 @226 do_raw_read_unlock(lock);
6b6b4792f89346 Thomas Gleixner 2009-11-16 227 preempt_enable();
6b6b4792f89346 Thomas Gleixner 2009-11-16 228 }
6b6b4792f89346 Thomas Gleixner 2009-11-16 229
9c1721aa4994f6 Thomas Gleixner 2009-12-03 230 static inline void
9c1721aa4994f6 Thomas Gleixner 2009-12-03 231 __raw_read_unlock_irqrestore(rwlock_t *lock, unsigned long flags)
6b6b4792f89346 Thomas Gleixner 2009-11-16 232 {
6b6b4792f89346 Thomas Gleixner 2009-11-16 233 rwlock_release(&lock->dep_map, 1, _RET_IP_);
9828ea9d75c38f Thomas Gleixner 2009-12-03 234 do_raw_read_unlock(lock);
6b6b4792f89346 Thomas Gleixner 2009-11-16 235 local_irq_restore(flags);
6b6b4792f89346 Thomas Gleixner 2009-11-16 236 preempt_enable();
6b6b4792f89346 Thomas Gleixner 2009-11-16 237 }
6b6b4792f89346 Thomas Gleixner 2009-11-16 238
9c1721aa4994f6 Thomas Gleixner 2009-12-03 239 static inline void __raw_read_unlock_irq(rwlock_t *lock)
6b6b4792f89346 Thomas Gleixner 2009-11-16 240 {
6b6b4792f89346 Thomas Gleixner 2009-11-16 241 rwlock_release(&lock->dep_map, 1, _RET_IP_);
9828ea9d75c38f Thomas Gleixner 2009-12-03 242 do_raw_read_unlock(lock);
6b6b4792f89346 Thomas Gleixner 2009-11-16 243 local_irq_enable();
6b6b4792f89346 Thomas Gleixner 2009-11-16 244 preempt_enable();
6b6b4792f89346 Thomas Gleixner 2009-11-16 245 }
6b6b4792f89346 Thomas Gleixner 2009-11-16 246
9c1721aa4994f6 Thomas Gleixner 2009-12-03 247 static inline void __raw_read_unlock_bh(rwlock_t *lock)
6b6b4792f89346 Thomas Gleixner 2009-11-16 248 {
6b6b4792f89346 Thomas Gleixner 2009-11-16 249 rwlock_release(&lock->dep_map, 1, _RET_IP_);
9828ea9d75c38f Thomas Gleixner 2009-12-03 @250 do_raw_read_unlock(lock);
9ea4c380066fbe Peter Zijlstra 2013-11-19 251 __local_bh_enable_ip(_RET_IP_, SOFTIRQ_LOCK_OFFSET);
6b6b4792f89346 Thomas Gleixner 2009-11-16 252 }
6b6b4792f89346 Thomas Gleixner 2009-11-16 253
:::::: The code at line 226 was first introduced by commit
:::::: 9828ea9d75c38fe3dce05d00566eed61c85732e6 locking: Further name space cleanups
:::::: TO: Thomas Gleixner <tglx@...utronix.de>
:::::: CC: Thomas Gleixner <tglx@...utronix.de>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
Download attachment ".config.gz" of type "application/gzip" (35313 bytes)
Powered by blists - more mailing lists