@@ -292,7 +292,7 @@ int ceph_reserve_caps(struct ceph_mds_client *mdsc,
return err;
}
-int ceph_unreserve_caps(struct ceph_mds_client *mdsc,
+void ceph_unreserve_caps(struct ceph_mds_client *mdsc,
struct ceph_cap_reservation *ctx)
{
dout("unreserve caps ctx=%p count=%d\n", ctx, ctx->count);
@@ -300,7 +300,6 @@ int ceph_unreserve_caps(struct ceph_mds_client *mdsc,
__ceph_unreserve_caps(mdsc, ctx->count);
ctx->count = 0;
spin_unlock(&mdsc->caps_list_lock);
- return 0;
}
struct ceph_cap *ceph_get_cap(struct ceph_mds_client *mdsc,
@@ -659,7 +659,7 @@ extern void ceph_caps_finalize(struct ceph_mds_client *mdsc);
extern void ceph_adjust_min_caps(struct ceph_mds_client *mdsc, int delta);
extern int ceph_reserve_caps(struct ceph_mds_client *mdsc,
struct ceph_cap_reservation *ctx, int need);
-extern int ceph_unreserve_caps(struct ceph_mds_client *mdsc,
+extern void ceph_unreserve_caps(struct ceph_mds_client *mdsc,
struct ceph_cap_reservation *ctx);
extern void ceph_reservation_status(struct ceph_fs_client *client,
int *total, int *avail, int *used,
ceph_unreserve_caps() always returns 0 and also callers do not check return code. Signed-off-by: Chengguang Xu <cgxu519@gmx.com> --- fs/ceph/caps.c | 3 +-- fs/ceph/super.h | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-)