aboutsummaryrefslogtreecommitdiffstats
path: root/fs/efs
diff options
context:
space:
mode:
authorJonathan Herman <hermanjl@cs.unc.edu>2013-01-17 16:15:55 -0500
committerJonathan Herman <hermanjl@cs.unc.edu>2013-01-17 16:15:55 -0500
commit8dea78da5cee153b8af9c07a2745f6c55057fe12 (patch)
treea8f4d49d63b1ecc92f2fddceba0655b2472c5bd9 /fs/efs
parent406089d01562f1e2bf9f089fd7637009ebaad589 (diff)
Patched in Tegra support.
Diffstat (limited to 'fs/efs')
-rw-r--r--fs/efs/efs.h2
-rw-r--r--fs/efs/inode.c6
-rw-r--r--fs/efs/namei.c3
-rw-r--r--fs/efs/super.c9
4 files changed, 8 insertions, 12 deletions
diff --git a/fs/efs/efs.h b/fs/efs/efs.h
index 5528926ac7f..d8305b582ab 100644
--- a/fs/efs/efs.h
+++ b/fs/efs/efs.h
@@ -129,7 +129,7 @@ extern struct inode *efs_iget(struct super_block *, unsigned long);
129extern efs_block_t efs_map_block(struct inode *, efs_block_t); 129extern efs_block_t efs_map_block(struct inode *, efs_block_t);
130extern int efs_get_block(struct inode *, sector_t, struct buffer_head *, int); 130extern int efs_get_block(struct inode *, sector_t, struct buffer_head *, int);
131 131
132extern struct dentry *efs_lookup(struct inode *, struct dentry *, unsigned int); 132extern struct dentry *efs_lookup(struct inode *, struct dentry *, struct nameidata *);
133extern struct dentry *efs_fh_to_dentry(struct super_block *sb, struct fid *fid, 133extern struct dentry *efs_fh_to_dentry(struct super_block *sb, struct fid *fid,
134 int fh_len, int fh_type); 134 int fh_len, int fh_type);
135extern struct dentry *efs_fh_to_parent(struct super_block *sb, struct fid *fid, 135extern struct dentry *efs_fh_to_parent(struct super_block *sb, struct fid *fid,
diff --git a/fs/efs/inode.c b/fs/efs/inode.c
index f3913eb2c47..9c13412e6c9 100644
--- a/fs/efs/inode.c
+++ b/fs/efs/inode.c
@@ -96,9 +96,9 @@ struct inode *efs_iget(struct super_block *super, unsigned long ino)
96 efs_inode = (struct efs_dinode *) (bh->b_data + offset); 96 efs_inode = (struct efs_dinode *) (bh->b_data + offset);
97 97
98 inode->i_mode = be16_to_cpu(efs_inode->di_mode); 98 inode->i_mode = be16_to_cpu(efs_inode->di_mode);
99 set_nlink(inode, be16_to_cpu(efs_inode->di_nlink)); 99 inode->i_nlink = be16_to_cpu(efs_inode->di_nlink);
100 i_uid_write(inode, (uid_t)be16_to_cpu(efs_inode->di_uid)); 100 inode->i_uid = (uid_t)be16_to_cpu(efs_inode->di_uid);
101 i_gid_write(inode, (gid_t)be16_to_cpu(efs_inode->di_gid)); 101 inode->i_gid = (gid_t)be16_to_cpu(efs_inode->di_gid);
102 inode->i_size = be32_to_cpu(efs_inode->di_size); 102 inode->i_size = be32_to_cpu(efs_inode->di_size);
103 inode->i_atime.tv_sec = be32_to_cpu(efs_inode->di_atime); 103 inode->i_atime.tv_sec = be32_to_cpu(efs_inode->di_atime);
104 inode->i_mtime.tv_sec = be32_to_cpu(efs_inode->di_mtime); 104 inode->i_mtime.tv_sec = be32_to_cpu(efs_inode->di_mtime);
diff --git a/fs/efs/namei.c b/fs/efs/namei.c
index 96f66d213a1..832b10ded82 100644
--- a/fs/efs/namei.c
+++ b/fs/efs/namei.c
@@ -58,8 +58,7 @@ static efs_ino_t efs_find_entry(struct inode *inode, const char *name, int len)
58 return(0); 58 return(0);
59} 59}
60 60
61struct dentry *efs_lookup(struct inode *dir, struct dentry *dentry, unsigned int flags) 61struct dentry *efs_lookup(struct inode *dir, struct dentry *dentry, struct nameidata *nd) {
62{
63 efs_ino_t inodenum; 62 efs_ino_t inodenum;
64 struct inode *inode = NULL; 63 struct inode *inode = NULL;
65 64
diff --git a/fs/efs/super.c b/fs/efs/super.c
index 2002431ef9a..0f31acb0131 100644
--- a/fs/efs/super.c
+++ b/fs/efs/super.c
@@ -68,6 +68,7 @@ static struct inode *efs_alloc_inode(struct super_block *sb)
68static void efs_i_callback(struct rcu_head *head) 68static void efs_i_callback(struct rcu_head *head)
69{ 69{
70 struct inode *inode = container_of(head, struct inode, i_rcu); 70 struct inode *inode = container_of(head, struct inode, i_rcu);
71 INIT_LIST_HEAD(&inode->i_dentry);
71 kmem_cache_free(efs_inode_cachep, INODE_INFO(inode)); 72 kmem_cache_free(efs_inode_cachep, INODE_INFO(inode));
72} 73}
73 74
@@ -96,11 +97,6 @@ static int init_inodecache(void)
96 97
97static void destroy_inodecache(void) 98static void destroy_inodecache(void)
98{ 99{
99 /*
100 * Make sure all delayed rcu free inodes are flushed before we
101 * destroy cache.
102 */
103 rcu_barrier();
104 kmem_cache_destroy(efs_inode_cachep); 100 kmem_cache_destroy(efs_inode_cachep);
105} 101}
106 102
@@ -322,9 +318,10 @@ static int efs_fill_super(struct super_block *s, void *d, int silent)
322 goto out_no_fs; 318 goto out_no_fs;
323 } 319 }
324 320
325 s->s_root = d_make_root(root); 321 s->s_root = d_alloc_root(root);
326 if (!(s->s_root)) { 322 if (!(s->s_root)) {
327 printk(KERN_ERR "EFS: get root dentry failed\n"); 323 printk(KERN_ERR "EFS: get root dentry failed\n");
324 iput(root);
328 ret = -ENOMEM; 325 ret = -ENOMEM;
329 goto out_no_fs; 326 goto out_no_fs;
330 } 327 }