Skip to content

Commit

Permalink
vfs: make no_llseek the default
Browse files Browse the repository at this point in the history
All file operations now have an explicit .llseek
operation pointer, so we can change the default
action for future code.

This makes changes the default from default_llseek
to no_llseek, which always returns -ESPIPE if
a user tries to seek on a file without a .llseek
operation.

The name of the default_llseek function remains
unchanged, if anyone thinks we should change it,
please speak up.

Signed-off-by: Arnd Bergmann <[email protected]>
Cc: Christoph Hellwig <[email protected]>
Cc: Al Viro <[email protected]>
Cc: [email protected]
  • Loading branch information
arndb committed Oct 15, 2010
1 parent ab91261 commit 776c163
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion fs/read_write.c
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,6 @@ loff_t vfs_llseek(struct file *file, loff_t offset, int origin)

fn = no_llseek;
if (file->f_mode & FMODE_LSEEK) {
fn = default_llseek;
if (file->f_op && file->f_op->llseek)
fn = file->f_op->llseek;
}
Expand Down

0 comments on commit 776c163

Please sign in to comment.