summaryrefslogtreecommitdiff
path: root/fs
diff options
context:
space:
mode:
Diffstat (limited to 'fs')
-rw-r--r--fs/file_table.c2
-rw-r--r--fs/open.c2
-rw-r--r--fs/read_write.c6
3 files changed, 1 insertions, 9 deletions
diff --git a/fs/file_table.c b/fs/file_table.c
index 0658b822beeb..5727a63a7b67 100644
--- a/fs/file_table.c
+++ b/fs/file_table.c
@@ -235,7 +235,7 @@ static struct file *alloc_file(const struct path *path, int flags,
file->f_mapping = path->dentry->d_inode->i_mapping;
file->f_wb_err = filemap_sample_wb_err(file->f_mapping);
file->f_sb_err = file_sample_sb_err(file);
- if (fop->llseek && fop->llseek != no_llseek)
+ if (fop->llseek)
file->f_mode |= FMODE_LSEEK;
if ((file->f_mode & FMODE_READ) &&
likely(fop->read || fop->read_iter))
diff --git a/fs/open.c b/fs/open.c
index 4488bd77c390..07c332753a36 100644
--- a/fs/open.c
+++ b/fs/open.c
@@ -860,8 +860,6 @@ static int do_dentry_open(struct file *f,
f->f_mode |= FMODE_CAN_WRITE;
if ((f->f_mode & FMODE_LSEEK) && !f->f_op->llseek)
f->f_mode &= ~FMODE_LSEEK;
- if ((f->f_mode & FMODE_LSEEK) && f->f_op->llseek == no_llseek)
- f->f_mode &= ~FMODE_LSEEK;
if (f->f_mapping->a_ops && f->f_mapping->a_ops->direct_IO)
f->f_mode |= FMODE_CAN_ODIRECT;
diff --git a/fs/read_write.c b/fs/read_write.c
index d94b6dbba6f9..6b2849b34781 100644
--- a/fs/read_write.c
+++ b/fs/read_write.c
@@ -227,12 +227,6 @@ loff_t noop_llseek(struct file *file, loff_t offset, int whence)
}
EXPORT_SYMBOL(noop_llseek);
-loff_t no_llseek(struct file *file, loff_t offset, int whence)
-{
- return -ESPIPE;
-}
-EXPORT_SYMBOL(no_llseek);
-
loff_t default_llseek(struct file *file, loff_t offset, int whence)
{
struct inode *inode = file_inode(file);