linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: NeilBrown <neilb@suse.de>, Al Viro <viro@zeniv.linux.org.uk>,
	Daire Byrne <daire@dneg.com>,
	Trond Myklebust <trond.myklebust@hammerspace.com>,
	Chuck Lever <chuck.lever@oracle.com>
Cc: llvm@lists.linux.dev, kbuild-all@lists.01.org,
	Linux NFS Mailing List <linux-nfs@vger.kernel.org>,
	linux-fsdevel@vger.kernel.org,
	LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 06/12] VFS: support concurrent renames.
Date: Tue, 14 Jun 2022 21:28:46 +0800	[thread overview]
Message-ID: <202206142141.w8ni6M0m-lkp@intel.com> (raw)
In-Reply-To: <165516230199.21248.18142980966152036732.stgit@noble.brown>

Hi NeilBrown,

Thank you for the patch! Perhaps something to improve:

[auto build test WARNING on linus/master]
[also build test WARNING on v5.19-rc2 next-20220614]
[cannot apply to trondmy-nfs/linux-next viro-vfs/for-next]
[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/intel-lab-lkp/linux/commits/NeilBrown/Allow-concurrent-directory-updates/20220614-072355
base:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git b13baccc3850ca8b8cccbf8ed9912dbaa0fdf7f3
config: i386-buildonly-randconfig-r005-20220613 (https://download.01.org/0day-ci/archive/20220614/202206142141.w8ni6M0m-lkp@intel.com/config)
compiler: clang version 15.0.0 (https://github.com/llvm/llvm-project c97436f8b6e2718286e8496faf53a2c800e281cf)
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
        # https://github.com/intel-lab-lkp/linux/commit/46a2afd9f68f24a42f38f3a8afebafe7e494e9d8
        git remote add linux-review https://github.com/intel-lab-lkp/linux
        git fetch --no-tags linux-review NeilBrown/Allow-concurrent-directory-updates/20220614-072355
        git checkout 46a2afd9f68f24a42f38f3a8afebafe7e494e9d8
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=i386 SHELL=/bin/bash

If you fix the issue, kindly add following tag where applicable
Reported-by: kernel test robot <lkp@intel.com>

All warnings (new ones prefixed by >>):

>> fs/namei.c:3175:16: warning: no previous prototype for function 'lock_rename_lookup_excl' [-Wmissing-prototypes]
   struct dentry *lock_rename_lookup_excl(struct dentry *p1, struct dentry *p2,
                  ^
   fs/namei.c:3175:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
   struct dentry *lock_rename_lookup_excl(struct dentry *p1, struct dentry *p2,
   ^
   static 
   1 warning generated.


vim +/lock_rename_lookup_excl +3175 fs/namei.c

  3174	
> 3175	struct dentry *lock_rename_lookup_excl(struct dentry *p1, struct dentry *p2,
  3176					       struct dentry **d1p, struct dentry **d2p,
  3177					       struct qstr *last1, struct qstr *last2,
  3178					       unsigned int flags1, unsigned int flags2)
  3179	{
  3180		struct dentry *p;
  3181		struct dentry *d1, *d2;
  3182	
  3183		if (p1 == p2) {
  3184			inode_lock_nested(p1->d_inode, I_MUTEX_PARENT);
  3185			d1 = __lookup_hash(last1, p1, flags1, NULL);
  3186			if (IS_ERR(d1))
  3187				goto out_unlock_1;
  3188			d2 = __lookup_hash(last2, p2, flags2, NULL);
  3189			if (IS_ERR(d2))
  3190				goto out_unlock_2;
  3191			*d1p = d1; *d2p = d2;
  3192			return NULL;
  3193		out_unlock_2:
  3194			dput(d1);
  3195			d1 = d2;
  3196		out_unlock_1:
  3197			inode_unlock(p1->d_inode);
  3198			return d1;
  3199		}
  3200	
  3201		mutex_lock(&p1->d_sb->s_vfs_rename_mutex);
  3202	
  3203		if ((p = d_ancestor(p2, p1)) != NULL) {
  3204			inode_lock_nested(p2->d_inode, I_MUTEX_PARENT);
  3205			inode_lock_nested(p1->d_inode, I_MUTEX_CHILD);
  3206		} else if ((p = d_ancestor(p1, p2)) != NULL) {
  3207			inode_lock_nested(p1->d_inode, I_MUTEX_PARENT);
  3208			inode_lock_nested(p2->d_inode, I_MUTEX_CHILD);
  3209		} else {
  3210			inode_lock_nested(p1->d_inode, I_MUTEX_PARENT);
  3211			inode_lock_nested(p2->d_inode, I_MUTEX_PARENT2);
  3212		}
  3213		d1 = __lookup_hash(last1, p1, flags1, NULL);
  3214		if (IS_ERR(d1))
  3215			goto unlock_out_3;
  3216		d2 = __lookup_hash(last2, p2, flags2, NULL);
  3217		if (IS_ERR(d2))
  3218			goto unlock_out_4;
  3219	
  3220		*d1p = d1;
  3221		*d2p = d2;
  3222		return p;
  3223	unlock_out_4:
  3224		dput(d1);
  3225		d1 = d2;
  3226	unlock_out_3:
  3227		inode_unlock(p1->d_inode);
  3228		inode_unlock(p2->d_inode);
  3229		mutex_unlock(&p1->d_sb->s_vfs_rename_mutex);
  3230		return d1;
  3231	}
  3232	

-- 
0-DAY CI Kernel Test Service
https://01.org/lkp

  parent reply	other threads:[~2022-06-14 13:29 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-13 23:18 [PATCH RFC 00/12] Allow concurrent directory updates NeilBrown
2022-06-13 23:18 ` [PATCH 04/12] VFS: move dput() and mnt_drop_write() into done_path_update() NeilBrown
2022-06-13 23:18 ` [PATCH 03/12] VFS: move want_write checks into lookup_hash_update() NeilBrown
2022-06-13 23:18 ` [PATCH 02/12] VFS: move EEXIST and ENOENT tests " NeilBrown
2022-06-13 23:18 ` [PATCH 01/12] VFS: support parallel updates in the one directory NeilBrown
2022-06-13 23:18 ` [PATCH 05/12] VFS: export done_path_update() NeilBrown
2022-06-13 23:18 ` [PATCH 08/12] nfsd: allow parallel creates from nfsd NeilBrown
2022-06-24 14:43   ` Chuck Lever III
2022-06-28 22:35   ` Chuck Lever III
2022-06-28 23:09     ` NeilBrown
2022-07-04 17:17       ` Chuck Lever III
2022-06-13 23:18 ` [PATCH 07/12] NFS: support parallel updates in the one directory NeilBrown
2022-06-13 23:18 ` [PATCH 11/12] nfsd: use (un)lock_inode instead of fh_(un)lock NeilBrown
2022-06-24 14:43   ` Chuck Lever III
2022-06-13 23:18 ` [PATCH 06/12] VFS: support concurrent renames NeilBrown
2022-06-14  4:35   ` kernel test robot
2022-06-14 12:37   ` kernel test robot
2022-06-14 13:28   ` kernel test robot [this message]
2022-06-26 13:07   ` [VFS] 46a2afd9f6: ltp.rename10.fail kernel test robot
2022-06-13 23:18 ` [PATCH 12/12] nfsd: discard fh_locked flag and fh_lock/fh_unlock NeilBrown
2022-06-24 14:43   ` Chuck Lever III
2022-06-13 23:18 ` [PATCH 10/12] nfsd: reduce locking in nfsd_lookup() NeilBrown
2022-06-24 14:43   ` Chuck Lever III
2022-06-13 23:18 ` [PATCH 09/12] nfsd: support concurrent renames NeilBrown
2022-06-24 14:43   ` Chuck Lever III
2022-06-15 13:46 ` [PATCH RFC 00/12] Allow concurrent directory updates Daire Byrne
2022-06-16  0:55   ` NeilBrown
2022-06-16 10:48     ` Daire Byrne
2022-06-17  5:49       ` NeilBrown
2022-06-17 15:27         ` Daire Byrne
2022-06-20 10:18           ` Daire Byrne
2022-06-16 13:49     ` Anna Schumaker

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=202206142141.w8ni6M0m-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=chuck.lever@oracle.com \
    --cc=daire@dneg.com \
    --cc=kbuild-all@lists.01.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-nfs@vger.kernel.org \
    --cc=llvm@lists.linux.dev \
    --cc=neilb@suse.de \
    --cc=trond.myklebust@hammerspace.com \
    --cc=viro@zeniv.linux.org.uk \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).