Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 39138
b: refs/heads/master
c: 0bae89e
h: refs/heads/master
v: v3
  • Loading branch information
Trond Myklebust authored and Linus Torvalds committed Oct 8, 2006
1 parent e27507d commit 1312c91
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 20 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: cb1055fb1b79775d398038ad8dcd2c7581f141d8
refs/heads/master: 0bae89ec8b1519dae67036637942f5b5bbaa9424
24 changes: 5 additions & 19 deletions trunk/fs/nfs/client.c
Original file line number Diff line number Diff line change
Expand Up @@ -322,25 +322,11 @@ static struct nfs_client *nfs_get_client(const char *hostname,
if (new)
nfs_free_client(new);

if (clp->cl_cons_state == NFS_CS_INITING) {
DECLARE_WAITQUEUE(myself, current);

add_wait_queue(&nfs_client_active_wq, &myself);

for (;;) {
set_current_state(TASK_INTERRUPTIBLE);
if (signal_pending(current) ||
clp->cl_cons_state != NFS_CS_INITING)
break;
schedule();
}

remove_wait_queue(&nfs_client_active_wq, &myself);

if (signal_pending(current)) {
nfs_put_client(clp);
return ERR_PTR(-ERESTARTSYS);
}
error = wait_event_interruptible(&nfs_client_active_wq,
clp->cl_cons_state != NFS_CS_INITING);
if (error < 0) {
nfs_put_client(clp);
return ERR_PTR(-ERESTARTSYS);
}

if (clp->cl_cons_state < NFS_CS_READY) {
Expand Down

0 comments on commit 1312c91

Please sign in to comment.