public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Borislav Petkov <bp@suse.de>
Cc: kbuild-all@lists.01.org, linux-kernel@vger.kernel.org,
	Ingo Molnar <mingo@kernel.org>
Subject: include/asm-generic/atomic-instrumented.h:193:29: sparse: sparse: context imbalance in 'dn_socket_seq_next' - unexpected unlock
Date: Wed, 2 Sep 2020 22:19:05 +0800	[thread overview]
Message-ID: <202009022254.UI6rWM4D%lkp@intel.com> (raw)

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

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   9c7d619be5a002ea29c172df5e3c1227c22cbb41
commit: a4654e9bde4ecedb4921e6c8fe2088114bdff1b3 Merge branch 'x86/kdump' into locking/kcsan, to resolve conflicts
date:   6 months ago
config: arm64-randconfig-s031-20200902 (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-191-g10164920-dirty
        git checkout a4654e9bde4ecedb4921e6c8fe2088114bdff1b3
        # 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@intel.com>


sparse warnings: (new ones prefixed by >>)

   net/decnet/af_decnet.c:249:22: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned int hash @@     got restricted __le16 [usertype] sdn_objnamel @@
   net/decnet/af_decnet.c:249:22: sparse:     expected unsigned int hash
   net/decnet/af_decnet.c:249:22: sparse:     got restricted __le16 [usertype] sdn_objnamel
   net/decnet/af_decnet.c: note: in included file:
   include/net/dn.h:192:24: sparse: sparse: incorrect type in assignment (different base types) @@     expected restricted __be16 [usertype] sport @@     got restricted __le16 [usertype] addrloc @@
   include/net/dn.h:192:24: sparse:     expected restricted __be16 [usertype] sport
   include/net/dn.h:192:24: sparse:     got restricted __le16 [usertype] addrloc
   include/net/dn.h:193:24: sparse: sparse: incorrect type in assignment (different base types) @@     expected restricted __be16 [usertype] dport @@     got restricted __le16 [usertype] addrrem @@
   include/net/dn.h:193:24: sparse:     expected restricted __be16 [usertype] dport
   include/net/dn.h:193:24: sparse:     got restricted __le16 [usertype] addrrem
   net/decnet/af_decnet.c:2159:13: sparse: sparse: context imbalance in 'dn_socket_get_idx' - wrong count at exit
   net/decnet/af_decnet.c: note: in included file (through arch/arm64/include/asm/atomic.h, include/linux/atomic.h, include/asm-generic/bitops/atomic.h, ...):
>> include/asm-generic/atomic-instrumented.h:193:29: sparse: sparse: context imbalance in 'dn_socket_seq_next' - unexpected unlock
>> include/asm-generic/atomic-instrumented.h:193:29: sparse: sparse: context imbalance in 'dn_socket_seq_stop' - unexpected unlock

# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=a4654e9bde4ecedb4921e6c8fe2088114bdff1b3
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout a4654e9bde4ecedb4921e6c8fe2088114bdff1b3
vim +/dn_socket_seq_next +193 include/asm-generic/atomic-instrumented.h

aa525d063851a9 Mark Rutland 2018-09-04  188  
aa525d063851a9 Mark Rutland 2018-09-04  189  #if defined(arch_atomic_sub_return_release)
c020395b6634b7 Marco Elver  2019-11-26  190  static __always_inline int
aa525d063851a9 Mark Rutland 2018-09-04  191  atomic_sub_return_release(int i, atomic_t *v)
aa525d063851a9 Mark Rutland 2018-09-04  192  {
e75a6795ed132f Marco Elver  2019-11-14 @193  	__atomic_check_write(v, sizeof(*v));
aa525d063851a9 Mark Rutland 2018-09-04  194  	return arch_atomic_sub_return_release(i, v);
aa525d063851a9 Mark Rutland 2018-09-04  195  }
aa525d063851a9 Mark Rutland 2018-09-04  196  #define atomic_sub_return_release atomic_sub_return_release
aa525d063851a9 Mark Rutland 2018-09-04  197  #endif
aa525d063851a9 Mark Rutland 2018-09-04  198  

:::::: The code at line 193 was first introduced by commit
:::::: e75a6795ed132f26f69d08dea958630d5993056d locking/atomics, kcsan: Add KCSAN instrumentation

:::::: TO: Marco Elver <elver@google.com>
:::::: CC: Paul E. McKenney <paulmck@kernel.org>

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

                 reply	other threads:[~2020-09-02 14:40 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=202009022254.UI6rWM4D%lkp@intel.com \
    --to=lkp@intel.com \
    --cc=bp@suse.de \
    --cc=kbuild-all@lists.01.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox