2006-01-13 01:01:17

by NeilBrown

[permalink] [raw]
Subject: [PATCH kNFSd 023 of 26] nfsd/vfs.c: endianness fixes


From: Al Viro <[email protected]>
Date: 1135476096 -0500

several failure exits return -E<something> instead of nfserr_<something>
and vice versa.

Signed-off-by: Al Viro <[email protected]>
Signed-off-by: Neil Brown <[email protected]>

### Diffstat output
./fs/nfsd/vfs.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)

diff ./fs/nfsd/vfs.c~current~ ./fs/nfsd/vfs.c
--- ./fs/nfsd/vfs.c~current~ 2006-01-13 11:50:54.000000000 +1100
+++ ./fs/nfsd/vfs.c 2006-01-13 11:51:10.000000000 +1100
@@ -1134,7 +1134,7 @@ nfsd_create(struct svc_rqst *rqstp, stru
"nfsd_create: parent %s/%s not locked!\n",
dentry->d_parent->d_name.name,
dentry->d_name.name);
- err = -EIO;
+ err = nfserr_io;
goto out;
}
}
@@ -1600,7 +1600,7 @@ nfsd_rename(struct svc_rqst *rqstp, stru
if ((ffhp->fh_export->ex_flags & NFSEXP_MSNFS) &&
((atomic_read(&odentry->d_count) > 1)
|| (atomic_read(&ndentry->d_count) > 1))) {
- err = nfserr_perm;
+ err = -EPERM;
} else
#endif
err = vfs_rename(fdir, odentry, tdir, ndentry);
@@ -1672,7 +1672,7 @@ nfsd_unlink(struct svc_rqst *rqstp, stru
#ifdef MSNFS
if ((fhp->fh_export->ex_flags & NFSEXP_MSNFS) &&
(atomic_read(&rdentry->d_count) > 1)) {
- err = nfserr_perm;
+ err = -EPERM;
} else
#endif
err = vfs_unlink(dirp, rdentry);


-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems? Stop! Download the new AJAX search engine that makes
searching your log files as easy as surfing the web. DOWNLOAD SPLUNK!
http://ads.osdn.com/?ad_id=7637&alloc_id=16865&op=click
_______________________________________________
NFS maillist - [email protected]
https://lists.sourceforge.net/lists/listinfo/nfs