lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <202008280030.lrR2wXqO%lkp@intel.com>
Date:   Fri, 28 Aug 2020 00:13:24 +0800
From:   kernel test robot <lkp@...el.com>
To:     Chunguang Xu <brookxu.cn@...il.com>, arnd@...db.de
Cc:     kbuild-all@...ts.01.org, clang-built-linux@...glegroups.com,
        rppt@...nel.org, linux-arch@...r.kernel.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH 08/23] jfs: use ASSERT_FAIL()/ASSERT_WARN() to cleanup
 some code

Hi Chunguang,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on mkp-scsi/for-next]
[also build test ERROR on scsi/for-next block/for-next linus/master asm-generic/master v5.9-rc2 next-20200827]
[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/Chunguang-Xu/clean-up-the-code-related-to-ASSERT/20200827-182148
base:   https://git.kernel.org/pub/scm/linux/kernel/git/mkp/scsi.git for-next
config: x86_64-randconfig-a014-20200827 (attached as .config)
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project 71f3169e1baeff262583b35ef88f8fb6df7be85e)
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 x86_64 cross compiling tool for clang build
        # apt-get install binutils-x86-64-linux-gnu
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=x86_64 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@...el.com>

All errors (new ones prefixed by >>):

>> fs/jfs/namei.c:524:3: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
                   assert(!test_cflag(COMMIT_Nolink, ip));
                   ^
   fs/jfs/namei.c:640:3: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
                   assert(filetype != S_IFDIR);
                   ^
   fs/jfs/namei.c:1191:4: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
                           assert(!test_cflag(COMMIT_Nolink, new_ip));
                           ^
   3 errors generated.
--
>> fs/jfs/jfs_xtree.c:494:3: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
                   BT_PUSH(btstack, bn, index);
                   ^
   fs/jfs/jfs_btree.h:119:2: note: expanded from macro 'BT_PUSH'
           assert(!BT_STACK_FULL(BTSTACK));\
           ^
   fs/jfs/jfs_xtree.c:3180:2: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
           assert(flag != COMMIT_PMAP);
           ^
   fs/jfs/jfs_xtree.c:3843:2: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
           BT_PUSH(&btstack, bn, index);
           ^
   fs/jfs/jfs_btree.h:119:2: note: expanded from macro 'BT_PUSH'
           assert(!BT_STACK_FULL(BTSTACK));\
           ^
   3 errors generated.
--
>> fs/jfs/jfs_imap.c:679:3: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
                   assert(tlck->type & tlckXTREE);
                   ^
   fs/jfs/jfs_imap.c:1095:4: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
                           assert(ciagp != NULL);
                           ^
   fs/jfs/jfs_imap.c:1109:4: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
                           assert(diagp != NULL);
                           ^
   fs/jfs/jfs_imap.c:1428:6: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
                                           assert(rc == -EIO);
                                           ^
   fs/jfs/jfs_imap.c:1511:6: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
                                           assert(rc == -EIO);
                                           ^
   fs/jfs/jfs_imap.c:1550:6: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
                                           assert(rc == -EIO);
                                           ^
   fs/jfs/jfs_imap.c:2689:2: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
           assert(start < 32);
           ^
   fs/jfs/jfs_imap.c:2813:3: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
                   assert(mp->clsn);
                   ^
   8 errors generated.
--
>> fs/jfs/jfs_dmap.c:700:2: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
           assert(nblocks > 0);
           ^
   fs/jfs/jfs_dmap.c:1865:2: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
           assert((blkno & (BPERDMAP - 1)) == 0);
           ^
   fs/jfs/jfs_dmap.c:1991:2: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
           assert(l2nb <= L2BPERDMAP);
           ^
   fs/jfs/jfs_dmap.c:2182:2: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
           assert(dbitno + nblocks <= BPERDMAP);
           ^
   fs/jfs/jfs_dmap.c:2327:2: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
           assert(dbitno + nblocks <= BPERDMAP);
           ^
   fs/jfs/jfs_dmap.c:2612:4: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
                           assert(level == bmp->db_maxlevel);
                           ^
   fs/jfs/jfs_dmap.c:2721:2: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
           assert(leaf[leafno] == NOFREE);
           ^
   fs/jfs/jfs_dmap.c:2989:3: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
                   assert(n < 4);
                   ^
   fs/jfs/jfs_dmap.c:3025:2: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
           assert(nb <= DBWORD);
           ^
   fs/jfs/jfs_dmap.c:3172:2: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
           assert(0);
           ^
   fs/jfs/jfs_dmap.c:3270:2: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
           assert(dbitno + nblocks <= BPERDMAP);
           ^
   11 errors generated.
--
>> fs/jfs/jfs_dtree.c:775:3: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
                   BT_PUSH(btstack, bn, index);
                   ^
   fs/jfs/jfs_btree.h:119:2: note: expanded from macro 'BT_PUSH'
           assert(!BT_STACK_FULL(BTSTACK));\
           ^
   fs/jfs/jfs_dtree.c:3376:3: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
                   BT_PUSH(btstack, bn, 0);
                   ^
   fs/jfs/jfs_btree.h:119:2: note: expanded from macro 'BT_PUSH'
           assert(!BT_STACK_FULL(BTSTACK));\
           ^
   2 errors generated.
--
>> fs/jfs/jfs_metapage.c:739:2: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
           assert(mp->count);
           ^
   1 error generated.
--
>> fs/jfs/jfs_logmgr.c:1595:2: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
           assert(list_empty(&log->cqueue));
           ^
   fs/jfs/jfs_logmgr.c:1929:2: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
           assert(bp->l_wqnext == NULL);
           ^
   fs/jfs/jfs_logmgr.c:2312:3: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
                   assert(bp->l_flag & lbmRELEASE);
                   ^
   3 errors generated.
--
>> fs/jfs/jfs_txnmgr.c:523:2: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
           assert(tblk->next == 0);
           ^
   fs/jfs/jfs_txnmgr.c:656:5: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
                                   assert(last);
                                   ^
   fs/jfs/jfs_txnmgr.c:875:4: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
                           assert(mp->xflag & COMMIT_PAGE);
                           ^
   fs/jfs/jfs_txnmgr.c:920:4: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
                           assert(mp->xflag & COMMIT_PAGE);
                           ^
   fs/jfs/jfs_txnmgr.c:2241:4: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
                           assert(mp->xflag & COMMIT_PAGE);
                           ^
   fs/jfs/jfs_txnmgr.c:2372:4: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
                           assert(mp->nohomeok == 1);
                           ^
   fs/jfs/jfs_txnmgr.c:2827:2: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
           assert(mp->nohomeok);
           ^
   7 errors generated.
--
>> fs/jfs/xattr.c:153:3: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
                   assert(size <= sizeof (ji->i_inline_ea));
                   ^
   fs/jfs/xattr.c:583:3: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
                   assert(ea_buf->mp);
                   ^
   fs/jfs/xattr.c:603:3: error: implicit declaration of function 'assert' [-Werror,-Wimplicit-function-declaration]
                   assert(new_size <= sizeof (ji->i_inline_ea));
                   ^
   3 errors generated.

# https://github.com/0day-ci/linux/commit/073244e1adc3932156c9523a347b3edec3d87a9d
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Chunguang-Xu/clean-up-the-code-related-to-ASSERT/20200827-182148
git checkout 073244e1adc3932156c9523a347b3edec3d87a9d
vim +/assert +524 fs/jfs/namei.c

^1da177e4c3f41 Linus Torvalds    2005-04-16  441  
^1da177e4c3f41 Linus Torvalds    2005-04-16  442  /*
^1da177e4c3f41 Linus Torvalds    2005-04-16  443   * NAME:	jfs_unlink(dip, dentry)
^1da177e4c3f41 Linus Torvalds    2005-04-16  444   *
^1da177e4c3f41 Linus Torvalds    2005-04-16  445   * FUNCTION:	remove a link to object <vp> named by <name>
^1da177e4c3f41 Linus Torvalds    2005-04-16  446   *		from parent directory <dvp>
^1da177e4c3f41 Linus Torvalds    2005-04-16  447   *
^1da177e4c3f41 Linus Torvalds    2005-04-16  448   * PARAMETER:	dip	- inode of parent directory
^1da177e4c3f41 Linus Torvalds    2005-04-16  449   *		dentry	- dentry of object to be removed
^1da177e4c3f41 Linus Torvalds    2005-04-16  450   *
^1da177e4c3f41 Linus Torvalds    2005-04-16  451   * RETURN:	errors from subroutines
^1da177e4c3f41 Linus Torvalds    2005-04-16  452   *
^1da177e4c3f41 Linus Torvalds    2005-04-16  453   * note:
^1da177e4c3f41 Linus Torvalds    2005-04-16  454   * temporary file: if one or more processes have the file open
^1da177e4c3f41 Linus Torvalds    2005-04-16  455   * when the last link is removed, the link will be removed before
^1da177e4c3f41 Linus Torvalds    2005-04-16  456   * unlink() returns, but the removal of the file contents will be
^1da177e4c3f41 Linus Torvalds    2005-04-16  457   * postponed until all references to the files are closed.
^1da177e4c3f41 Linus Torvalds    2005-04-16  458   *
^1da177e4c3f41 Linus Torvalds    2005-04-16  459   * JFS does NOT support unlink() on directories.
^1da177e4c3f41 Linus Torvalds    2005-04-16  460   *
^1da177e4c3f41 Linus Torvalds    2005-04-16  461   */
^1da177e4c3f41 Linus Torvalds    2005-04-16  462  static int jfs_unlink(struct inode *dip, struct dentry *dentry)
^1da177e4c3f41 Linus Torvalds    2005-04-16  463  {
^1da177e4c3f41 Linus Torvalds    2005-04-16  464  	int rc;
^1da177e4c3f41 Linus Torvalds    2005-04-16  465  	tid_t tid;		/* transaction id */
2b0143b5c986be David Howells     2015-03-17  466  	struct inode *ip = d_inode(dentry);
^1da177e4c3f41 Linus Torvalds    2005-04-16  467  	ino_t ino;
^1da177e4c3f41 Linus Torvalds    2005-04-16  468  	struct component_name dname;	/* object name */
^1da177e4c3f41 Linus Torvalds    2005-04-16  469  	struct inode *iplist[2];
^1da177e4c3f41 Linus Torvalds    2005-04-16  470  	struct tblock *tblk;
^1da177e4c3f41 Linus Torvalds    2005-04-16  471  	s64 new_size = 0;
^1da177e4c3f41 Linus Torvalds    2005-04-16  472  	int commit_flag;
^1da177e4c3f41 Linus Torvalds    2005-04-16  473  
a455589f181e60 Al Viro           2014-10-21  474  	jfs_info("jfs_unlink: dip:0x%p name:%pd", dip, dentry);
^1da177e4c3f41 Linus Torvalds    2005-04-16  475  
^1da177e4c3f41 Linus Torvalds    2005-04-16  476  	/* Init inode for quota operations. */
acc84b05b1f463 Dave Kleikamp     2015-07-15  477  	rc = dquot_initialize(dip);
acc84b05b1f463 Dave Kleikamp     2015-07-15  478  	if (rc)
acc84b05b1f463 Dave Kleikamp     2015-07-15  479  		goto out;
acc84b05b1f463 Dave Kleikamp     2015-07-15  480  	rc = dquot_initialize(ip);
acc84b05b1f463 Dave Kleikamp     2015-07-15  481  	if (rc)
acc84b05b1f463 Dave Kleikamp     2015-07-15  482  		goto out;
^1da177e4c3f41 Linus Torvalds    2005-04-16  483  
^1da177e4c3f41 Linus Torvalds    2005-04-16  484  	if ((rc = get_UCSname(&dname, dentry)))
^1da177e4c3f41 Linus Torvalds    2005-04-16  485  		goto out;
^1da177e4c3f41 Linus Torvalds    2005-04-16  486  
82d5b9a7c63054 Dave Kleikamp     2007-01-09  487  	IWRITE_LOCK(ip, RDWRLOCK_NORMAL);
^1da177e4c3f41 Linus Torvalds    2005-04-16  488  
^1da177e4c3f41 Linus Torvalds    2005-04-16  489  	tid = txBegin(dip->i_sb, 0);
^1da177e4c3f41 Linus Torvalds    2005-04-16  490  
82d5b9a7c63054 Dave Kleikamp     2007-01-09  491  	mutex_lock_nested(&JFS_IP(dip)->commit_mutex, COMMIT_MUTEX_PARENT);
82d5b9a7c63054 Dave Kleikamp     2007-01-09  492  	mutex_lock_nested(&JFS_IP(ip)->commit_mutex, COMMIT_MUTEX_CHILD);
^1da177e4c3f41 Linus Torvalds    2005-04-16  493  
^1da177e4c3f41 Linus Torvalds    2005-04-16  494  	iplist[0] = dip;
^1da177e4c3f41 Linus Torvalds    2005-04-16  495  	iplist[1] = ip;
^1da177e4c3f41 Linus Torvalds    2005-04-16  496  
^1da177e4c3f41 Linus Torvalds    2005-04-16  497  	/*
^1da177e4c3f41 Linus Torvalds    2005-04-16  498  	 * delete the entry of target file from parent directory
^1da177e4c3f41 Linus Torvalds    2005-04-16  499  	 */
^1da177e4c3f41 Linus Torvalds    2005-04-16  500  	ino = ip->i_ino;
^1da177e4c3f41 Linus Torvalds    2005-04-16  501  	if ((rc = dtDelete(tid, dip, &dname, &ino, JFS_REMOVE))) {
^1da177e4c3f41 Linus Torvalds    2005-04-16  502  		jfs_err("jfs_unlink: dtDelete returned %d", rc);
^1da177e4c3f41 Linus Torvalds    2005-04-16  503  		if (rc == -EIO)
^1da177e4c3f41 Linus Torvalds    2005-04-16  504  			txAbort(tid, 1);	/* Marks FS Dirty */
^1da177e4c3f41 Linus Torvalds    2005-04-16  505  		txEnd(tid);
1de87444f8f910 Ingo Molnar       2006-01-24  506  		mutex_unlock(&JFS_IP(ip)->commit_mutex);
48ce8b056c8892 Evgeniy Dushistov 2006-06-05  507  		mutex_unlock(&JFS_IP(dip)->commit_mutex);
^1da177e4c3f41 Linus Torvalds    2005-04-16  508  		IWRITE_UNLOCK(ip);
^1da177e4c3f41 Linus Torvalds    2005-04-16  509  		goto out1;
^1da177e4c3f41 Linus Torvalds    2005-04-16  510  	}
^1da177e4c3f41 Linus Torvalds    2005-04-16  511  
^1da177e4c3f41 Linus Torvalds    2005-04-16  512  	ASSERT(ip->i_nlink);
^1da177e4c3f41 Linus Torvalds    2005-04-16  513  
078cd8279e6599 Deepa Dinamani    2016-09-14  514  	ip->i_ctime = dip->i_ctime = dip->i_mtime = current_time(ip);
^1da177e4c3f41 Linus Torvalds    2005-04-16  515  	mark_inode_dirty(dip);
^1da177e4c3f41 Linus Torvalds    2005-04-16  516  
^1da177e4c3f41 Linus Torvalds    2005-04-16  517  	/* update target's inode */
9a53c3a783c2fa Dave Hansen       2006-09-30  518  	inode_dec_link_count(ip);
^1da177e4c3f41 Linus Torvalds    2005-04-16  519  
^1da177e4c3f41 Linus Torvalds    2005-04-16  520  	/*
^1da177e4c3f41 Linus Torvalds    2005-04-16  521  	 *	commit zero link count object
^1da177e4c3f41 Linus Torvalds    2005-04-16  522  	 */
^1da177e4c3f41 Linus Torvalds    2005-04-16  523  	if (ip->i_nlink == 0) {
^1da177e4c3f41 Linus Torvalds    2005-04-16 @524  		assert(!test_cflag(COMMIT_Nolink, ip));
^1da177e4c3f41 Linus Torvalds    2005-04-16  525  		/* free block resources */
^1da177e4c3f41 Linus Torvalds    2005-04-16  526  		if ((new_size = commitZeroLink(tid, ip)) < 0) {
^1da177e4c3f41 Linus Torvalds    2005-04-16  527  			txAbort(tid, 1);	/* Marks FS Dirty */
^1da177e4c3f41 Linus Torvalds    2005-04-16  528  			txEnd(tid);
1de87444f8f910 Ingo Molnar       2006-01-24  529  			mutex_unlock(&JFS_IP(ip)->commit_mutex);
48ce8b056c8892 Evgeniy Dushistov 2006-06-05  530  			mutex_unlock(&JFS_IP(dip)->commit_mutex);
^1da177e4c3f41 Linus Torvalds    2005-04-16  531  			IWRITE_UNLOCK(ip);
^1da177e4c3f41 Linus Torvalds    2005-04-16  532  			rc = new_size;
^1da177e4c3f41 Linus Torvalds    2005-04-16  533  			goto out1;
^1da177e4c3f41 Linus Torvalds    2005-04-16  534  		}
^1da177e4c3f41 Linus Torvalds    2005-04-16  535  		tblk = tid_to_tblock(tid);
^1da177e4c3f41 Linus Torvalds    2005-04-16  536  		tblk->xflag |= COMMIT_DELETE;
^1da177e4c3f41 Linus Torvalds    2005-04-16  537  		tblk->u.ip = ip;
^1da177e4c3f41 Linus Torvalds    2005-04-16  538  	}
^1da177e4c3f41 Linus Torvalds    2005-04-16  539  
^1da177e4c3f41 Linus Torvalds    2005-04-16  540  	/*
^1da177e4c3f41 Linus Torvalds    2005-04-16  541  	 * Incomplete truncate of file data can
^1da177e4c3f41 Linus Torvalds    2005-04-16  542  	 * result in timing problems unless we synchronously commit the
^1da177e4c3f41 Linus Torvalds    2005-04-16  543  	 * transaction.
^1da177e4c3f41 Linus Torvalds    2005-04-16  544  	 */
^1da177e4c3f41 Linus Torvalds    2005-04-16  545  	if (new_size)
^1da177e4c3f41 Linus Torvalds    2005-04-16  546  		commit_flag = COMMIT_SYNC;
^1da177e4c3f41 Linus Torvalds    2005-04-16  547  	else
^1da177e4c3f41 Linus Torvalds    2005-04-16  548  		commit_flag = 0;
^1da177e4c3f41 Linus Torvalds    2005-04-16  549  
^1da177e4c3f41 Linus Torvalds    2005-04-16  550  	/*
^1da177e4c3f41 Linus Torvalds    2005-04-16  551  	 * If xtTruncate was incomplete, commit synchronously to avoid
^1da177e4c3f41 Linus Torvalds    2005-04-16  552  	 * timing complications
^1da177e4c3f41 Linus Torvalds    2005-04-16  553  	 */
^1da177e4c3f41 Linus Torvalds    2005-04-16  554  	rc = txCommit(tid, 2, &iplist[0], commit_flag);
^1da177e4c3f41 Linus Torvalds    2005-04-16  555  
^1da177e4c3f41 Linus Torvalds    2005-04-16  556  	txEnd(tid);
^1da177e4c3f41 Linus Torvalds    2005-04-16  557  
1de87444f8f910 Ingo Molnar       2006-01-24  558  	mutex_unlock(&JFS_IP(ip)->commit_mutex);
48ce8b056c8892 Evgeniy Dushistov 2006-06-05  559  	mutex_unlock(&JFS_IP(dip)->commit_mutex);
^1da177e4c3f41 Linus Torvalds    2005-04-16  560  
^1da177e4c3f41 Linus Torvalds    2005-04-16  561  	while (new_size && (rc == 0)) {
^1da177e4c3f41 Linus Torvalds    2005-04-16  562  		tid = txBegin(dip->i_sb, 0);
1de87444f8f910 Ingo Molnar       2006-01-24  563  		mutex_lock(&JFS_IP(ip)->commit_mutex);
^1da177e4c3f41 Linus Torvalds    2005-04-16  564  		new_size = xtTruncate_pmap(tid, ip, new_size);
^1da177e4c3f41 Linus Torvalds    2005-04-16  565  		if (new_size < 0) {
^1da177e4c3f41 Linus Torvalds    2005-04-16  566  			txAbort(tid, 1);	/* Marks FS Dirty */
^1da177e4c3f41 Linus Torvalds    2005-04-16  567  			rc = new_size;
^1da177e4c3f41 Linus Torvalds    2005-04-16  568  		} else
^1da177e4c3f41 Linus Torvalds    2005-04-16  569  			rc = txCommit(tid, 2, &iplist[0], COMMIT_SYNC);
^1da177e4c3f41 Linus Torvalds    2005-04-16  570  		txEnd(tid);
1de87444f8f910 Ingo Molnar       2006-01-24  571  		mutex_unlock(&JFS_IP(ip)->commit_mutex);
^1da177e4c3f41 Linus Torvalds    2005-04-16  572  	}
^1da177e4c3f41 Linus Torvalds    2005-04-16  573  
^1da177e4c3f41 Linus Torvalds    2005-04-16  574  	if (ip->i_nlink == 0)
^1da177e4c3f41 Linus Torvalds    2005-04-16  575  		set_cflag(COMMIT_Nolink, ip);
^1da177e4c3f41 Linus Torvalds    2005-04-16  576  
^1da177e4c3f41 Linus Torvalds    2005-04-16  577  	IWRITE_UNLOCK(ip);
^1da177e4c3f41 Linus Torvalds    2005-04-16  578  
^1da177e4c3f41 Linus Torvalds    2005-04-16  579  	/*
^1da177e4c3f41 Linus Torvalds    2005-04-16  580  	 * Truncating the directory index table is not guaranteed.  It
^1da177e4c3f41 Linus Torvalds    2005-04-16  581  	 * may need to be done iteratively
^1da177e4c3f41 Linus Torvalds    2005-04-16  582  	 */
^1da177e4c3f41 Linus Torvalds    2005-04-16  583  	if (test_cflag(COMMIT_Stale, dip)) {
^1da177e4c3f41 Linus Torvalds    2005-04-16  584  		if (dip->i_size > 1)
^1da177e4c3f41 Linus Torvalds    2005-04-16  585  			jfs_truncate_nolock(dip, 0);
^1da177e4c3f41 Linus Torvalds    2005-04-16  586  
^1da177e4c3f41 Linus Torvalds    2005-04-16  587  		clear_cflag(COMMIT_Stale, dip);
^1da177e4c3f41 Linus Torvalds    2005-04-16  588  	}
^1da177e4c3f41 Linus Torvalds    2005-04-16  589  
^1da177e4c3f41 Linus Torvalds    2005-04-16  590        out1:
^1da177e4c3f41 Linus Torvalds    2005-04-16  591  	free_UCSname(&dname);
^1da177e4c3f41 Linus Torvalds    2005-04-16  592        out:
^1da177e4c3f41 Linus Torvalds    2005-04-16  593  	jfs_info("jfs_unlink: rc:%d", rc);
^1da177e4c3f41 Linus Torvalds    2005-04-16  594  	return rc;
^1da177e4c3f41 Linus Torvalds    2005-04-16  595  }
^1da177e4c3f41 Linus Torvalds    2005-04-16  596  

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

Download attachment ".config.gz" of type "application/gzip" (31508 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ