git://git.onelab.eu
/
sliver-openvswitch.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
revalidator: Fix ukey stats cache updating.
[sliver-openvswitch.git]
/
lib
/
reconnect.c
diff --git
a/lib/reconnect.c
b/lib/reconnect.c
index
40cc7fc
..
5296c5c
100644
(file)
--- a/
lib/reconnect.c
+++ b/
lib/reconnect.c
@@
-1,5
+1,5
@@
/*
/*
- * Copyright (c) 2008, 2009, 2010, 2012 Nicira, Inc.
+ * Copyright (c) 2008, 2009, 2010, 2012
, 2013
Nicira, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@
-207,7
+207,8
@@
reconnect_get_max_tries(struct reconnect *fsm)
/* Configures the backoff parameters for 'fsm'. 'min_backoff' is the minimum
* number of milliseconds, and 'max_backoff' is the maximum, between connection
/* Configures the backoff parameters for 'fsm'. 'min_backoff' is the minimum
* number of milliseconds, and 'max_backoff' is the maximum, between connection
- * attempts.
+ * attempts. The current backoff is also the duration that 'fsm' is willing to
+ * wait for a given connection to succeed or fail.
*
* 'min_backoff' must be at least 1000, and 'max_backoff' must be greater than
* or equal to 'min_backoff'.
*
* 'min_backoff' must be at least 1000, and 'max_backoff' must be greater than
* or equal to 'min_backoff'.
@@
-330,7
+331,7
@@
reconnect_disconnected(struct reconnect *fsm, long long int now, int error)
if (fsm->state & (S_ACTIVE | S_IDLE)) {
if (error > 0) {
VLOG_WARN("%s: connection dropped (%s)",
if (fsm->state & (S_ACTIVE | S_IDLE)) {
if (error > 0) {
VLOG_WARN("%s: connection dropped (%s)",
- fsm->name, strerror(error));
+ fsm->name,
ovs_
strerror(error));
} else if (error == EOF) {
VLOG(fsm->info, "%s: connection closed by peer", fsm->name);
} else {
} else if (error == EOF) {
VLOG(fsm->info, "%s: connection closed by peer", fsm->name);
} else {
@@
-339,7
+340,7
@@
reconnect_disconnected(struct reconnect *fsm, long long int now, int error)
} else if (fsm->state == S_LISTENING) {
if (error > 0) {
VLOG_WARN("%s: error listening for connections (%s)",
} else if (fsm->state == S_LISTENING) {
if (error > 0) {
VLOG_WARN("%s: error listening for connections (%s)",
- fsm->name, strerror(error));
+ fsm->name,
ovs_
strerror(error));
} else {
VLOG(fsm->info, "%s: error listening for connections",
fsm->name);
} else {
VLOG(fsm->info, "%s: error listening for connections",
fsm->name);
@@
-347,8
+348,8
@@
reconnect_disconnected(struct reconnect *fsm, long long int now, int error)
} else {
const char *type = fsm->passive ? "listen" : "connection";
if (error > 0) {
} else {
const char *type = fsm->passive ? "listen" : "connection";
if (error > 0) {
- VLOG_
WARN
("%s: %s attempt failed (%s)",
- fsm->name, type, strerror(error));
+ VLOG_
INFO
("%s: %s attempt failed (%s)",
+ fsm->name, type,
ovs_
strerror(error));
} else {
VLOG(fsm->info, "%s: %s attempt timed out", fsm->name, type);
}
} else {
VLOG(fsm->info, "%s: %s attempt timed out", fsm->name, type);
}
@@
-531,7
+532,7
@@
reconnect_deadline__(const struct reconnect *fsm)
return fsm->state_entered;
}
return fsm->state_entered;
}
- NOT_REACHED();
+
OVS_
NOT_REACHED();
}
/* Assesses whether any action should be taken on 'fsm'. The return value is
}
/* Assesses whether any action should be taken on 'fsm'. The return value is
@@
-603,7
+604,7
@@
reconnect_run(struct reconnect *fsm, long long int now)
return 0;
}
return 0;
}
- NOT_REACHED();
+
OVS_
NOT_REACHED();
} else {
return 0;
}
} else {
return 0;
}