CC: [email protected]
CC: [email protected]
CC: [email protected]
TO: Boqun Feng <[email protected]>
CC: Peter Zijlstra <[email protected]>

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git locking/core
head:   997acaf6b4b59c6a9c259740312a69ea549cc684
commit: 9271a40d2a1429113160ccc4c16150921600bcc1 [1/10] lockdep/selftest: Add 
wait context selftests
:::::: branch date: 2 weeks ago
:::::: commit date: 3 weeks ago
config: powerpc-randconfig-s032-20210205 (attached as .config)
compiler: powerpc64-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.3-215-g0fb77bb6-dirty
        # 
https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git/commit/?id=9271a40d2a1429113160ccc4c16150921600bcc1
        git remote add tip 
https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git
        git fetch --no-tags tip locking/core
        git checkout 9271a40d2a1429113160ccc4c16150921600bcc1
        # 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=powerpc 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <[email protected]>


"sparse warnings: (new ones prefixed by >>)"
   lib/locking-selftest.c:298:1: sparse: sparse: context imbalance in 'AA_spin' 
- wrong count at exit
   lib/locking-selftest.c:300:1: sparse: sparse: context imbalance in 
'AA_wlock' - wrong count at exit
   lib/locking-selftest.c:302:1: sparse: sparse: context imbalance in 
'AA_rlock' - wrong count at exit
   lib/locking-selftest.c:321:13: sparse: sparse: context imbalance in 
'rlock_AA1' - wrong count at exit
   lib/locking-selftest.c:327:13: sparse: sparse: context imbalance in 
'rlock_AA1B' - wrong count at exit
   lib/locking-selftest.c:347:13: sparse: sparse: context imbalance in 
'rlock_AA2' - wrong count at exit
   lib/locking-selftest.c:359:13: sparse: sparse: context imbalance in 
'rlock_AA3' - wrong count at exit
   lib/locking-selftest.c:722:1: sparse: sparse: context imbalance in 
'double_unlock_spin' - unexpected unlock
   lib/locking-selftest.c:724:1: sparse: sparse: context imbalance in 
'double_unlock_wlock' - unexpected unlock
   lib/locking-selftest.c:726:1: sparse: sparse: context imbalance in 
'double_unlock_rlock' - unexpected unlock
   lib/locking-selftest.c:753:1: sparse: sparse: context imbalance in 
'init_held_spin' - wrong count at exit
   lib/locking-selftest.c:755:1: sparse: sparse: context imbalance in 
'init_held_wlock' - wrong count at exit
   lib/locking-selftest.c:757:1: sparse: sparse: context imbalance in 
'init_held_rlock' - wrong count at exit
   lib/locking-selftest.c:2456:13: sparse: sparse: context imbalance in 
'rcu_exit' - unexpected unlock
   lib/locking-selftest.c:2465:13: sparse: sparse: context imbalance in 
'rcu_bh_exit' - unexpected unlock
   lib/locking-selftest.c:2474:13: sparse: sparse: context imbalance in 
'rcu_sched_exit' - unexpected unlock
   lib/locking-selftest.c:2493:13: sparse: sparse: context imbalance in 
'raw_spinlock_exit' - unexpected unlock
   lib/locking-selftest.c:2502:13: sparse: sparse: context imbalance in 
'spinlock_exit' - unexpected unlock
   lib/locking-selftest.c: note: in included file (through 
include/linux/thread_info.h, include/asm-generic/preempt.h, 
arch/powerpc/include/generated/asm/preempt.h, ...):
>> arch/powerpc/include/asm/current.h:20:9: sparse: sparse: context imbalance 
>> in 'RCU_in_HARDIRQ' - wrong count at exit
>> arch/powerpc/include/asm/current.h:20:9: sparse: sparse: context imbalance 
>> in 'RCU_in_NOTTHREADED_HARDIRQ' - wrong count at exit
>> arch/powerpc/include/asm/current.h:20:9: sparse: sparse: context imbalance 
>> in 'RCU_in_SOFTIRQ' - wrong count at exit
   lib/locking-selftest.c:2573:1: sparse: sparse: context imbalance in 
'RCU_in_RCU' - wrong count at exit
   lib/locking-selftest.c:2573:1: sparse: sparse: context imbalance in 
'RCU_in_RCU_BH' - wrong count at exit
   lib/locking-selftest.c:2573:1: sparse: sparse: context imbalance in 
'RCU_in_RCU_CALLBACK' - wrong count at exit
   lib/locking-selftest.c:2573:1: sparse: sparse: context imbalance in 
'RCU_in_RCU_SCHED' - wrong count at exit
   lib/locking-selftest.c:2573:1: sparse: sparse: context imbalance in 
'RCU_in_RAW_SPINLOCK' - wrong count at exit
   lib/locking-selftest.c:2573:1: sparse: sparse: context imbalance in 
'RCU_in_SPINLOCK' - wrong count at exit
   lib/locking-selftest.c:2573:1: sparse: sparse: context imbalance in 
'RCU_in_MUTEX' - wrong count at exit
   arch/powerpc/include/asm/current.h:20:9: sparse: sparse: context imbalance 
in 'RAW_SPINLOCK_in_HARDIRQ' - wrong count at exit
   arch/powerpc/include/asm/current.h:20:9: sparse: sparse: context imbalance 
in 'RAW_SPINLOCK_in_NOTTHREADED_HARDIRQ' - wrong count at exit
   arch/powerpc/include/asm/current.h:20:9: sparse: sparse: context imbalance 
in 'RAW_SPINLOCK_in_SOFTIRQ' - wrong count at exit
   lib/locking-selftest.c:2574:1: sparse: sparse: context imbalance in 
'RAW_SPINLOCK_in_RCU' - wrong count at exit
   lib/locking-selftest.c:2574:1: sparse: sparse: context imbalance in 
'RAW_SPINLOCK_in_RCU_BH' - wrong count at exit
   lib/locking-selftest.c:2574:1: sparse: sparse: context imbalance in 
'RAW_SPINLOCK_in_RCU_CALLBACK' - wrong count at exit
   lib/locking-selftest.c:2574:1: sparse: sparse: context imbalance in 
'RAW_SPINLOCK_in_RCU_SCHED' - wrong count at exit
   lib/locking-selftest.c:2574:1: sparse: sparse: context imbalance in 
'RAW_SPINLOCK_in_RAW_SPINLOCK' - wrong count at exit
   lib/locking-selftest.c:2574:1: sparse: sparse: context imbalance in 
'RAW_SPINLOCK_in_SPINLOCK' - wrong count at exit
   lib/locking-selftest.c:2574:1: sparse: sparse: context imbalance in 
'RAW_SPINLOCK_in_MUTEX' - wrong count at exit
   arch/powerpc/include/asm/current.h:20:9: sparse: sparse: context imbalance 
in 'SPINLOCK_in_HARDIRQ' - wrong count at exit
   arch/powerpc/include/asm/current.h:20:9: sparse: sparse: context imbalance 
in 'SPINLOCK_in_NOTTHREADED_HARDIRQ' - wrong count at exit
   arch/powerpc/include/asm/current.h:20:9: sparse: sparse: context imbalance 
in 'SPINLOCK_in_SOFTIRQ' - wrong count at exit
   lib/locking-selftest.c:2575:1: sparse: sparse: context imbalance in 
'SPINLOCK_in_RCU' - wrong count at exit
   lib/locking-selftest.c:2575:1: sparse: sparse: context imbalance in 
'SPINLOCK_in_RCU_BH' - wrong count at exit
   lib/locking-selftest.c:2575:1: sparse: sparse: context imbalance in 
'SPINLOCK_in_RCU_CALLBACK' - wrong count at exit
   lib/locking-selftest.c:2575:1: sparse: sparse: context imbalance in 
'SPINLOCK_in_RCU_SCHED' - wrong count at exit
   lib/locking-selftest.c:2575:1: sparse: sparse: context imbalance in 
'SPINLOCK_in_RAW_SPINLOCK' - wrong count at exit
   lib/locking-selftest.c:2575:1: sparse: sparse: context imbalance in 
'SPINLOCK_in_SPINLOCK' - wrong count at exit
   lib/locking-selftest.c:2575:1: sparse: sparse: context imbalance in 
'SPINLOCK_in_MUTEX' - wrong count at exit
   lib/locking-selftest.c:2576:1: sparse: sparse: context imbalance in 
'MUTEX_in_RCU' - wrong count at exit
   lib/locking-selftest.c:2576:1: sparse: sparse: context imbalance in 
'MUTEX_in_RCU_BH' - wrong count at exit
   lib/locking-selftest.c:2576:1: sparse: sparse: context imbalance in 
'MUTEX_in_RCU_SCHED' - wrong count at exit
   lib/locking-selftest.c:2576:1: sparse: sparse: context imbalance in 
'MUTEX_in_RAW_SPINLOCK' - wrong count at exit
   lib/locking-selftest.c:2576:1: sparse: sparse: context imbalance in 
'MUTEX_in_SPINLOCK' - wrong count at exit

vim +/RCU_in_HARDIRQ +20 arch/powerpc/include/asm/current.h

584224e4095d8a include/asm-powerpc/current.h      David Gibson    2005-11-09  
14  
5fe8e8b88e68e5 include/asm-powerpc/current.h      Hugh Dickins    2006-10-31  
15  static inline struct task_struct *get_current(void)
5fe8e8b88e68e5 include/asm-powerpc/current.h      Hugh Dickins    2006-10-31  
16  {
5fe8e8b88e68e5 include/asm-powerpc/current.h      Hugh Dickins    2006-10-31  
17        struct task_struct *task;
5fe8e8b88e68e5 include/asm-powerpc/current.h      Hugh Dickins    2006-10-31  
18  
e354d7dc81d0e8 arch/powerpc/include/asm/current.h Nicholas Piggin 2019-06-13  
19        /* get_current can be cached by the compiler, so no volatile */
e354d7dc81d0e8 arch/powerpc/include/asm/current.h Nicholas Piggin 2019-06-13 
@20        asm ("ld %0,%1(13)"
5fe8e8b88e68e5 include/asm-powerpc/current.h      Hugh Dickins    2006-10-31  
21        : "=r" (task)
5fe8e8b88e68e5 include/asm-powerpc/current.h      Hugh Dickins    2006-10-31  
22        : "i" (offsetof(struct paca_struct, __current)));
5fe8e8b88e68e5 include/asm-powerpc/current.h      Hugh Dickins    2006-10-31  
23  
5fe8e8b88e68e5 include/asm-powerpc/current.h      Hugh Dickins    2006-10-31  
24        return task;
5fe8e8b88e68e5 include/asm-powerpc/current.h      Hugh Dickins    2006-10-31  
25  }
5fe8e8b88e68e5 include/asm-powerpc/current.h      Hugh Dickins    2006-10-31  
26  #define current       get_current()
584224e4095d8a include/asm-powerpc/current.h      David Gibson    2005-11-09  
27  

:::::: The code at line 20 was first introduced by commit
:::::: e354d7dc81d0e81bea33165f381aff1eda45f5d9 powerpc/64: allow compiler to 
cache 'current'

:::::: TO: Nicholas Piggin <[email protected]>
:::::: CC: Michael Ellerman <[email protected]>

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/[email protected]

Attachment: .config.gz
Description: application/gzip

_______________________________________________
kbuild mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to