All the mail mirrored from lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: oe-kbuild@lists.linux.dev
Cc: lkp@intel.com, Dan Carpenter <error27@gmail.com>
Subject: [linux-next:master 5679/6705] fs/9p/vfs_inode.c:513 v9fs_remove() error: uninitialized symbol 'v9fid'.
Date: Thu, 18 Apr 2024 01:15:58 +0800	[thread overview]
Message-ID: <202404180119.5AIBXYfG-lkp@intel.com> (raw)

BCC: lkp@intel.com
CC: oe-kbuild-all@lists.linux.dev
CC: Linux Memory Management List <linux-mm@kvack.org>
TO: Eric Van Hensbergen <ericvh@kernel.org>

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head:   4eab358930711bbeb85bf5ee267d0d42d3394c2c
commit: 6ae7784008d9f8a48fdce5609ce795e470a1ddc7 [5679/6705]  fs/9p: mitigate inode collisions
:::::: branch date: 11 hours ago
:::::: commit date: 2 days ago
config: alpha-randconfig-r081-20240417 (https://download.01.org/0day-ci/archive/20240418/202404180119.5AIBXYfG-lkp@intel.com/config)
compiler: alpha-linux-gcc (GCC) 13.2.0

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Reported-by: Dan Carpenter <error27@gmail.com>
| Closes: https://lore.kernel.org/r/202404180119.5AIBXYfG-lkp@intel.com/

smatch warnings:
fs/9p/vfs_inode.c:513 v9fs_remove() error: uninitialized symbol 'v9fid'.

vim +/v9fid +513 fs/9p/vfs_inode.c

ac89b2ef9b55924 Eryu Guan           2018-04-05  461  
2bad8471511ce5c Eric Van Hensbergen 2005-09-09  462  /**
2bad8471511ce5c Eric Van Hensbergen 2005-09-09  463   * v9fs_remove - helper function to remove files and directories
73c592b9b844cc3 Eric Van Hensbergen 2005-09-09  464   * @dir: directory inode that is being deleted
48e370ff93769ee Aneesh Kumar K.V    2011-06-28  465   * @dentry:  dentry that is being deleted
fd2916bd77109b6 Fabian Frederick    2014-06-04  466   * @flags: removing a directory
2bad8471511ce5c Eric Van Hensbergen 2005-09-09  467   *
2bad8471511ce5c Eric Van Hensbergen 2005-09-09  468   */
2bad8471511ce5c Eric Van Hensbergen 2005-09-09  469  
48e370ff93769ee Aneesh Kumar K.V    2011-06-28  470  static int v9fs_remove(struct inode *dir, struct dentry *dentry, int flags)
2bad8471511ce5c Eric Van Hensbergen 2005-09-09  471  {
48e370ff93769ee Aneesh Kumar K.V    2011-06-28  472  	struct inode *inode;
48e370ff93769ee Aneesh Kumar K.V    2011-06-28  473  	int retval = -EOPNOTSUPP;
48e370ff93769ee Aneesh Kumar K.V    2011-06-28  474  	struct p9_fid *v9fid, *dfid;
48e370ff93769ee Aneesh Kumar K.V    2011-06-28  475  	struct v9fs_session_info *v9ses;
2bad8471511ce5c Eric Van Hensbergen 2005-09-09  476  
5d3851530d6d685 Joe Perches         2011-11-28  477  	p9_debug(P9_DEBUG_VFS, "inode: %p dentry: %p rmdir: %x\n",
48e370ff93769ee Aneesh Kumar K.V    2011-06-28  478  		 dir, dentry, flags);
2bad8471511ce5c Eric Van Hensbergen 2005-09-09  479  
48e370ff93769ee Aneesh Kumar K.V    2011-06-28  480  	v9ses = v9fs_inode2v9ses(dir);
2b0143b5c986be1 David Howells       2015-03-17  481  	inode = d_inode(dentry);
77d5a6b7d9924e2 Al Viro             2016-05-29  482  	dfid = v9fs_parent_fid(dentry);
48e370ff93769ee Aneesh Kumar K.V    2011-06-28  483  	if (IS_ERR(dfid)) {
48e370ff93769ee Aneesh Kumar K.V    2011-06-28  484  		retval = PTR_ERR(dfid);
5d3851530d6d685 Joe Perches         2011-11-28  485  		p9_debug(P9_DEBUG_VFS, "fid lookup failed %d\n", retval);
48e370ff93769ee Aneesh Kumar K.V    2011-06-28  486  		return retval;
48e370ff93769ee Aneesh Kumar K.V    2011-06-28  487  	}
48e370ff93769ee Aneesh Kumar K.V    2011-06-28  488  	if (v9fs_proto_dotl(v9ses))
f88657ce3f9713a Aneesh Kumar K.V    2011-08-03  489  		retval = p9_client_unlinkat(dfid, dentry->d_name.name,
f88657ce3f9713a Aneesh Kumar K.V    2011-08-03  490  					    v9fs_at_to_dotl_flags(flags));
b48dbb998d70b7f Dominique Martinet  2022-06-12  491  	p9_fid_put(dfid);
48e370ff93769ee Aneesh Kumar K.V    2011-06-28  492  	if (retval == -EOPNOTSUPP) {
48e370ff93769ee Aneesh Kumar K.V    2011-06-28  493  		/* Try the one based on path */
48e370ff93769ee Aneesh Kumar K.V    2011-06-28  494  		v9fid = v9fs_fid_clone(dentry);
da977b2c7eb4d63 Eric Van Hensbergen 2007-01-26  495  		if (IS_ERR(v9fid))
da977b2c7eb4d63 Eric Van Hensbergen 2007-01-26  496  			return PTR_ERR(v9fid);
d994f4058d9f9be Aneesh Kumar K.V    2010-03-29  497  		retval = p9_client_remove(v9fid);
48e370ff93769ee Aneesh Kumar K.V    2011-06-28  498  	}
b271ec47bc11dea Aneesh Kumar K.V    2011-02-28  499  	if (!retval) {
b271ec47bc11dea Aneesh Kumar K.V    2011-02-28  500  		/*
b271ec47bc11dea Aneesh Kumar K.V    2011-02-28  501  		 * directories on unlink should have zero
b271ec47bc11dea Aneesh Kumar K.V    2011-02-28  502  		 * link count
b271ec47bc11dea Aneesh Kumar K.V    2011-02-28  503  		 */
48e370ff93769ee Aneesh Kumar K.V    2011-06-28  504  		if (flags & AT_REMOVEDIR) {
48e370ff93769ee Aneesh Kumar K.V    2011-06-28  505  			clear_nlink(inode);
ac89b2ef9b55924 Eryu Guan           2018-04-05  506  			v9fs_dec_count(dir);
b271ec47bc11dea Aneesh Kumar K.V    2011-02-28  507  		} else
ac89b2ef9b55924 Eryu Guan           2018-04-05  508  			v9fs_dec_count(inode);
d28c61f0e08aab9 Aneesh Kumar K.V    2011-02-28  509  
6ae7784008d9f8a Eric Van Hensbergen 2024-04-15  510  		if (inode->i_nlink <= 0) { /* no more refs unhash it */
6ae7784008d9f8a Eric Van Hensbergen 2024-04-15  511  			remove_inode_hash(inode);
6ae7784008d9f8a Eric Van Hensbergen 2024-04-15  512  		} else {
6ae7784008d9f8a Eric Van Hensbergen 2024-04-15 @513  			p9_debug(P9_DEBUG_ERROR,
6ae7784008d9f8a Eric Van Hensbergen 2024-04-15  514  			"WARNING: unlink inode %lx %s qid->path=%llx w/i_nlink==%d\n",
6ae7784008d9f8a Eric Van Hensbergen 2024-04-15  515  			inode->i_ino, dentry->d_name.name, v9fid->qid.path, inode->i_nlink);
6ae7784008d9f8a Eric Van Hensbergen 2024-04-15  516  		}
6ae7784008d9f8a Eric Van Hensbergen 2024-04-15  517  
48e370ff93769ee Aneesh Kumar K.V    2011-06-28  518  		v9fs_invalidate_inode_attr(inode);
d28c61f0e08aab9 Aneesh Kumar K.V    2011-02-28  519  		v9fs_invalidate_inode_attr(dir);
154372e67d4053e Eric Van Hensbergen 2020-09-23  520  
154372e67d4053e Eric Van Hensbergen 2020-09-23  521  		/* invalidate all fids associated with dentry */
154372e67d4053e Eric Van Hensbergen 2020-09-23  522  		/* NOTE: This will not include open fids */
154372e67d4053e Eric Van Hensbergen 2020-09-23  523  		dentry->d_op->d_release(dentry);
b271ec47bc11dea Aneesh Kumar K.V    2011-02-28  524  	}
d994f4058d9f9be Aneesh Kumar K.V    2010-03-29  525  	return retval;
2bad8471511ce5c Eric Van Hensbergen 2005-09-09  526  }
2bad8471511ce5c Eric Van Hensbergen 2005-09-09  527  

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

                 reply	other threads:[~2024-04-17 17:16 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=202404180119.5AIBXYfG-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=error27@gmail.com \
    --cc=oe-kbuild@lists.linux.dev \
    /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 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.