All of lore.kernel.org
 help / color / mirror / Atom feed
* [cel:nfsd-testing 47/288] fs/nfsd/nfs4state.c:6197 nfsd4_deleg_recall_rejected() warn: inconsistent returns '&clp->cl_lock'.
@ 2026-10-19 19:26 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2026-10-19 19:26 UTC (permalink / raw)
  To: oe-kbuild; +Cc: lkp, Dan Carpenter

Unfiltered warning: this smatch report is sent as-is and has not been
reviewed for false positives, so please treat it with due skepticism.

BCC: lkp@intel.com
CC: oe-kbuild-all@lists.linux.dev
TO: Chuck Lever <cel@kernel.org>

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/cel/linux nfsd-testing
head:   b4e06bef38843c8b909d0b4317dfaaf87dba6d72
commit: bbfa823f624d41e85ebca929ac77dc2182cadfed [47/288] NFSD: Destroy a recalled delegation the client does not hold
:::::: branch date: 26 hours ago
:::::: commit date: 2 weeks ago
config: i386-randconfig-2200-20261019 (https://download.01.org/0day-ci/archive/20261019/202610192154.oZWxX8ca-lkp@intel.com/config)
compiler: gcc-14 (Debian 14.2.0-19) 14.2.0
smatch: v0.5.0-9187-g5189e3fb

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/202610192154.oZWxX8ca-lkp@intel.com/

New smatch warnings:
fs/nfsd/nfs4state.c:6197 nfsd4_deleg_recall_rejected() warn: inconsistent returns '&clp->cl_lock'.

Old smatch warnings:
fs/nfsd/nfs4state.c:9065 init_lock_stateid() warn: inconsistent returns '&stp->st_mutex'.

vim +6197 fs/nfsd/nfs4state.c

^1da177e4c3f41 Linus Torvalds 2005-04-16  6174  
bbfa823f624d41 Chuck Lever    2026-08-02  6175  /*
bbfa823f624d41 Chuck Lever    2026-08-02  6176   * cl_lock orders this against a laundromat reaping @dp: either
bbfa823f624d41 Chuck Lever    2026-08-02  6177   * revoke_delegation() observes dl_recall_rejected and destroys @dp, or
bbfa823f624d41 Chuck Lever    2026-08-02  6178   * it reached cl_revoked first and @dp is released here instead.
bbfa823f624d41 Chuck Lever    2026-08-02  6179   */
bbfa823f624d41 Chuck Lever    2026-08-02  6180  static void nfsd4_deleg_recall_rejected(struct nfs4_delegation *dp)
bbfa823f624d41 Chuck Lever    2026-08-02  6181  {
bbfa823f624d41 Chuck Lever    2026-08-02  6182  	struct nfs4_client *clp = dp->dl_stid.sc_client;
bbfa823f624d41 Chuck Lever    2026-08-02  6183  
bbfa823f624d41 Chuck Lever    2026-08-02  6184  	spin_lock(&clp->cl_lock);
bbfa823f624d41 Chuck Lever    2026-08-02  6185  	if (dp->dl_stid.sc_status & (SC_STATUS_CLOSED | SC_STATUS_FREED |
bbfa823f624d41 Chuck Lever    2026-08-02  6186  				     SC_STATUS_ADMIN_REVOKED)) {
bbfa823f624d41 Chuck Lever    2026-08-02  6187  		spin_unlock(&clp->cl_lock);
bbfa823f624d41 Chuck Lever    2026-08-02  6188  		return;
bbfa823f624d41 Chuck Lever    2026-08-02  6189  	}
bbfa823f624d41 Chuck Lever    2026-08-02  6190  	if (dp->dl_stid.sc_status & SC_STATUS_FREEABLE) {
bbfa823f624d41 Chuck Lever    2026-08-02  6191  		dp->dl_stid.sc_status |= SC_STATUS_CLOSED;
bbfa823f624d41 Chuck Lever    2026-08-02  6192  		/* this function drops ->cl_lock */
bbfa823f624d41 Chuck Lever    2026-08-02  6193  		nfsd4_drop_revoked_stid(&dp->dl_stid);
bbfa823f624d41 Chuck Lever    2026-08-02  6194  		return;
bbfa823f624d41 Chuck Lever    2026-08-02  6195  	}
bbfa823f624d41 Chuck Lever    2026-08-02  6196  	dp->dl_recall_rejected = true;
bbfa823f624d41 Chuck Lever    2026-08-02 @6197  	spin_unlock(&clp->cl_lock);
bbfa823f624d41 Chuck Lever    2026-08-02  6198  }
bbfa823f624d41 Chuck Lever    2026-08-02  6199  

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

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

only message in thread, other threads:[~2026-10-19 19:26 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-10-19 19:26 [cel:nfsd-testing 47/288] fs/nfsd/nfs4state.c:6197 nfsd4_deleg_recall_rejected() warn: inconsistent returns '&clp->cl_lock' 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.