aboutsummaryrefslogtreecommitdiffstats
path: root/fs/nfsd/vfs.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/nfsd/vfs.c')
-rw-r--r--fs/nfsd/vfs.c23
1 files changed, 13 insertions, 10 deletions
diff --git a/fs/nfsd/vfs.c b/fs/nfsd/vfs.c
index c827acb0e943..94b5f5d2bfed 100644
--- a/fs/nfsd/vfs.c
+++ b/fs/nfsd/vfs.c
@@ -427,7 +427,7 @@ nfsd_setattr(struct svc_rqst *rqstp, struct svc_fh *fhp, struct iattr *iap,
427 goto out_nfserr; 427 goto out_nfserr;
428 fh_lock(fhp); 428 fh_lock(fhp);
429 429
430 host_err = notify_change(dentry, iap); 430 host_err = notify_change(dentry, iap, NULL);
431 err = nfserrno(host_err); 431 err = nfserrno(host_err);
432 fh_unlock(fhp); 432 fh_unlock(fhp);
433 } 433 }
@@ -988,7 +988,11 @@ static void kill_suid(struct dentry *dentry)
988 ia.ia_valid = ATTR_KILL_SUID | ATTR_KILL_SGID | ATTR_KILL_PRIV; 988 ia.ia_valid = ATTR_KILL_SUID | ATTR_KILL_SGID | ATTR_KILL_PRIV;
989 989
990 mutex_lock(&dentry->d_inode->i_mutex); 990 mutex_lock(&dentry->d_inode->i_mutex);
991 notify_change(dentry, &ia); 991 /*
992 * Note we call this on write, so notify_change will not
993 * encounter any conflicting delegations:
994 */
995 notify_change(dentry, &ia, NULL);
992 mutex_unlock(&dentry->d_inode->i_mutex); 996 mutex_unlock(&dentry->d_inode->i_mutex);
993} 997}
994 998
@@ -1317,9 +1321,8 @@ nfsd_create(struct svc_rqst *rqstp, struct svc_fh *fhp,
1317 if (!fhp->fh_locked) { 1321 if (!fhp->fh_locked) {
1318 /* not actually possible */ 1322 /* not actually possible */
1319 printk(KERN_ERR 1323 printk(KERN_ERR
1320 "nfsd_create: parent %s/%s not locked!\n", 1324 "nfsd_create: parent %pd2 not locked!\n",
1321 dentry->d_parent->d_name.name, 1325 dentry);
1322 dentry->d_name.name);
1323 err = nfserr_io; 1326 err = nfserr_io;
1324 goto out; 1327 goto out;
1325 } 1328 }
@@ -1329,8 +1332,8 @@ nfsd_create(struct svc_rqst *rqstp, struct svc_fh *fhp,
1329 */ 1332 */
1330 err = nfserr_exist; 1333 err = nfserr_exist;
1331 if (dchild->d_inode) { 1334 if (dchild->d_inode) {
1332 dprintk("nfsd_create: dentry %s/%s not negative!\n", 1335 dprintk("nfsd_create: dentry %pd/%pd not negative!\n",
1333 dentry->d_name.name, dchild->d_name.name); 1336 dentry, dchild);
1334 goto out; 1337 goto out;
1335 } 1338 }
1336 1339
@@ -1737,7 +1740,7 @@ nfsd_link(struct svc_rqst *rqstp, struct svc_fh *ffhp,
1737 err = nfserrno(host_err); 1740 err = nfserrno(host_err);
1738 goto out_dput; 1741 goto out_dput;
1739 } 1742 }
1740 host_err = vfs_link(dold, dirp, dnew); 1743 host_err = vfs_link(dold, dirp, dnew, NULL);
1741 if (!host_err) { 1744 if (!host_err) {
1742 err = nfserrno(commit_metadata(ffhp)); 1745 err = nfserrno(commit_metadata(ffhp));
1743 if (!err) 1746 if (!err)
@@ -1838,7 +1841,7 @@ nfsd_rename(struct svc_rqst *rqstp, struct svc_fh *ffhp, char *fname, int flen,
1838 if (host_err) 1841 if (host_err)
1839 goto out_dput_new; 1842 goto out_dput_new;
1840 } 1843 }
1841 host_err = vfs_rename(fdir, odentry, tdir, ndentry); 1844 host_err = vfs_rename(fdir, odentry, tdir, ndentry, NULL);
1842 if (!host_err) { 1845 if (!host_err) {
1843 host_err = commit_metadata(tfhp); 1846 host_err = commit_metadata(tfhp);
1844 if (!host_err) 1847 if (!host_err)
@@ -1911,7 +1914,7 @@ nfsd_unlink(struct svc_rqst *rqstp, struct svc_fh *fhp, int type,
1911 if (host_err) 1914 if (host_err)
1912 goto out_put; 1915 goto out_put;
1913 if (type != S_IFDIR) 1916 if (type != S_IFDIR)
1914 host_err = vfs_unlink(dirp, rdentry); 1917 host_err = vfs_unlink(dirp, rdentry, NULL);
1915 else 1918 else
1916 host_err = vfs_rmdir(dirp, rdentry); 1919 host_err = vfs_rmdir(dirp, rdentry);
1917 if (!host_err) 1920 if (!host_err)