Whamcloud - gitweb
git://git.whamcloud.com
/
fs
/
lustre-release.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
LU-8734 gnilnd: Handle dla credits exhaustion
[fs/lustre-release.git]
/
lnet
/
klnds
/
gnilnd
/
gnilnd_stack.c
diff --git
a/lnet/klnds/gnilnd/gnilnd_stack.c
b/lnet/klnds/gnilnd/gnilnd_stack.c
index
1da0fbe
..
bdec685
100644
(file)
--- a/
lnet/klnds/gnilnd/gnilnd_stack.c
+++ b/
lnet/klnds/gnilnd/gnilnd_stack.c
@@
-254,6
+254,9
@@
kgnilnd_reset_stack(void)
list_del_init(&conn->gnc_schedlist);
list_del_init(&conn->gnc_schedlist);
+ if (!list_empty(&conn->gnc_delaylist))
+ list_del_init(&conn->gnc_delaylist);
+
if (conn->gnc_state == GNILND_CONN_CLOSING) {
/* bump to CLOSED to fake out send of CLOSE */
conn->gnc_state = GNILND_CONN_CLOSED;
if (conn->gnc_state == GNILND_CONN_CLOSING) {
/* bump to CLOSED to fake out send of CLOSE */
conn->gnc_state = GNILND_CONN_CLOSED;
@@
-535,7
+538,7
@@
kgnilnd_quiesce_end_callback(gni_nic_handle_t nic_handle, uint64_t msecs)
if (!kgnilnd_data.kgn_ruhroh_shutdown) {
if (!kgnilnd_data.kgn_ruhroh_shutdown) {
- CDEBUG(D_NET, "requesting timeout bump by
"LPD64"
msecs\n", msecs);
+ CDEBUG(D_NET, "requesting timeout bump by
%lld
msecs\n", msecs);
/* Save the bump interval and request the bump.
* The memory barrier ensures that the interval is in place before
/* Save the bump interval and request the bump.
* The memory barrier ensures that the interval is in place before
@@
-581,10
+584,9
@@
struct rcadata {
rs_event_code_t ec;
};
static struct rcadata rd[RCA_EVENTS] = {
rs_event_code_t ec;
};
static struct rcadata rd[RCA_EVENTS] = {
- {0, 0, ec_node_unavailable},
- {0, 0, ec_node_available},
- {0, 0, ec_node_failed}
-};
+ { .ec = ec_node_unavailable },
+ { .ec = ec_node_available },
+ { .ec = ec_node_failed } };
/* thread for receiving rca events */
int
/* thread for receiving rca events */
int
@@
-651,7
+653,7
@@
subscribe_retry:
}
if (krca_get_message(&rca_krt, &event) == 0) {
}
if (krca_get_message(&rca_krt, &event) == 0) {
- int node_down = GNILND_
RCA_NODE
_UNKNOWN;
+ int node_down = GNILND_
PEER
_UNKNOWN;
rs_state_t state;
LIST_HEAD(zombies);
rs_state_t state;
LIST_HEAD(zombies);
@@
-675,7
+677,7
@@
subscribe_retry:
switch (event.ev_id) {
case ec_node_available:
CDEBUG(D_INFO, "ec_node_available\n");
switch (event.ev_id) {
case ec_node_available:
CDEBUG(D_INFO, "ec_node_available\n");
- node_down = GNILND_
RCA_NODE
_UP;
+ node_down = GNILND_
PEER
_UP;
break;
case ec_node_failed:
CDEBUG(D_INFO, "ec_node_failed\n");
break;
case ec_node_failed:
CDEBUG(D_INFO, "ec_node_failed\n");
@@
-684,7
+686,7
@@
subscribe_retry:
"ec_node_failed ignored\n");
break;
}
"ec_node_failed ignored\n");
break;
}
- node_down = GNILND_
RCA_NODE
_DOWN;
+ node_down = GNILND_
PEER
_DOWN;
break;
case ec_node_unavailable:
state = RSN_GET_FLD(event.ev_gen.svid_node.rsn_intval, STATE);
break;
case ec_node_unavailable:
state = RSN_GET_FLD(event.ev_gen.svid_node.rsn_intval, STATE);
@@
-701,7
+703,7
@@
subscribe_retry:
" RS_CS_READY state\n");
break;
}
" RS_CS_READY state\n");
break;
}
- node_down = GNILND_
RCA_NODE
_DOWN;
+ node_down = GNILND_
PEER
_DOWN;
break;
default:
CDEBUG(D_INFO, "unknown event\n");
break;
default:
CDEBUG(D_INFO, "unknown event\n");
@@
-710,9
+712,8
@@
subscribe_retry:
/* if we get an event we don't know about, just go ahead
* and wait for another event */
/* if we get an event we don't know about, just go ahead
* and wait for another event */
- if (node_down == GNILND_
RCA_NODE_UNKNOWN) {
+ if (node_down == GNILND_
PEER_UNKNOWN)
continue;
continue;
- }
nid = RSN_GET_FLD(event.ev_gen.svid_node.rs_node_flat,
NID);
nid = RSN_GET_FLD(event.ev_gen.svid_node.rs_node_flat,
NID);
@@
-768,7
+769,7
@@
int
kgnilnd_get_node_state(__u32 nid)
{
int i;
kgnilnd_get_node_state(__u32 nid)
{
int i;
- int rc = GNILND_
RCA_NODE
_UNKNOWN;
+ int rc = GNILND_
PEER
_UNKNOWN;
int ret;
rs_node_array_t nlist;
rs_node_t *na = NULL;
int ret;
rs_node_array_t nlist;
rs_node_t *na = NULL;
@@
-783,7
+784,7
@@
kgnilnd_get_node_state(__u32 nid)
for (i = 0; i < nlist.na_len; i++) {
if ((rca_nid_t)RSN_GET_FLD(na[i].rs_node_flat, NID) == nid) {
rc = RSN_GET_FLD(na[i].rs_node_flat, STATE) == RS_CS_READY ?
for (i = 0; i < nlist.na_len; i++) {
if ((rca_nid_t)RSN_GET_FLD(na[i].rs_node_flat, NID) == nid) {
rc = RSN_GET_FLD(na[i].rs_node_flat, STATE) == RS_CS_READY ?
- GNILND_
RCA_NODE_UP : GNILND_RCA_NODE
_DOWN;
+ GNILND_
PEER_UP : GNILND_PEER
_DOWN;
break;
}
}
break;
}
}
@@
-810,6
+811,6
@@
kgnilnd_wakeup_rca_thread(void)
int
kgnilnd_get_node_state(__u32 nid)
{
int
kgnilnd_get_node_state(__u32 nid)
{
- return GNILND_
RCA_NODE
_UP;
+ return GNILND_
PEER
_UP;
}
#endif /* GNILND_USE_RCA */
}
#endif /* GNILND_USE_RCA */