All of lore.kernel.org
 help / color / mirror / Atom feed
* [dlm:next 10/16] fs/dlm/lowcomms.c:1497:16: sparse: sparse: context imbalance in 'dlm_lowcomms_new_msg' - different lock contexts for basic block
@ 2021-05-25 20:51 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2021-05-25 20:51 UTC (permalink / raw)
  To: kbuild

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

CC: kbuild-all(a)lists.01.org
CC: cluster-devel(a)redhat.com
TO: Alexander Aring <aahringo@redhat.com>
CC: David Teigland <teigland@redhat.com>

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/teigland/linux-dlm.git next
head:   706474fbc5fedd7799b488962aad3541b235165b
commit: 8f2dc78dbc2010b497bb58e0460cb44c678a3c5b [10/16] fs: dlm: make buffer handling per msg
:::::: branch date: 6 hours ago
:::::: commit date: 6 hours ago
config: m68k-randconfig-s031-20210525 (attached as .config)
compiler: m68k-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-341-g8af24329-dirty
        # https://git.kernel.org/pub/scm/linux/kernel/git/teigland/linux-dlm.git/commit/?id=8f2dc78dbc2010b497bb58e0460cb44c678a3c5b
        git remote add dlm https://git.kernel.org/pub/scm/linux/kernel/git/teigland/linux-dlm.git
        git fetch --no-tags dlm next
        git checkout 8f2dc78dbc2010b497bb58e0460cb44c678a3c5b
        # 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__' W=1 ARCH=m68k 

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 >>)
>> fs/dlm/lowcomms.c:1497:16: sparse: sparse: context imbalance in 'dlm_lowcomms_new_msg' - different lock contexts for basic block
   fs/dlm/lowcomms.c:1568:20: sparse: sparse: context imbalance in 'dlm_lowcomms_commit_msg' - unexpected unlock

vim +/dlm_lowcomms_new_msg +1497 fs/dlm/lowcomms.c

f0747ebf48f362 fs/dlm/lowcomms.c     Alexander Aring   2021-03-01  1496  
8f2dc78dbc2010 fs/dlm/lowcomms.c     Alexander Aring   2021-05-21 @1497  struct dlm_msg *dlm_lowcomms_new_msg(int nodeid, int len, gfp_t allocation,
8f2dc78dbc2010 fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1498  				     char **ppc, void (*cb)(struct dlm_mhandle *mh),
8f2dc78dbc2010 fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1499  				     struct dlm_mhandle *mh)
f0747ebf48f362 fs/dlm/lowcomms.c     Alexander Aring   2021-03-01  1500  {
b38bc9c2b3171f fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1501  	struct writequeue_entry *e;
f0747ebf48f362 fs/dlm/lowcomms.c     Alexander Aring   2021-03-01  1502  	struct connection *con;
8f2dc78dbc2010 fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1503  	struct dlm_msg *msg;
b38bc9c2b3171f fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1504  	int idx;
f0747ebf48f362 fs/dlm/lowcomms.c     Alexander Aring   2021-03-01  1505  
f0747ebf48f362 fs/dlm/lowcomms.c     Alexander Aring   2021-03-01  1506  	if (len > DEFAULT_BUFFER_SIZE ||
f0747ebf48f362 fs/dlm/lowcomms.c     Alexander Aring   2021-03-01  1507  	    len < sizeof(struct dlm_header)) {
f0747ebf48f362 fs/dlm/lowcomms.c     Alexander Aring   2021-03-01  1508  		BUILD_BUG_ON(PAGE_SIZE < DEFAULT_BUFFER_SIZE);
f0747ebf48f362 fs/dlm/lowcomms.c     Alexander Aring   2021-03-01  1509  		log_print("failed to allocate a buffer of size %d", len);
f0747ebf48f362 fs/dlm/lowcomms.c     Alexander Aring   2021-03-01  1510  		WARN_ON(1);
f0747ebf48f362 fs/dlm/lowcomms.c     Alexander Aring   2021-03-01  1511  		return NULL;
fdda387f73947e fs/dlm/lowcomms-tcp.c Patrick Caulfield 2006-11-02  1512  	}
f0747ebf48f362 fs/dlm/lowcomms.c     Alexander Aring   2021-03-01  1513  
b38bc9c2b3171f fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1514  	idx = srcu_read_lock(&connections_srcu);
f0747ebf48f362 fs/dlm/lowcomms.c     Alexander Aring   2021-03-01  1515  	con = nodeid2con(nodeid, allocation);
b38bc9c2b3171f fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1516  	if (!con) {
b38bc9c2b3171f fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1517  		srcu_read_unlock(&connections_srcu, idx);
fdda387f73947e fs/dlm/lowcomms-tcp.c Patrick Caulfield 2006-11-02  1518  		return NULL;
b38bc9c2b3171f fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1519  	}
f0747ebf48f362 fs/dlm/lowcomms.c     Alexander Aring   2021-03-01  1520  
8f2dc78dbc2010 fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1521  	msg = kzalloc(sizeof(*msg), allocation);
8f2dc78dbc2010 fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1522  	if (!msg) {
8f2dc78dbc2010 fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1523  		srcu_read_unlock(&connections_srcu, idx);
8f2dc78dbc2010 fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1524  		return NULL;
8f2dc78dbc2010 fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1525  	}
8f2dc78dbc2010 fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1526  
8f2dc78dbc2010 fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1527  	kref_init(&msg->ref);
8f2dc78dbc2010 fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1528  
8f2dc78dbc2010 fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1529  	e = new_wq_entry(con, len, allocation, ppc, cb, mh);
b38bc9c2b3171f fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1530  	if (!e) {
b38bc9c2b3171f fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1531  		srcu_read_unlock(&connections_srcu, idx);
8f2dc78dbc2010 fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1532  		kfree(msg);
b38bc9c2b3171f fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1533  		return NULL;
b38bc9c2b3171f fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1534  	}
b38bc9c2b3171f fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1535  
8f2dc78dbc2010 fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1536  	msg->ppc = *ppc;
8f2dc78dbc2010 fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1537  	msg->len = len;
8f2dc78dbc2010 fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1538  	msg->entry = e;
8f2dc78dbc2010 fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1539  
b38bc9c2b3171f fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1540  	/* we assume if successful commit must called */
8f2dc78dbc2010 fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1541  	msg->idx = idx;
b38bc9c2b3171f fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1542  
8f2dc78dbc2010 fs/dlm/lowcomms.c     Alexander Aring   2021-05-21  1543  	return msg;
fdda387f73947e fs/dlm/lowcomms-tcp.c Patrick Caulfield 2006-11-02  1544  }
fdda387f73947e fs/dlm/lowcomms-tcp.c Patrick Caulfield 2006-11-02  1545  

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

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-05-25 20:51 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-25 20:51 [dlm:next 10/16] fs/dlm/lowcomms.c:1497:16: sparse: sparse: context imbalance in 'dlm_lowcomms_new_msg' - different lock contexts for basic block 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.