X-Git-Url: https://git.whamcloud.com/?p=fs%2Flustre-release.git;a=blobdiff_plain;f=lnet%2Flnet%2Fapi-ni.c;h=2ccbecc2fbde8b61894135d03a41a6f780a38d79;hp=d298f46a462b298ebe52e0f57fc4c38dc8b61d0d;hb=4f526f5c20073d7025154d97885ec2fdfe832e1c;hpb=b30930a242c6839c2cdb653c849838e928fc3936 diff --git a/lnet/lnet/api-ni.c b/lnet/lnet/api-ni.c index d298f46..2ccbecc 100644 --- a/lnet/lnet/api-ni.c +++ b/lnet/lnet/api-ni.c @@ -800,9 +800,9 @@ static void lnet_assert_wire_constants(void) BUILD_BUG_ON((int)sizeof(((struct lnet_ping_info *)0)->pi_ni) != 0); } -static struct lnet_lnd *lnet_find_lnd_by_type(__u32 type) +static const struct lnet_lnd *lnet_find_lnd_by_type(__u32 type) { - struct lnet_lnd *lnd; + const struct lnet_lnd *lnd; /* holding lnd mutex */ if (type >= NUM_LNDS) @@ -821,7 +821,7 @@ lnet_get_lnd_timeout(void) EXPORT_SYMBOL(lnet_get_lnd_timeout); void -lnet_register_lnd(struct lnet_lnd *lnd) +lnet_register_lnd(const struct lnet_lnd *lnd) { mutex_lock(&the_lnet.ln_lnd_mutex); @@ -837,7 +837,7 @@ lnet_register_lnd(struct lnet_lnd *lnd) EXPORT_SYMBOL(lnet_register_lnd); void -lnet_unregister_lnd(struct lnet_lnd *lnd) +lnet_unregister_lnd(const struct lnet_lnd *lnd) { mutex_lock(&the_lnet.ln_lnd_mutex); @@ -2274,7 +2274,7 @@ lnet_startup_lndnet(struct lnet_net *net, struct lnet_lnd_tunables *tun) int rc; int ni_count = 0; __u32 lnd_type; - struct lnet_lnd *lnd; + const struct lnet_lnd *lnd; int peer_timeout = net->net_tunables.lct_peer_timeout; int maxtxcredits =