summaryrefslogtreecommitdiffstats
path: root/fs/ceph
diff options
context:
space:
mode:
authorIlya Dryomov <idryomov@gmail.com>2016-04-26 15:05:29 +0200
committerIlya Dryomov <idryomov@gmail.com>2016-05-26 00:36:20 +0200
commit3ed97d6345a36a0a61e6af62ad8a66ca40f1aa2e (patch)
tree8169875c78caa8e2bede29204fbb29f72b299edc /fs/ceph
parent663ae2cc04773608e1e741f693e41200fd4faf14 (diff)
downloadop-kernel-dev-3ed97d6345a36a0a61e6af62ad8a66ca40f1aa2e.zip
op-kernel-dev-3ed97d6345a36a0a61e6af62ad8a66ca40f1aa2e.tar.gz
libceph: make ceph_osdc_put_request() accept NULL
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Diffstat (limited to 'fs/ceph')
-rw-r--r--fs/ceph/addr.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/fs/ceph/addr.c b/fs/ceph/addr.c
index 4801571..3e61fc8 100644
--- a/fs/ceph/addr.c
+++ b/fs/ceph/addr.c
@@ -1099,8 +1099,7 @@ release_pvec_pages:
mapping->writeback_index = index;
out:
- if (req)
- ceph_osdc_put_request(req);
+ ceph_osdc_put_request(req);
ceph_put_snap_context(snapc);
dout("writepages done, rc = %d\n", rc);
return rc;
@@ -1824,10 +1823,8 @@ static int __ceph_pool_perm_get(struct ceph_inode_info *ci, u32 pool)
out_unlock:
up_write(&mdsc->pool_perm_rwsem);
- if (rd_req)
- ceph_osdc_put_request(rd_req);
- if (wr_req)
- ceph_osdc_put_request(wr_req);
+ ceph_osdc_put_request(rd_req);
+ ceph_osdc_put_request(wr_req);
out:
if (!err)
err = have;
OpenPOWER on IntegriCloud