Re: [PATCH v2 3/3] nfsd: resolve possible conflicts of reads using special stateids and write delegations

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 






On 29/07/2024 3:35, kernel test robot wrote:
Hi Sagi,

kernel test robot noticed the following build warnings:

[auto build test WARNING on linus/master]
[also build test WARNING on v6.11-rc1 next-20240726]
[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#_base_tree_information]

url:    https://github.com/intel-lab-lkp/linux/commits/Sagi-Grimberg/nfsd-don-t-assume-copy-notify-when-preprocessing-the-stateid/20240729-044834
base:   linus/master
patch link:    https://lore.kernel.org/r/20240728204104.519041-4-sagi%40grimberg.me
patch subject: [PATCH v2 3/3] nfsd: resolve possible conflicts of reads using special stateids and write delegations
config: x86_64-rhel-8.3-rust (https://download.01.org/0day-ci/archive/20240729/202407290814.7REsmaH7-lkp@xxxxxxxxx/config)
compiler: clang version 18.1.5 (https://github.com/llvm/llvm-project 617a15a9eac96088ae5e9134248d8236e34b91b1)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240729/202407290814.7REsmaH7-lkp@xxxxxxxxx/reproduce)

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@xxxxxxxxx>
| Closes: https://lore.kernel.org/oe-kbuild-all/202407290814.7REsmaH7-lkp@xxxxxxxxx/

All warnings (new ones prefixed by >>):

fs/nfsd/nfs4state.c:8826: warning: Excess function parameter 'inode' description in 'nfsd4_deleg_read_conflict'
fs/nfsd/nfs4state.c:8826: warning: Excess function parameter 'modified' description in 'nfsd4_deleg_read_conflict'
fs/nfsd/nfs4state.c:8826: warning: Excess function parameter 'size' description in 'nfsd4_deleg_read_conflict'

vim +8826 fs/nfsd/nfs4state.c

   8805	
   8806	/**
   8807	 * nfsd4_deleg_read_conflict - Recall if read causes conflict
   8808	 * @rqstp: RPC transaction context
   8809	 * @clp: nfs client
   8810	 * @fhp: nfs file handle
   8811	 * @inode: file to be checked for a conflict
   8812	 * @modified: return true if file was modified
   8813	 * @size: new size of file if modified is true
   8814	 *
   8815	 * This function is called when there is a conflict between a write
   8816	 * delegation and a read that is using a special stateid where the
   8817	 * we cannot derive the client stateid exsistence. The server
   8818	 * must recall a conflicting delegation before allowing the read
   8819	 * to continue.
   8820	 *
   8821	 * Returns 0 if there is no conflict; otherwise an nfs_stat
   8822	 * code is returned.
   8823	 */
   8824	__be32 nfsd4_deleg_read_conflict(struct svc_rqst *rqstp,
   8825			struct nfs4_client *clp, struct svc_fh *fhp)
8826	{
   8827		struct nfs4_file *fp;
   8828		__be32 status = 0;
   8829	
   8830		fp = nfsd4_file_hash_lookup(fhp);
   8831		if (!fp)
   8832			return nfs_ok;
   8833	
   8834		spin_lock(&state_lock);
   8835		spin_lock(&fp->fi_lock);
   8836		if (!list_empty(&fp->fi_delegations) &&
   8837		    !nfs4_delegation_exists(clp, fp)) {
   8838			/* conflict, recall deleg */
   8839			status = nfserrno(nfsd_open_break_lease(fp->fi_inode,
   8840						NFSD_MAY_READ));
   8841			if (status)
   8842				goto out;
   8843			if (!nfsd_wait_for_delegreturn(rqstp, fp->fi_inode))
   8844				status = nfserr_jukebox;
   8845		}
   8846	out:
   8847		spin_unlock(&fp->fi_lock);
   8848		spin_unlock(&state_lock);
   8849		return status;
   8850	}
   8851	


Its not clear what is the warning about here...




[Index of Archives]     [Linux Filesystem Development]     [Linux USB Development]     [Linux Media Development]     [Video for Linux]     [Linux NILFS]     [Linux Audio Users]     [Yosemite Info]     [Linux SCSI]

  Powered by Linux