Commit 867fa491 authored by Josef "Jeff" Sipek's avatar Josef "Jeff" Sipek Committed by Linus Torvalds

[PATCH] configfs: change uses of f_{dentry, vfsmnt} to use f_path

Change all the uses of f_{dentry,vfsmnt} to f_path.{dentry,mnt} in the
configfs filesystem.
Signed-off-by: default avatarJosef "Jeff" Sipek <jsipek@cs.sunysb.edu>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent a4669ed8
...@@ -980,7 +980,7 @@ int configfs_rename_dir(struct config_item * item, const char *new_name) ...@@ -980,7 +980,7 @@ int configfs_rename_dir(struct config_item * item, const char *new_name)
static int configfs_dir_open(struct inode *inode, struct file *file) static int configfs_dir_open(struct inode *inode, struct file *file)
{ {
struct dentry * dentry = file->f_dentry; struct dentry * dentry = file->f_path.dentry;
struct configfs_dirent * parent_sd = dentry->d_fsdata; struct configfs_dirent * parent_sd = dentry->d_fsdata;
mutex_lock(&dentry->d_inode->i_mutex); mutex_lock(&dentry->d_inode->i_mutex);
...@@ -993,7 +993,7 @@ static int configfs_dir_open(struct inode *inode, struct file *file) ...@@ -993,7 +993,7 @@ static int configfs_dir_open(struct inode *inode, struct file *file)
static int configfs_dir_close(struct inode *inode, struct file *file) static int configfs_dir_close(struct inode *inode, struct file *file)
{ {
struct dentry * dentry = file->f_dentry; struct dentry * dentry = file->f_path.dentry;
struct configfs_dirent * cursor = file->private_data; struct configfs_dirent * cursor = file->private_data;
mutex_lock(&dentry->d_inode->i_mutex); mutex_lock(&dentry->d_inode->i_mutex);
...@@ -1013,7 +1013,7 @@ static inline unsigned char dt_type(struct configfs_dirent *sd) ...@@ -1013,7 +1013,7 @@ static inline unsigned char dt_type(struct configfs_dirent *sd)
static int configfs_readdir(struct file * filp, void * dirent, filldir_t filldir) static int configfs_readdir(struct file * filp, void * dirent, filldir_t filldir)
{ {
struct dentry *dentry = filp->f_dentry; struct dentry *dentry = filp->f_path.dentry;
struct configfs_dirent * parent_sd = dentry->d_fsdata; struct configfs_dirent * parent_sd = dentry->d_fsdata;
struct configfs_dirent *cursor = filp->private_data; struct configfs_dirent *cursor = filp->private_data;
struct list_head *p, *q = &cursor->s_sibling; struct list_head *p, *q = &cursor->s_sibling;
...@@ -1070,7 +1070,7 @@ static int configfs_readdir(struct file * filp, void * dirent, filldir_t filldir ...@@ -1070,7 +1070,7 @@ static int configfs_readdir(struct file * filp, void * dirent, filldir_t filldir
static loff_t configfs_dir_lseek(struct file * file, loff_t offset, int origin) static loff_t configfs_dir_lseek(struct file * file, loff_t offset, int origin)
{ {
struct dentry * dentry = file->f_dentry; struct dentry * dentry = file->f_path.dentry;
mutex_lock(&dentry->d_inode->i_mutex); mutex_lock(&dentry->d_inode->i_mutex);
switch (origin) { switch (origin) {
...@@ -1080,7 +1080,7 @@ static loff_t configfs_dir_lseek(struct file * file, loff_t offset, int origin) ...@@ -1080,7 +1080,7 @@ static loff_t configfs_dir_lseek(struct file * file, loff_t offset, int origin)
if (offset >= 0) if (offset >= 0)
break; break;
default: default:
mutex_unlock(&file->f_dentry->d_inode->i_mutex); mutex_unlock(&file->f_path.dentry->d_inode->i_mutex);
return -EINVAL; return -EINVAL;
} }
if (offset != file->f_pos) { if (offset != file->f_pos) {
......
...@@ -134,7 +134,7 @@ configfs_read_file(struct file *file, char __user *buf, size_t count, loff_t *pp ...@@ -134,7 +134,7 @@ configfs_read_file(struct file *file, char __user *buf, size_t count, loff_t *pp
down(&buffer->sem); down(&buffer->sem);
if (buffer->needs_read_fill) { if (buffer->needs_read_fill) {
if ((retval = fill_read_buffer(file->f_dentry,buffer))) if ((retval = fill_read_buffer(file->f_path.dentry,buffer)))
goto out; goto out;
} }
pr_debug("%s: count = %zd, ppos = %lld, buf = %s\n", pr_debug("%s: count = %zd, ppos = %lld, buf = %s\n",
...@@ -222,7 +222,7 @@ configfs_write_file(struct file *file, const char __user *buf, size_t count, lof ...@@ -222,7 +222,7 @@ configfs_write_file(struct file *file, const char __user *buf, size_t count, lof
down(&buffer->sem); down(&buffer->sem);
len = fill_write_buffer(buffer, buf, count); len = fill_write_buffer(buffer, buf, count);
if (len > 0) if (len > 0)
len = flush_write_buffer(file->f_dentry, buffer, count); len = flush_write_buffer(file->f_path.dentry, buffer, count);
if (len > 0) if (len > 0)
*ppos += len; *ppos += len;
up(&buffer->sem); up(&buffer->sem);
...@@ -231,8 +231,8 @@ configfs_write_file(struct file *file, const char __user *buf, size_t count, lof ...@@ -231,8 +231,8 @@ configfs_write_file(struct file *file, const char __user *buf, size_t count, lof
static int check_perm(struct inode * inode, struct file * file) static int check_perm(struct inode * inode, struct file * file)
{ {
struct config_item *item = configfs_get_config_item(file->f_dentry->d_parent); struct config_item *item = configfs_get_config_item(file->f_path.dentry->d_parent);
struct configfs_attribute * attr = to_attr(file->f_dentry); struct configfs_attribute * attr = to_attr(file->f_path.dentry);
struct configfs_buffer * buffer; struct configfs_buffer * buffer;
struct configfs_item_operations * ops = NULL; struct configfs_item_operations * ops = NULL;
int error = 0; int error = 0;
...@@ -305,8 +305,8 @@ static int configfs_open_file(struct inode * inode, struct file * filp) ...@@ -305,8 +305,8 @@ static int configfs_open_file(struct inode * inode, struct file * filp)
static int configfs_release(struct inode * inode, struct file * filp) static int configfs_release(struct inode * inode, struct file * filp)
{ {
struct config_item * item = to_item(filp->f_dentry->d_parent); struct config_item * item = to_item(filp->f_path.dentry->d_parent);
struct configfs_attribute * attr = to_attr(filp->f_dentry); struct configfs_attribute * attr = to_attr(filp->f_path.dentry);
struct module * owner = attr->ca_owner; struct module * owner = attr->ca_owner;
struct configfs_buffer * buffer = filp->private_data; struct configfs_buffer * buffer = filp->private_data;
......
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