aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNeilBrown <neilb@suse.de>2010-09-21 22:55:07 -0400
committerJ. Bruce Fields <bfields@redhat.com>2010-09-22 15:33:13 -0400
commitc67874f942e30039442d925b03793e0a46ddcddd (patch)
tree4f5def2f155c74181b015a13d563c1898b64d98a
parente95dffa4304186ad87963255f3e5e96b5c41849f (diff)
nfsd: formally deprecate legacy nfsd syscall interface
The syscall interface is has been replaced by a more flexible interface since 2.6.0. It is time to work towards discarding the old interface. So add a entry in feature-removal-schedule.txt and print a warning when the interface is used. Signed-off-by: NeilBrown <neilb@suse.de> Signed-off-by: J. Bruce Fields <bfields@redhat.com>
-rw-r--r--Documentation/feature-removal-schedule.txt10
-rw-r--r--fs/nfsd/nfsctl.c10
2 files changed, 20 insertions, 0 deletions
diff --git a/Documentation/feature-removal-schedule.txt b/Documentation/feature-removal-schedule.txt
index 842aa9de84a6..076a2c02adaf 100644
--- a/Documentation/feature-removal-schedule.txt
+++ b/Documentation/feature-removal-schedule.txt
@@ -564,3 +564,13 @@ Who: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
564 564
565---------------------------- 565----------------------------
566 566
567What: access to nfsd auth cache through sys_nfsservctl or '.' files
568 in the 'nfsd' filesystem.
569When: 2.6.40
570Why: This is a legacy interface which have been replaced by a more
571 dynamic cache. Continuing to maintain this interface is an
572 unnecessary burden.
573Who: NeilBrown <neilb@suse.de>
574
575----------------------------
576
diff --git a/fs/nfsd/nfsctl.c b/fs/nfsd/nfsctl.c
index b53b1d042f1f..7f0fc8861b85 100644
--- a/fs/nfsd/nfsctl.c
+++ b/fs/nfsd/nfsctl.c
@@ -121,6 +121,16 @@ static ssize_t nfsctl_transaction_write(struct file *file, const char __user *bu
121 121
122static ssize_t nfsctl_transaction_read(struct file *file, char __user *buf, size_t size, loff_t *pos) 122static ssize_t nfsctl_transaction_read(struct file *file, char __user *buf, size_t size, loff_t *pos)
123{ 123{
124 static int warned;
125 if (file->f_dentry->d_name.name[0] == '.' && !warned) {
126 char name[sizeof(current->comm)];
127 printk(KERN_INFO
128 "Warning: \"%s\" uses deprecated NFSD interface: %s."
129 " This will be removed in 2.6.40\n",
130 get_task_comm(name, current),
131 file->f_dentry->d_name.name);
132 warned = 1;
133 }
124 if (! file->private_data) { 134 if (! file->private_data) {
125 /* An attempt to read a transaction file without writing 135 /* An attempt to read a transaction file without writing
126 * causes a 0-byte write so that the file can return 136 * causes a 0-byte write so that the file can return