Commit 5b6a599f authored by bookjovi@gmail.com's avatar bookjovi@gmail.com Committed by J. Bruce Fields

nfs: add missed CONFIG_NFSD_DEPRECATED

these pieces of code only make sense when CONFIG_NFSD_DEPRECATED enabled
Signed-off-by: default avatarJovi Zhang <bookjovi@gmail.com>

 fs/nfsd/nfsctl.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)
Signed-off-by: default avatarJ. Bruce Fields <bfields@redhat.com>
parent 3942302e
...@@ -127,6 +127,7 @@ static ssize_t nfsctl_transaction_write(struct file *file, const char __user *bu ...@@ -127,6 +127,7 @@ static ssize_t nfsctl_transaction_write(struct file *file, const char __user *bu
static ssize_t nfsctl_transaction_read(struct file *file, char __user *buf, size_t size, loff_t *pos) static ssize_t nfsctl_transaction_read(struct file *file, char __user *buf, size_t size, loff_t *pos)
{ {
#ifdef CONFIG_NFSD_DEPRECATED
static int warned; static int warned;
if (file->f_dentry->d_name.name[0] == '.' && !warned) { if (file->f_dentry->d_name.name[0] == '.' && !warned) {
printk(KERN_INFO printk(KERN_INFO
...@@ -135,6 +136,7 @@ static ssize_t nfsctl_transaction_read(struct file *file, char __user *buf, size ...@@ -135,6 +136,7 @@ static ssize_t nfsctl_transaction_read(struct file *file, char __user *buf, size
current->comm, file->f_dentry->d_name.name); current->comm, file->f_dentry->d_name.name);
warned = 1; warned = 1;
} }
#endif
if (! file->private_data) { if (! file->private_data) {
/* An attempt to read a transaction file without writing /* An attempt to read a transaction file without writing
* causes a 0-byte write so that the file can return * causes a 0-byte write so that the file can return
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment