diff options
Diffstat (limited to 'fs/9p/vfs_super.c')
-rw-r--r-- | fs/9p/vfs_super.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/fs/9p/vfs_super.c b/fs/9p/vfs_super.c index 82c5b0084079..ae0f06b3c11a 100644 --- a/fs/9p/vfs_super.c +++ b/fs/9p/vfs_super.c | |||
@@ -44,7 +44,6 @@ | |||
44 | #include "v9fs.h" | 44 | #include "v9fs.h" |
45 | #include "9p.h" | 45 | #include "9p.h" |
46 | #include "v9fs_vfs.h" | 46 | #include "v9fs_vfs.h" |
47 | #include "conv.h" | ||
48 | #include "fid.h" | 47 | #include "fid.h" |
49 | 48 | ||
50 | static void v9fs_clear_inode(struct inode *); | 49 | static void v9fs_clear_inode(struct inode *); |
@@ -123,12 +122,13 @@ static struct super_block *v9fs_get_sb(struct file_system_type | |||
123 | 122 | ||
124 | dprintk(DEBUG_VFS, " \n"); | 123 | dprintk(DEBUG_VFS, " \n"); |
125 | 124 | ||
126 | v9ses = kcalloc(1, sizeof(struct v9fs_session_info), GFP_KERNEL); | 125 | v9ses = kzalloc(sizeof(struct v9fs_session_info), GFP_KERNEL); |
127 | if (!v9ses) | 126 | if (!v9ses) |
128 | return ERR_PTR(-ENOMEM); | 127 | return ERR_PTR(-ENOMEM); |
129 | 128 | ||
130 | if ((newfid = v9fs_session_init(v9ses, dev_name, data)) < 0) { | 129 | if ((newfid = v9fs_session_init(v9ses, dev_name, data)) < 0) { |
131 | dprintk(DEBUG_ERROR, "problem initiating session\n"); | 130 | dprintk(DEBUG_ERROR, "problem initiating session\n"); |
131 | kfree(v9ses); | ||
132 | return ERR_PTR(newfid); | 132 | return ERR_PTR(newfid); |
133 | } | 133 | } |
134 | 134 | ||
@@ -157,7 +157,7 @@ static struct super_block *v9fs_get_sb(struct file_system_type | |||
157 | stat_result = v9fs_t_stat(v9ses, newfid, &fcall); | 157 | stat_result = v9fs_t_stat(v9ses, newfid, &fcall); |
158 | if (stat_result < 0) { | 158 | if (stat_result < 0) { |
159 | dprintk(DEBUG_ERROR, "stat error\n"); | 159 | dprintk(DEBUG_ERROR, "stat error\n"); |
160 | v9fs_t_clunk(v9ses, newfid, NULL); | 160 | v9fs_t_clunk(v9ses, newfid); |
161 | v9fs_put_idpool(newfid, &v9ses->fidpool); | 161 | v9fs_put_idpool(newfid, &v9ses->fidpool); |
162 | } else { | 162 | } else { |
163 | /* Setup the Root Inode */ | 163 | /* Setup the Root Inode */ |
@@ -167,10 +167,10 @@ static struct super_block *v9fs_get_sb(struct file_system_type | |||
167 | goto put_back_sb; | 167 | goto put_back_sb; |
168 | } | 168 | } |
169 | 169 | ||
170 | root_fid->qid = fcall->params.rstat.stat->qid; | 170 | root_fid->qid = fcall->params.rstat.stat.qid; |
171 | root->d_inode->i_ino = | 171 | root->d_inode->i_ino = |
172 | v9fs_qid2ino(&fcall->params.rstat.stat->qid); | 172 | v9fs_qid2ino(&fcall->params.rstat.stat.qid); |
173 | v9fs_mistat2inode(fcall->params.rstat.stat, root->d_inode, sb); | 173 | v9fs_stat2inode(&fcall->params.rstat.stat, root->d_inode, sb); |
174 | } | 174 | } |
175 | 175 | ||
176 | kfree(fcall); | 176 | kfree(fcall); |