From: J. Bruce Fields Date: Wed, 13 Oct 2010 18:46:17 +0000 (-0400) Subject: nfsd: fix BUG at fs/nfsd/nfsfh.h:199 on unlink X-Git-Tag: v3.0~3158^2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=b1e86db1de2e8bc2be9fb94fae3451c2a776e8c1;p=platform%2Fkernel%2Flinux-amlogic.git nfsd: fix BUG at fs/nfsd/nfsfh.h:199 on unlink As of commit 43a9aa64a2f4330a9cb59aaf5c5636566bce067c "NFSD: Fill in WCC data for REMOVE, RMDIR, MKNOD, and MKDIR", we sometimes call fh_unlock on a filehandle that isn't fully initialized. We should fix up the callers, but as a quick fix it is also sufficient just to remove this assertion. Reported-by: Marius Tolzmann Cc: Chuck Lever Signed-off-by: J. Bruce Fields --- diff --git a/fs/nfsd/nfsfh.h b/fs/nfsd/nfsfh.h index cdfb8c6..c16f8d8 100644 --- a/fs/nfsd/nfsfh.h +++ b/fs/nfsd/nfsfh.h @@ -196,8 +196,6 @@ fh_lock(struct svc_fh *fhp) static inline void fh_unlock(struct svc_fh *fhp) { - BUG_ON(!fhp->fh_dentry); - if (fhp->fh_locked) { fill_post_wcc(fhp); mutex_unlock(&fhp->fh_dentry->d_inode->i_mutex);