diff options
Diffstat (limited to 'fs/ceph/file.c')
| -rw-r--r-- | fs/ceph/file.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/fs/ceph/file.c b/fs/ceph/file.c index 4c304a90d046..b8cc3ee5401e 100644 --- a/fs/ceph/file.c +++ b/fs/ceph/file.c | |||
| @@ -213,9 +213,9 @@ out: | |||
| 213 | * may_open() fails, the struct *file gets cleaned up (i.e. | 213 | * may_open() fails, the struct *file gets cleaned up (i.e. |
| 214 | * ceph_release gets called). So fear not! | 214 | * ceph_release gets called). So fear not! |
| 215 | */ | 215 | */ |
| 216 | struct file *ceph_lookup_open(struct inode *dir, struct dentry *dentry, | 216 | int ceph_lookup_open(struct inode *dir, struct dentry *dentry, |
| 217 | struct opendata *od, unsigned flags, umode_t mode, | 217 | struct opendata *od, unsigned flags, umode_t mode, |
| 218 | int *opened) | 218 | int *opened) |
| 219 | { | 219 | { |
| 220 | struct ceph_fs_client *fsc = ceph_sb_to_client(dir->i_sb); | 220 | struct ceph_fs_client *fsc = ceph_sb_to_client(dir->i_sb); |
| 221 | struct ceph_mds_client *mdsc = fsc->mdsc; | 221 | struct ceph_mds_client *mdsc = fsc->mdsc; |
| @@ -230,7 +230,7 @@ struct file *ceph_lookup_open(struct inode *dir, struct dentry *dentry, | |||
| 230 | /* do the open */ | 230 | /* do the open */ |
| 231 | req = prepare_open_request(dir->i_sb, flags, mode); | 231 | req = prepare_open_request(dir->i_sb, flags, mode); |
| 232 | if (IS_ERR(req)) | 232 | if (IS_ERR(req)) |
| 233 | return ERR_CAST(req); | 233 | return PTR_ERR(req); |
| 234 | req->r_dentry = dget(dentry); | 234 | req->r_dentry = dget(dentry); |
| 235 | req->r_num_caps = 2; | 235 | req->r_num_caps = 2; |
| 236 | if (flags & O_CREAT) { | 236 | if (flags & O_CREAT) { |
| @@ -257,10 +257,10 @@ out: | |||
| 257 | dout("ceph_lookup_open result=%p\n", ret); | 257 | dout("ceph_lookup_open result=%p\n", ret); |
| 258 | 258 | ||
| 259 | if (IS_ERR(ret)) | 259 | if (IS_ERR(ret)) |
| 260 | return ERR_CAST(ret); | 260 | return PTR_ERR(ret); |
| 261 | 261 | ||
| 262 | dput(ret); | 262 | dput(ret); |
| 263 | return err ? ERR_PTR(err) : file; | 263 | return err; |
| 264 | } | 264 | } |
| 265 | 265 | ||
| 266 | int ceph_release(struct inode *inode, struct file *file) | 266 | int ceph_release(struct inode *inode, struct file *file) |
