diff options
Diffstat (limited to 'fs/coda/cnode.c')
-rw-r--r-- | fs/coda/cnode.c | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/fs/coda/cnode.c b/fs/coda/cnode.c index 845b5a66952a..06855f6c7902 100644 --- a/fs/coda/cnode.c +++ b/fs/coda/cnode.c | |||
@@ -8,8 +8,8 @@ | |||
8 | #include <linux/time.h> | 8 | #include <linux/time.h> |
9 | 9 | ||
10 | #include <linux/coda.h> | 10 | #include <linux/coda.h> |
11 | #include <linux/coda_psdev.h> | ||
12 | #include <linux/pagemap.h> | 11 | #include <linux/pagemap.h> |
12 | #include "coda_psdev.h" | ||
13 | #include "coda_linux.h" | 13 | #include "coda_linux.h" |
14 | 14 | ||
15 | static inline int coda_fideq(struct CodaFid *fid1, struct CodaFid *fid2) | 15 | static inline int coda_fideq(struct CodaFid *fid1, struct CodaFid *fid2) |
@@ -137,11 +137,6 @@ struct inode *coda_fid_to_inode(struct CodaFid *fid, struct super_block *sb) | |||
137 | struct inode *inode; | 137 | struct inode *inode; |
138 | unsigned long hash = coda_f2i(fid); | 138 | unsigned long hash = coda_f2i(fid); |
139 | 139 | ||
140 | if ( !sb ) { | ||
141 | pr_warn("%s: no sb!\n", __func__); | ||
142 | return NULL; | ||
143 | } | ||
144 | |||
145 | inode = ilookup5(sb, hash, coda_test_inode, fid); | 140 | inode = ilookup5(sb, hash, coda_test_inode, fid); |
146 | if ( !inode ) | 141 | if ( !inode ) |
147 | return NULL; | 142 | return NULL; |
@@ -153,6 +148,16 @@ struct inode *coda_fid_to_inode(struct CodaFid *fid, struct super_block *sb) | |||
153 | return inode; | 148 | return inode; |
154 | } | 149 | } |
155 | 150 | ||
151 | struct coda_file_info *coda_ftoc(struct file *file) | ||
152 | { | ||
153 | struct coda_file_info *cfi = file->private_data; | ||
154 | |||
155 | BUG_ON(!cfi || cfi->cfi_magic != CODA_MAGIC); | ||
156 | |||
157 | return cfi; | ||
158 | |||
159 | } | ||
160 | |||
156 | /* the CONTROL inode is made without asking attributes from Venus */ | 161 | /* the CONTROL inode is made without asking attributes from Venus */ |
157 | struct inode *coda_cnode_makectl(struct super_block *sb) | 162 | struct inode *coda_cnode_makectl(struct super_block *sb) |
158 | { | 163 | { |