All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: ycaibb <ycaibb@gmail.com>,
	davem@davemloft.net, yoshfuji@linux-ipv6.org, dsahern@kernel.org,
	kuba@kernel.org
Cc: llvm@lists.linux.dev, kbuild-all@lists.01.org,
	netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
	ycaibb@gmail.com
Subject: Re: [PATCH] net: missing lock releases in ipmr_base.c
Date: Fri, 21 Jan 2022 16:08:43 +0800	[thread overview]
Message-ID: <202201211524.XaQUNPO4-lkp@intel.com> (raw)
In-Reply-To: <20220121032210.5829-1-ycaibb@gmail.com>

Hi ycaibb,

Thank you for the patch! Perhaps something to improve:

[auto build test WARNING on net-next/master]
[also build test WARNING on net/master horms-ipvs/master linus/master v5.16 next-20220121]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]

url:    https://github.com/0day-ci/linux/commits/ycaibb/net-missing-lock-releases-in-ipmr_base-c/20220121-112603
base:   https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git 8aaaf2f3af2ae212428f4db1af34214225f5cec3
config: mips-bmips_stb_defconfig (https://download.01.org/0day-ci/archive/20220121/202201211524.XaQUNPO4-lkp@intel.com/config)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project d4baf3b1322b84816aa623d8e8cb45a49cb68b84)
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/0day-ci/linux/commit/33b03feacaf2155323b031274d2d67dab0cf561c
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review ycaibb/net-missing-lock-releases-in-ipmr_base-c/20220121-112603
        git checkout 33b03feacaf2155323b031274d2d67dab0cf561c
        # save the config file to linux build tree
        mkdir build_dir
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=mips SHELL=/bin/bash net/ipv4/

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 >>):

>> net/ipv4/ipmr_base.c:158:4: warning: misleading indentation; statement is not part of the previous 'if' [-Wmisleading-indentation]
                           return mfc;
                           ^
   net/ipv4/ipmr_base.c:156:3: note: previous statement is here
                   if (pos-- == 0)
                   ^
   net/ipv4/ipmr_base.c:166:4: warning: misleading indentation; statement is not part of the previous 'if' [-Wmisleading-indentation]
                           return mfc;
                           ^
   net/ipv4/ipmr_base.c:164:3: note: previous statement is here
                   if (pos-- == 0)
                   ^
   2 warnings generated.


vim +/if +158 net/ipv4/ipmr_base.c

3feda6b46f7347 Yuval Mintz 2018-02-28  146  
c8d61968032654 Yuval Mintz 2018-02-28  147  void *mr_mfc_seq_idx(struct net *net,
c8d61968032654 Yuval Mintz 2018-02-28  148  		     struct mr_mfc_iter *it, loff_t pos)
c8d61968032654 Yuval Mintz 2018-02-28  149  {
c8d61968032654 Yuval Mintz 2018-02-28  150  	struct mr_table *mrt = it->mrt;
c8d61968032654 Yuval Mintz 2018-02-28  151  	struct mr_mfc *mfc;
c8d61968032654 Yuval Mintz 2018-02-28  152  
c8d61968032654 Yuval Mintz 2018-02-28  153  	rcu_read_lock();
c8d61968032654 Yuval Mintz 2018-02-28  154  	it->cache = &mrt->mfc_cache_list;
c8d61968032654 Yuval Mintz 2018-02-28  155  	list_for_each_entry_rcu(mfc, &mrt->mfc_cache_list, list)
c8d61968032654 Yuval Mintz 2018-02-28  156  		if (pos-- == 0)
33b03feacaf215 Ryan Cai    2022-01-21  157  			rcu_read_unlock();
c8d61968032654 Yuval Mintz 2018-02-28 @158  			return mfc;
c8d61968032654 Yuval Mintz 2018-02-28  159  	rcu_read_unlock();
c8d61968032654 Yuval Mintz 2018-02-28  160  
c8d61968032654 Yuval Mintz 2018-02-28  161  	spin_lock_bh(it->lock);
c8d61968032654 Yuval Mintz 2018-02-28  162  	it->cache = &mrt->mfc_unres_queue;
c8d61968032654 Yuval Mintz 2018-02-28  163  	list_for_each_entry(mfc, it->cache, list)
c8d61968032654 Yuval Mintz 2018-02-28  164  		if (pos-- == 0)
33b03feacaf215 Ryan Cai    2022-01-21  165  			spin_unlock_bh(it->lock);
c8d61968032654 Yuval Mintz 2018-02-28  166  			return mfc;
c8d61968032654 Yuval Mintz 2018-02-28  167  	spin_unlock_bh(it->lock);
c8d61968032654 Yuval Mintz 2018-02-28  168  
c8d61968032654 Yuval Mintz 2018-02-28  169  	it->cache = NULL;
c8d61968032654 Yuval Mintz 2018-02-28  170  	return NULL;
c8d61968032654 Yuval Mintz 2018-02-28  171  }
c8d61968032654 Yuval Mintz 2018-02-28  172  EXPORT_SYMBOL(mr_mfc_seq_idx);
c8d61968032654 Yuval Mintz 2018-02-28  173  

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

WARNING: multiple messages have this Message-ID (diff)
From: kernel test robot <lkp@intel.com>
To: kbuild-all@lists.01.org
Subject: Re: [PATCH] net: missing lock releases in ipmr_base.c
Date: Fri, 21 Jan 2022 16:08:43 +0800	[thread overview]
Message-ID: <202201211524.XaQUNPO4-lkp@intel.com> (raw)
In-Reply-To: <20220121032210.5829-1-ycaibb@gmail.com>

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

Hi ycaibb,

Thank you for the patch! Perhaps something to improve:

[auto build test WARNING on net-next/master]
[also build test WARNING on net/master horms-ipvs/master linus/master v5.16 next-20220121]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]

url:    https://github.com/0day-ci/linux/commits/ycaibb/net-missing-lock-releases-in-ipmr_base-c/20220121-112603
base:   https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git 8aaaf2f3af2ae212428f4db1af34214225f5cec3
config: mips-bmips_stb_defconfig (https://download.01.org/0day-ci/archive/20220121/202201211524.XaQUNPO4-lkp(a)intel.com/config)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project d4baf3b1322b84816aa623d8e8cb45a49cb68b84)
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/0day-ci/linux/commit/33b03feacaf2155323b031274d2d67dab0cf561c
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review ycaibb/net-missing-lock-releases-in-ipmr_base-c/20220121-112603
        git checkout 33b03feacaf2155323b031274d2d67dab0cf561c
        # save the config file to linux build tree
        mkdir build_dir
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=mips SHELL=/bin/bash net/ipv4/

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 >>):

>> net/ipv4/ipmr_base.c:158:4: warning: misleading indentation; statement is not part of the previous 'if' [-Wmisleading-indentation]
                           return mfc;
                           ^
   net/ipv4/ipmr_base.c:156:3: note: previous statement is here
                   if (pos-- == 0)
                   ^
   net/ipv4/ipmr_base.c:166:4: warning: misleading indentation; statement is not part of the previous 'if' [-Wmisleading-indentation]
                           return mfc;
                           ^
   net/ipv4/ipmr_base.c:164:3: note: previous statement is here
                   if (pos-- == 0)
                   ^
   2 warnings generated.


vim +/if +158 net/ipv4/ipmr_base.c

3feda6b46f7347 Yuval Mintz 2018-02-28  146  
c8d61968032654 Yuval Mintz 2018-02-28  147  void *mr_mfc_seq_idx(struct net *net,
c8d61968032654 Yuval Mintz 2018-02-28  148  		     struct mr_mfc_iter *it, loff_t pos)
c8d61968032654 Yuval Mintz 2018-02-28  149  {
c8d61968032654 Yuval Mintz 2018-02-28  150  	struct mr_table *mrt = it->mrt;
c8d61968032654 Yuval Mintz 2018-02-28  151  	struct mr_mfc *mfc;
c8d61968032654 Yuval Mintz 2018-02-28  152  
c8d61968032654 Yuval Mintz 2018-02-28  153  	rcu_read_lock();
c8d61968032654 Yuval Mintz 2018-02-28  154  	it->cache = &mrt->mfc_cache_list;
c8d61968032654 Yuval Mintz 2018-02-28  155  	list_for_each_entry_rcu(mfc, &mrt->mfc_cache_list, list)
c8d61968032654 Yuval Mintz 2018-02-28  156  		if (pos-- == 0)
33b03feacaf215 Ryan Cai    2022-01-21  157  			rcu_read_unlock();
c8d61968032654 Yuval Mintz 2018-02-28 @158  			return mfc;
c8d61968032654 Yuval Mintz 2018-02-28  159  	rcu_read_unlock();
c8d61968032654 Yuval Mintz 2018-02-28  160  
c8d61968032654 Yuval Mintz 2018-02-28  161  	spin_lock_bh(it->lock);
c8d61968032654 Yuval Mintz 2018-02-28  162  	it->cache = &mrt->mfc_unres_queue;
c8d61968032654 Yuval Mintz 2018-02-28  163  	list_for_each_entry(mfc, it->cache, list)
c8d61968032654 Yuval Mintz 2018-02-28  164  		if (pos-- == 0)
33b03feacaf215 Ryan Cai    2022-01-21  165  			spin_unlock_bh(it->lock);
c8d61968032654 Yuval Mintz 2018-02-28  166  			return mfc;
c8d61968032654 Yuval Mintz 2018-02-28  167  	spin_unlock_bh(it->lock);
c8d61968032654 Yuval Mintz 2018-02-28  168  
c8d61968032654 Yuval Mintz 2018-02-28  169  	it->cache = NULL;
c8d61968032654 Yuval Mintz 2018-02-28  170  	return NULL;
c8d61968032654 Yuval Mintz 2018-02-28  171  }
c8d61968032654 Yuval Mintz 2018-02-28  172  EXPORT_SYMBOL(mr_mfc_seq_idx);
c8d61968032654 Yuval Mintz 2018-02-28  173  

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

  parent reply	other threads:[~2022-01-21  8:09 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-21  3:22 [PATCH] net: missing lock releases in ipmr_base.c ycaibb
2022-01-21  7:58 ` kernel test robot
2022-01-21  7:58   ` kernel test robot
2022-01-21  8:08 ` kernel test robot [this message]
2022-01-21  8:08   ` kernel test robot
2022-01-21 16:13 ` Stephen Hemminger
2022-01-27  8:35 ` [net] 33b03feaca: BUG:KASAN:slab-out-of-bounds_in_ip6_string kernel test robot
2022-01-27  8:35   ` kernel test robot

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=202201211524.XaQUNPO4-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=davem@davemloft.net \
    --cc=dsahern@kernel.org \
    --cc=kbuild-all@lists.01.org \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=llvm@lists.linux.dev \
    --cc=netdev@vger.kernel.org \
    --cc=ycaibb@gmail.com \
    --cc=yoshfuji@linux-ipv6.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 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.