aboutsummaryrefslogtreecommitdiffstats
path: root/fs/ceph/mds_client.c
diff options
context:
space:
mode:
authorSage Weil <sage@newdream.net>2009-11-18 14:52:18 -0800
committerSage Weil <sage@newdream.net>2009-11-18 15:02:36 -0800
commit5f44f142601bf94c448e2d463f0f18fd159da164 (patch)
tree773b4677c536519435f073b27873212f705c9c3c /fs/ceph/mds_client.c
parent71ececdacae24be333c534869cb1b06357f0e215 (diff)
downloadkernel_samsung_smdk4412-5f44f142601bf94c448e2d463f0f18fd159da164.zip
kernel_samsung_smdk4412-5f44f142601bf94c448e2d463f0f18fd159da164.tar.gz
kernel_samsung_smdk4412-5f44f142601bf94c448e2d463f0f18fd159da164.tar.bz2
ceph: handle errors during osd client init
Unwind initializing if we get ENOMEM during client initialization. Signed-off-by: Sage Weil <sage@newdream.net>
Diffstat (limited to 'fs/ceph/mds_client.c')
-rw-r--r--fs/ceph/mds_client.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/ceph/mds_client.c b/fs/ceph/mds_client.c
index fdecf99..69feeb1 100644
--- a/fs/ceph/mds_client.c
+++ b/fs/ceph/mds_client.c
@@ -2552,7 +2552,7 @@ static void delayed_work(struct work_struct *work)
}
-void ceph_mdsc_init(struct ceph_mds_client *mdsc, struct ceph_client *client)
+int ceph_mdsc_init(struct ceph_mds_client *mdsc, struct ceph_client *client)
{
mdsc->client = client;
mutex_init(&mdsc->mutex);
@@ -2582,6 +2582,7 @@ void ceph_mdsc_init(struct ceph_mds_client *mdsc, struct ceph_client *client)
init_waitqueue_head(&mdsc->cap_flushing_wq);
spin_lock_init(&mdsc->dentry_lru_lock);
INIT_LIST_HEAD(&mdsc->dentry_lru);
+ return 0;
}
/*