Skip to content

Commit

Permalink
fs/file_table.c: Update alloc_file() comment
Browse files Browse the repository at this point in the history
This comment is 5 years outdated; init_file() no longer exists.

Signed-off-by: Eric Biggers <[email protected]>
Signed-off-by: Al Viro <[email protected]>
  • Loading branch information
ebiggers authored and Al Viro committed Oct 12, 2014
1 parent 8cc4311 commit a457606
Showing 1 changed file with 2 additions and 10 deletions.
12 changes: 2 additions & 10 deletions fs/file_table.c
Original file line number Diff line number Diff line change
Expand Up @@ -150,18 +150,10 @@ struct file *get_empty_filp(void)

/**
* alloc_file - allocate and initialize a 'struct file'
* @mnt: the vfsmount on which the file will reside
* @dentry: the dentry representing the new file
*
* @path: the (dentry, vfsmount) pair for the new file
* @mode: the mode with which the new file will be opened
* @fop: the 'struct file_operations' for the new file
*
* Use this instead of get_empty_filp() to get a new
* 'struct file'. Do so because of the same initialization
* pitfalls reasons listed for init_file(). This is a
* preferred interface to using init_file().
*
* If all the callers of init_file() are eliminated, its
* code should be moved into this function.
*/
struct file *alloc_file(struct path *path, fmode_t mode,
const struct file_operations *fop)
Expand Down

0 comments on commit a457606

Please sign in to comment.