All of lore.kernel.org
 help / color / mirror / Atom feed
* [djwong-xfs:repair-xattrs 109/126] fs/xfs/xfs_swapext_item.c:59:5-24: atomic_dec_and_test variation before object free at line 60.
@ 2020-10-01  5:30 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2020-10-01  5:30 UTC (permalink / raw)
  To: kbuild

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

CC: kbuild-all(a)lists.01.org
CC: "Darrick J. Wong" <darrick.wong@oracle.com>
TO: "Darrick J. Wong" <darrick.wong@oracle.com>

Hi Darrick,

First bad commit (maybe != root cause):

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/djwong/xfs-linux.git repair-xattrs
head:   116db50275b4cdfe629f26b677f16a38b77f14ee
commit: ebe81ecf6cde45190ffdc5ac3c55e527023729d4 [109/126] xfs: create deferred log items for extent swapping
:::::: branch date: 3 days ago
:::::: commit date: 3 days ago
config: i386-randconfig-c001-20200930 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Julia Lawall <julia.lawall@lip6.fr>

	echo
	echo "coccinelle warnings: (new ones prefixed by >>)"
	echo
>> fs/xfs/xfs_swapext_item.c:59:5-24: atomic_dec_and_test variation before object free at line 60.

vim +59 fs/xfs/xfs_swapext_item.c

3905a86df350b1 Darrick J. Wong 2020-06-25  46  
3905a86df350b1 Darrick J. Wong 2020-06-25  47  /*
3905a86df350b1 Darrick J. Wong 2020-06-25  48   * Freeing the SXI requires that we remove it from the AIL if it has already
3905a86df350b1 Darrick J. Wong 2020-06-25  49   * been placed there. However, the SXI may not yet have been placed in the AIL
3905a86df350b1 Darrick J. Wong 2020-06-25  50   * when called by xfs_sxi_release() from SXD processing due to the ordering of
3905a86df350b1 Darrick J. Wong 2020-06-25  51   * committed vs unpin operations in bulk insert operations. Hence the reference
3905a86df350b1 Darrick J. Wong 2020-06-25  52   * count to ensure only the last caller frees the SXI.
3905a86df350b1 Darrick J. Wong 2020-06-25  53   */
3905a86df350b1 Darrick J. Wong 2020-06-25  54  STATIC void
3905a86df350b1 Darrick J. Wong 2020-06-25  55  xfs_sxi_release(
3905a86df350b1 Darrick J. Wong 2020-06-25  56  	struct xfs_sxi_log_item	*sxi_lip)
3905a86df350b1 Darrick J. Wong 2020-06-25  57  {
3905a86df350b1 Darrick J. Wong 2020-06-25  58  	ASSERT(atomic_read(&sxi_lip->sxi_refcount) > 0);
3905a86df350b1 Darrick J. Wong 2020-06-25 @59  	if (atomic_dec_and_test(&sxi_lip->sxi_refcount)) {
3905a86df350b1 Darrick J. Wong 2020-06-25 @60  		xfs_trans_ail_delete(&sxi_lip->sxi_item, SHUTDOWN_LOG_IO_ERROR);
3905a86df350b1 Darrick J. Wong 2020-06-25  61  		xfs_sxi_item_free(sxi_lip);
3905a86df350b1 Darrick J. Wong 2020-06-25  62  	}
3905a86df350b1 Darrick J. Wong 2020-06-25  63  }
3905a86df350b1 Darrick J. Wong 2020-06-25  64  

:::::: The code at line 59 was first introduced by commit
:::::: 3905a86df350b1007b5f1f0ba21f3d284b4a4e16 xfs: introduce a swap-extent log intent item

:::::: TO: Darrick J. Wong <darrick.wong@oracle.com>
:::::: CC: Darrick J. Wong <darrick.wong@oracle.com>

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

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

only message in thread, other threads:[~2020-10-01  5:30 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-10-01  5:30 [djwong-xfs:repair-xattrs 109/126] fs/xfs/xfs_swapext_item.c:59:5-24: atomic_dec_and_test variation before object free at line 60 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.