ceph: mount fails immediately on error

Signed-off-by: Yehuda Sadeh <yehuda@newdream.net>
This commit is contained in:
Yehuda Sadeh
2009-11-20 13:59:13 -08:00
committed by Sage Weil
parent 94045e115e
commit dc14657c9c
2 changed files with 10 additions and 1 deletions

View File

@@ -712,10 +712,14 @@ static int ceph_mount(struct ceph_client *client, struct vfsmount *mnt,
/* wait */
dout("mount waiting for mon_map\n");
err = wait_event_interruptible_timeout(client->mount_wq, /* FIXME */
have_mon_map(client),
have_mon_map(client) || (client->mount_err < 0),
timeout);
if (err == -EINTR || err == -ERESTARTSYS)
goto out;
if (client->mount_err < 0) {
err = client->mount_err;
goto out;
}
}
dout("mount opening root\n");