Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 346120
b: refs/heads/master
c: 823bd83
h: refs/heads/master
v: v3
  • Loading branch information
Philipp Reisner committed Nov 8, 2012
1 parent 5fd5d6d commit 8a1e0ca
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 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: 7d4c782cbda4af0d7dc39cb8e7d50a927781aa1f
refs/heads/master: 823bd832a60dcf4bf9c162112f34f2f1783d0eaa
10 changes: 5 additions & 5 deletions trunk/drivers/block/drbd/drbd_receiver.c
Original file line number Diff line number Diff line change
Expand Up @@ -987,14 +987,9 @@ static int conn_connect(struct drbd_tconn *tconn)
}
}

if (conn_request_state(tconn, NS(conn, C_WF_REPORT_PARAMS), CS_VERBOSE) < SS_SUCCESS)
return 0;

sock->sk->sk_sndtimeo = timeout;
sock->sk->sk_rcvtimeo = MAX_SCHEDULE_TIMEOUT;

drbd_thread_start(&tconn->asender);

if (drbd_send_protocol(tconn) == -EOPNOTSUPP)
return -1;

Expand All @@ -1008,6 +1003,11 @@ static int conn_connect(struct drbd_tconn *tconn)
}
rcu_read_unlock();

if (conn_request_state(tconn, NS(conn, C_WF_REPORT_PARAMS), CS_VERBOSE) < SS_SUCCESS)
return 0;

drbd_thread_start(&tconn->asender);

return h;

out_release_sockets:
Expand Down
2 changes: 1 addition & 1 deletion trunk/drivers/block/drbd/drbd_state.c
Original file line number Diff line number Diff line change
Expand Up @@ -1055,7 +1055,7 @@ __drbd_set_state(struct drbd_conf *mdev, union drbd_state ns,
drbd_thread_stop_nowait(&mdev->tconn->receiver);

/* Upon network failure, we need to restart the receiver. */
if (os.conn > C_TEAR_DOWN &&
if (os.conn > C_WF_CONNECTION &&
ns.conn <= C_TEAR_DOWN && ns.conn >= C_TIMEOUT)
drbd_thread_restart_nowait(&mdev->tconn->receiver);

Expand Down

0 comments on commit 8a1e0ca

Please sign in to comment.