#include "gnilnd.h"
/* Primary entry points from LNET. There are no guarantees against reentrance. */
-struct lnet_lnd the_kgnilnd = {
+const struct lnet_lnd the_kgnilnd = {
.lnd_type = GNILND,
.lnd_startup = kgnilnd_startup,
.lnd_shutdown = kgnilnd_shutdown,
conn->gnc_next_tx = (int) GNILND_MAX_MSG_ID - 10;
/* if this fails, we have conflicts and MAX_TX is too large */
- CLASSERT(GNILND_MAX_MSG_ID < GNILND_MSGID_CLOSE);
+ BUILD_BUG_ON(GNILND_MAX_MSG_ID >= GNILND_MSGID_CLOSE);
/* get a new unique CQ id for this conn */
write_lock(&kgnilnd_data.kgn_peer_conn_lock);
ktime_get_seconds() - peer->gnp_last_alive);
lnet_notify(net->gnn_ni, peer_nid, alive,
+ (alive) ? true : false,
peer->gnp_last_alive);
kgnilnd_net_decref(net);
/* OK to call kgnilnd_api_shutdown() to cleanup now */
kgnilnd_data.kgn_init = GNILND_INIT_DATA;
- try_module_get(THIS_MODULE);
+ if (!try_module_get(THIS_MODULE))
+ GOTO(failed, rc = -ENOENT);
rwlock_init(&kgnilnd_data.kgn_peer_conn_lock);