Whamcloud - gitweb
LU-13478 lnet: handle discovery off properly 21/38321/5
authorAmir Shehata <ashehata@whamcloud.com>
Thu, 23 Apr 2020 00:26:48 +0000 (17:26 -0700)
committerOleg Drokin <green@whamcloud.com>
Wed, 27 May 2020 05:04:57 +0000 (05:04 +0000)
commitadae4295b62b1074f5c3c45543c586282394b1be
tree71405bd05fc27d877f33f16d06d4d03829518a8b
parent87443d9c27e8535c3e17d6bf142ad68d4449b93f
LU-13478 lnet: handle discovery off properly

Peers need to only be updated when discovery is toggled from
on to off. This way the peers don't attempt to send to a
non-primary NID of the node. However, when discovery is
toggled from off to on, the peer will attempt rediscovery
and the peer information will eventually consolidate.

In order to properly delete the peer only when it makes sense
we have to differentiate between the case when we get the
initial message and when we get a push for an already discovered
peer. We only want to delete our local representation if the peer
is one we have already had in our records.

Signed-off-by: Amir Shehata <ashehata@whamcloud.com>
Change-Id: Id6a7353276fec82fddf90e0fa9d85d165b459c8d
Reviewed-on: https://review.whamcloud.com/38321
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Chris Horn <chris.horn@hpe.com>
Reviewed-by: Serguei Smirnov <ssmirnov@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lnet/lnet/api-ni.c
lnet/lnet/peer.c