All of lore.kernel.org
 help / color / mirror / Atom feed
* drivers/infiniband/hw/mlx5/mr.c:234:25: sparse: sparse: context imbalance in 'resize_available_mrs' - unexpected unlock
@ 2020-09-11  5:50 kernel test robot
  0 siblings, 0 replies; 3+ messages in thread
From: kernel test robot @ 2020-09-11  5:50 UTC (permalink / raw)
  To: kbuild

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

CC: kbuild-all(a)lists.01.org
CC: linux-kernel(a)vger.kernel.org
TO: Jason Gunthorpe <jgg@mellanox.com>
CC: Leon Romanovsky <leonro@mellanox.com>

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   581cb3a26baf846ee9636214afaa5333919875b1
commit: a1d8854aae4ee19df6161a276a99d3c9c2abc4f3 RDMA/mlx5: Fix MR cache size and limit debugfs
date:   6 months ago
:::::: branch date: 10 hours ago
:::::: commit date: 6 months ago
config: x86_64-randconfig-s022-20200911 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
reproduce:
        # apt-get install sparse
        # sparse version: v0.6.2-191-g10164920-dirty
        git checkout a1d8854aae4ee19df6161a276a99d3c9c2abc4f3
        # save the attached .config to linux build tree
        make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=x86_64 

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

>> drivers/infiniband/hw/mlx5/mr.c:234:25: sparse: sparse: context imbalance in 'resize_available_mrs' - unexpected unlock

# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=a1d8854aae4ee19df6161a276a99d3c9c2abc4f3
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout a1d8854aae4ee19df6161a276a99d3c9c2abc4f3
vim +/resize_available_mrs +234 drivers/infiniband/hw/mlx5/mr.c

65edd0e758b8a2 Daniel Jurgens  2018-03-13  220  
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  221  static int resize_available_mrs(struct mlx5_cache_ent *ent, unsigned int target,
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  222  				bool limit_fill)
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  223  {
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  224  	int err;
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  225  
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  226  	lockdep_assert_held(&ent->lock);
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  227  
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  228  	while (true) {
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  229  		if (limit_fill)
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  230  			target = ent->limit * 2;
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  231  		if (target == ent->available_mrs + ent->pending)
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  232  			return 0;
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  233  		if (target > ent->available_mrs + ent->pending) {
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10 @234  			u32 todo = target - (ent->available_mrs + ent->pending);
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  235  
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  236  			spin_unlock_irq(&ent->lock);
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  237  			err = add_keys(ent, todo);
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  238  			if (err == -EAGAIN)
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  239  				usleep_range(3000, 5000);
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  240  			spin_lock_irq(&ent->lock);
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  241  			if (err) {
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  242  				if (err != -EAGAIN)
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  243  					return err;
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  244  			} else
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  245  				return 0;
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  246  		} else {
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  247  			spin_unlock_irq(&ent->lock);
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  248  			remove_cache_mr(ent);
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  249  			spin_lock_irq(&ent->lock);
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  250  		}
e126ba97dba9ed Eli Cohen       2013-07-07  251  	}
e126ba97dba9ed Eli Cohen       2013-07-07  252  }
e126ba97dba9ed Eli Cohen       2013-07-07  253  

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

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

* drivers/infiniband/hw/mlx5/mr.c:234:25: sparse: sparse: context imbalance in 'resize_available_mrs' - unexpected unlock
@ 2020-07-04 22:53 kernel test robot
  0 siblings, 0 replies; 3+ messages in thread
From: kernel test robot @ 2020-07-04 22:53 UTC (permalink / raw)
  To: kbuild

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

CC: kbuild-all(a)lists.01.org
CC: linux-kernel(a)vger.kernel.org
TO: Jason Gunthorpe <jgg@mellanox.com>
CC: Leon Romanovsky <leonro@mellanox.com>

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   35e884f89df4c48566d745dc5a97a0d058d04263
commit: a1d8854aae4ee19df6161a276a99d3c9c2abc4f3 RDMA/mlx5: Fix MR cache size and limit debugfs
date:   4 months ago
:::::: branch date: 16 hours ago
:::::: commit date: 4 months ago
config: i386-randconfig-s001-20200705 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-14) 9.3.0
reproduce:
        # apt-get install sparse
        # sparse version: v0.6.2-3-gfa153962-dirty
        git checkout a1d8854aae4ee19df6161a276a99d3c9c2abc4f3
        # save the attached .config to linux build tree
        make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=i386 

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

>> drivers/infiniband/hw/mlx5/mr.c:234:25: sparse: sparse: context imbalance in 'resize_available_mrs' - unexpected unlock

# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=a1d8854aae4ee19df6161a276a99d3c9c2abc4f3
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git remote update linus
git checkout a1d8854aae4ee19df6161a276a99d3c9c2abc4f3
vim +/resize_available_mrs +234 drivers/infiniband/hw/mlx5/mr.c

65edd0e758b8a2 Daniel Jurgens  2018-03-13  220  
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  221  static int resize_available_mrs(struct mlx5_cache_ent *ent, unsigned int target,
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  222  				bool limit_fill)
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  223  {
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  224  	int err;
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  225  
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  226  	lockdep_assert_held(&ent->lock);
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  227  
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  228  	while (true) {
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  229  		if (limit_fill)
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  230  			target = ent->limit * 2;
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  231  		if (target == ent->available_mrs + ent->pending)
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  232  			return 0;
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  233  		if (target > ent->available_mrs + ent->pending) {
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10 @234  			u32 todo = target - (ent->available_mrs + ent->pending);
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  235  
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  236  			spin_unlock_irq(&ent->lock);
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  237  			err = add_keys(ent, todo);
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  238  			if (err == -EAGAIN)
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  239  				usleep_range(3000, 5000);
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  240  			spin_lock_irq(&ent->lock);
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  241  			if (err) {
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  242  				if (err != -EAGAIN)
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  243  					return err;
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  244  			} else
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  245  				return 0;
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  246  		} else {
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  247  			spin_unlock_irq(&ent->lock);
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  248  			remove_cache_mr(ent);
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  249  			spin_lock_irq(&ent->lock);
a1d8854aae4ee1 Jason Gunthorpe 2020-03-10  250  		}
e126ba97dba9ed Eli Cohen       2013-07-07  251  	}
e126ba97dba9ed Eli Cohen       2013-07-07  252  }
e126ba97dba9ed Eli Cohen       2013-07-07  253  

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

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

* drivers/infiniband/hw/mlx5/mr.c:234:25: sparse: sparse: context imbalance in 'resize_available_mrs' - unexpected unlock
@ 2020-06-18 13:52 kernel test robot
  0 siblings, 0 replies; 3+ messages in thread
From: kernel test robot @ 2020-06-18 13:52 UTC (permalink / raw)
  To: kbuild

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

CC: kbuild-all(a)lists.01.org
CC: linux-kernel(a)vger.kernel.org
TO: Jason Gunthorpe <jgg@mellanox.com>
CC: Leon Romanovsky <leonro@mellanox.com>

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   1b5044021070efa3259f3e9548dc35d1eb6aa844
commit: a1d8854aae4ee19df6161a276a99d3c9c2abc4f3 RDMA/mlx5: Fix MR cache size and limit debugfs
date:   3 months ago
:::::: branch date: 19 hours ago
:::::: commit date: 3 months ago
config: arm-randconfig-s032-20200618 (attached as .config)
compiler: arm-linux-gnueabi-gcc (GCC) 9.3.0
reproduce:
        # apt-get install sparse
        # sparse version: v0.6.2-rc1-10-gc17b1b06-dirty
        git checkout a1d8854aae4ee19df6161a276a99d3c9c2abc4f3
        # save the attached .config to linux build tree
        make W=1 C=1 ARCH=arm CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__'

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

>> drivers/infiniband/hw/mlx5/mr.c:234:25: sparse: sparse: context imbalance in 'resize_available_mrs' - unexpected unlock

# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=a1d8854aae4ee19df6161a276a99d3c9c2abc4f3
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git remote update linus
git checkout a1d8854aae4ee19df6161a276a99d3c9c2abc4f3
vim +/resize_available_mrs +234 drivers/infiniband/hw/mlx5/mr.c

65edd0e758b8a21 Daniel Jurgens  2018-03-13  220  
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  221  static int resize_available_mrs(struct mlx5_cache_ent *ent, unsigned int target,
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  222  				bool limit_fill)
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  223  {
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  224  	int err;
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  225  
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  226  	lockdep_assert_held(&ent->lock);
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  227  
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  228  	while (true) {
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  229  		if (limit_fill)
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  230  			target = ent->limit * 2;
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  231  		if (target == ent->available_mrs + ent->pending)
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  232  			return 0;
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  233  		if (target > ent->available_mrs + ent->pending) {
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10 @234  			u32 todo = target - (ent->available_mrs + ent->pending);
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  235  
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  236  			spin_unlock_irq(&ent->lock);
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  237  			err = add_keys(ent, todo);
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  238  			if (err == -EAGAIN)
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  239  				usleep_range(3000, 5000);
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  240  			spin_lock_irq(&ent->lock);
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  241  			if (err) {
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  242  				if (err != -EAGAIN)
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  243  					return err;
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  244  			} else
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  245  				return 0;
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  246  		} else {
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  247  			spin_unlock_irq(&ent->lock);
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  248  			remove_cache_mr(ent);
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  249  			spin_lock_irq(&ent->lock);
a1d8854aae4ee19 Jason Gunthorpe 2020-03-10  250  		}
e126ba97dba9ede Eli Cohen       2013-07-07  251  	}
e126ba97dba9ede Eli Cohen       2013-07-07  252  }
e126ba97dba9ede Eli Cohen       2013-07-07  253  

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

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

end of thread, other threads:[~2020-09-11  5:50 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-11  5:50 drivers/infiniband/hw/mlx5/mr.c:234:25: sparse: sparse: context imbalance in 'resize_available_mrs' - unexpected unlock kernel test robot
  -- strict thread matches above, loose matches on Subject: below --
2020-07-04 22:53 kernel test robot
2020-06-18 13:52 kernel test robot

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.