提交 b4d1ab58 编写于 作者: J Josef Sipek 提交者: Linus Torvalds

[PATCH] struct path: convert powerpc

Signed-off-by: NJosef Sipek <jsipek@fsl.cs.sunysb.edu>
Signed-off-by: NAndrew Morton <akpm@osdl.org>
Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
上级 40fad04b
...@@ -83,7 +83,7 @@ __initcall(proc_ppc64_init); ...@@ -83,7 +83,7 @@ __initcall(proc_ppc64_init);
static loff_t page_map_seek( struct file *file, loff_t off, int whence) static loff_t page_map_seek( struct file *file, loff_t off, int whence)
{ {
loff_t new; loff_t new;
struct proc_dir_entry *dp = PDE(file->f_dentry->d_inode); struct proc_dir_entry *dp = PDE(file->f_path.dentry->d_inode);
switch(whence) { switch(whence) {
case 0: case 0:
...@@ -106,13 +106,13 @@ static loff_t page_map_seek( struct file *file, loff_t off, int whence) ...@@ -106,13 +106,13 @@ static loff_t page_map_seek( struct file *file, loff_t off, int whence)
static ssize_t page_map_read( struct file *file, char __user *buf, size_t nbytes, static ssize_t page_map_read( struct file *file, char __user *buf, size_t nbytes,
loff_t *ppos) loff_t *ppos)
{ {
struct proc_dir_entry *dp = PDE(file->f_dentry->d_inode); struct proc_dir_entry *dp = PDE(file->f_path.dentry->d_inode);
return simple_read_from_buffer(buf, nbytes, ppos, dp->data, dp->size); return simple_read_from_buffer(buf, nbytes, ppos, dp->data, dp->size);
} }
static int page_map_mmap( struct file *file, struct vm_area_struct *vma ) static int page_map_mmap( struct file *file, struct vm_area_struct *vma )
{ {
struct proc_dir_entry *dp = PDE(file->f_dentry->d_inode); struct proc_dir_entry *dp = PDE(file->f_path.dentry->d_inode);
if ((vma->vm_end - vma->vm_start) > dp->size) if ((vma->vm_end - vma->vm_start) > dp->size)
return -EINVAL; return -EINVAL;
......
...@@ -193,7 +193,7 @@ static void free_flash_list(struct flash_block_list *f) ...@@ -193,7 +193,7 @@ static void free_flash_list(struct flash_block_list *f)
static int rtas_flash_release(struct inode *inode, struct file *file) static int rtas_flash_release(struct inode *inode, struct file *file)
{ {
struct proc_dir_entry *dp = PDE(file->f_dentry->d_inode); struct proc_dir_entry *dp = PDE(file->f_path.dentry->d_inode);
struct rtas_update_flash_t *uf; struct rtas_update_flash_t *uf;
uf = (struct rtas_update_flash_t *) dp->data; uf = (struct rtas_update_flash_t *) dp->data;
...@@ -255,7 +255,7 @@ static void get_flash_status_msg(int status, char *buf) ...@@ -255,7 +255,7 @@ static void get_flash_status_msg(int status, char *buf)
static ssize_t rtas_flash_read(struct file *file, char __user *buf, static ssize_t rtas_flash_read(struct file *file, char __user *buf,
size_t count, loff_t *ppos) size_t count, loff_t *ppos)
{ {
struct proc_dir_entry *dp = PDE(file->f_dentry->d_inode); struct proc_dir_entry *dp = PDE(file->f_path.dentry->d_inode);
struct rtas_update_flash_t *uf; struct rtas_update_flash_t *uf;
char msg[RTAS_MSG_MAXLEN]; char msg[RTAS_MSG_MAXLEN];
int msglen; int msglen;
...@@ -299,7 +299,7 @@ void rtas_block_ctor(void *ptr, struct kmem_cache *cache, unsigned long flags) ...@@ -299,7 +299,7 @@ void rtas_block_ctor(void *ptr, struct kmem_cache *cache, unsigned long flags)
static ssize_t rtas_flash_write(struct file *file, const char __user *buffer, static ssize_t rtas_flash_write(struct file *file, const char __user *buffer,
size_t count, loff_t *off) size_t count, loff_t *off)
{ {
struct proc_dir_entry *dp = PDE(file->f_dentry->d_inode); struct proc_dir_entry *dp = PDE(file->f_path.dentry->d_inode);
struct rtas_update_flash_t *uf; struct rtas_update_flash_t *uf;
char *p; char *p;
int next_free; int next_free;
...@@ -391,7 +391,7 @@ static void manage_flash(struct rtas_manage_flash_t *args_buf) ...@@ -391,7 +391,7 @@ static void manage_flash(struct rtas_manage_flash_t *args_buf)
static ssize_t manage_flash_read(struct file *file, char __user *buf, static ssize_t manage_flash_read(struct file *file, char __user *buf,
size_t count, loff_t *ppos) size_t count, loff_t *ppos)
{ {
struct proc_dir_entry *dp = PDE(file->f_dentry->d_inode); struct proc_dir_entry *dp = PDE(file->f_path.dentry->d_inode);
struct rtas_manage_flash_t *args_buf; struct rtas_manage_flash_t *args_buf;
char msg[RTAS_MSG_MAXLEN]; char msg[RTAS_MSG_MAXLEN];
int msglen; int msglen;
...@@ -421,7 +421,7 @@ static ssize_t manage_flash_read(struct file *file, char __user *buf, ...@@ -421,7 +421,7 @@ static ssize_t manage_flash_read(struct file *file, char __user *buf,
static ssize_t manage_flash_write(struct file *file, const char __user *buf, static ssize_t manage_flash_write(struct file *file, const char __user *buf,
size_t count, loff_t *off) size_t count, loff_t *off)
{ {
struct proc_dir_entry *dp = PDE(file->f_dentry->d_inode); struct proc_dir_entry *dp = PDE(file->f_path.dentry->d_inode);
struct rtas_manage_flash_t *args_buf; struct rtas_manage_flash_t *args_buf;
const char reject_str[] = "0"; const char reject_str[] = "0";
const char commit_str[] = "1"; const char commit_str[] = "1";
...@@ -492,7 +492,7 @@ static int get_validate_flash_msg(struct rtas_validate_flash_t *args_buf, ...@@ -492,7 +492,7 @@ static int get_validate_flash_msg(struct rtas_validate_flash_t *args_buf,
static ssize_t validate_flash_read(struct file *file, char __user *buf, static ssize_t validate_flash_read(struct file *file, char __user *buf,
size_t count, loff_t *ppos) size_t count, loff_t *ppos)
{ {
struct proc_dir_entry *dp = PDE(file->f_dentry->d_inode); struct proc_dir_entry *dp = PDE(file->f_path.dentry->d_inode);
struct rtas_validate_flash_t *args_buf; struct rtas_validate_flash_t *args_buf;
char msg[RTAS_MSG_MAXLEN]; char msg[RTAS_MSG_MAXLEN];
int msglen; int msglen;
...@@ -520,7 +520,7 @@ static ssize_t validate_flash_read(struct file *file, char __user *buf, ...@@ -520,7 +520,7 @@ static ssize_t validate_flash_read(struct file *file, char __user *buf,
static ssize_t validate_flash_write(struct file *file, const char __user *buf, static ssize_t validate_flash_write(struct file *file, const char __user *buf,
size_t count, loff_t *off) size_t count, loff_t *off)
{ {
struct proc_dir_entry *dp = PDE(file->f_dentry->d_inode); struct proc_dir_entry *dp = PDE(file->f_path.dentry->d_inode);
struct rtas_validate_flash_t *args_buf; struct rtas_validate_flash_t *args_buf;
int rc; int rc;
...@@ -569,7 +569,7 @@ static ssize_t validate_flash_write(struct file *file, const char __user *buf, ...@@ -569,7 +569,7 @@ static ssize_t validate_flash_write(struct file *file, const char __user *buf,
static int validate_flash_release(struct inode *inode, struct file *file) static int validate_flash_release(struct inode *inode, struct file *file)
{ {
struct proc_dir_entry *dp = PDE(file->f_dentry->d_inode); struct proc_dir_entry *dp = PDE(file->f_path.dentry->d_inode);
struct rtas_validate_flash_t *args_buf; struct rtas_validate_flash_t *args_buf;
args_buf = (struct rtas_validate_flash_t *) dp->data; args_buf = (struct rtas_validate_flash_t *) dp->data;
......
...@@ -205,7 +205,7 @@ static int spufs_dir_close(struct inode *inode, struct file *file) ...@@ -205,7 +205,7 @@ static int spufs_dir_close(struct inode *inode, struct file *file)
struct dentry *dir; struct dentry *dir;
int ret; int ret;
dir = file->f_dentry; dir = file->f_path.dentry;
parent = dir->d_parent->d_inode; parent = dir->d_parent->d_inode;
ctx = SPUFS_I(dir->d_inode)->i_ctx; ctx = SPUFS_I(dir->d_inode)->i_ctx;
...@@ -363,7 +363,7 @@ static int spufs_gang_close(struct inode *inode, struct file *file) ...@@ -363,7 +363,7 @@ static int spufs_gang_close(struct inode *inode, struct file *file)
struct dentry *dir; struct dentry *dir;
int ret; int ret;
dir = file->f_dentry; dir = file->f_path.dentry;
parent = dir->d_parent->d_inode; parent = dir->d_parent->d_inode;
ret = spufs_rmgang(parent, dir); ret = spufs_rmgang(parent, dir);
......
...@@ -46,7 +46,7 @@ static long do_spu_run(struct file *filp, ...@@ -46,7 +46,7 @@ static long do_spu_run(struct file *filp,
if (filp->f_op != &spufs_context_fops) if (filp->f_op != &spufs_context_fops)
goto out; goto out;
i = SPUFS_I(filp->f_dentry->d_inode); i = SPUFS_I(filp->f_path.dentry->d_inode);
ret = spufs_run_spu(filp, i->i_ctx, &npc, &status); ret = spufs_run_spu(filp, i->i_ctx, &npc, &status);
if (put_user(npc, unpc)) if (put_user(npc, unpc))
......
...@@ -1178,7 +1178,7 @@ static ssize_t proc_mf_change_vmlinux(struct file *file, ...@@ -1178,7 +1178,7 @@ static ssize_t proc_mf_change_vmlinux(struct file *file,
const char __user *buf, const char __user *buf,
size_t count, loff_t *ppos) size_t count, loff_t *ppos)
{ {
struct proc_dir_entry *dp = PDE(file->f_dentry->d_inode); struct proc_dir_entry *dp = PDE(file->f_path.dentry->d_inode);
ssize_t rc; ssize_t rc;
dma_addr_t dma_addr; dma_addr_t dma_addr;
char *page; char *page;
......
...@@ -85,7 +85,7 @@ static int hcall_inst_seq_open(struct inode *inode, struct file *file) ...@@ -85,7 +85,7 @@ static int hcall_inst_seq_open(struct inode *inode, struct file *file)
rc = seq_open(file, &hcall_inst_seq_ops); rc = seq_open(file, &hcall_inst_seq_ops);
seq = file->private_data; seq = file->private_data;
seq->private = file->f_dentry->d_inode->i_private; seq->private = file->f_path.dentry->d_inode->i_private;
return rc; return rc;
} }
......
...@@ -47,7 +47,7 @@ static struct proc_dir_entry *proc_ppc64_scan_log_dump; /* The proc file */ ...@@ -47,7 +47,7 @@ static struct proc_dir_entry *proc_ppc64_scan_log_dump; /* The proc file */
static ssize_t scanlog_read(struct file *file, char __user *buf, static ssize_t scanlog_read(struct file *file, char __user *buf,
size_t count, loff_t *ppos) size_t count, loff_t *ppos)
{ {
struct inode * inode = file->f_dentry->d_inode; struct inode * inode = file->f_path.dentry->d_inode;
struct proc_dir_entry *dp; struct proc_dir_entry *dp;
unsigned int *data; unsigned int *data;
int status; int status;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册