Whamcloud - gitweb
LU-14954 socklnd: fix link state detection 32/44732/5
authorSerguei Smirnov <ssmirnov@whamcloud.com>
Mon, 23 Aug 2021 19:58:51 +0000 (12:58 -0700)
committerOleg Drokin <green@whamcloud.com>
Tue, 31 Aug 2021 05:23:48 +0000 (05:23 +0000)
commit008795508d65bb40b6ea631c141449866ab7aa67
tree881569fbcab159cf23b5f7732f1e174b4cefcef7
parente8d76d1090e912ee5d916284ca5c8ba9195ddd9b
LU-14954 socklnd: fix link state detection

Due to matching only the device index, link detection implemented
in LU-14742 has issues with confusing the link events for the
virtual interfaces with the link events for the interface that
LNet was actually configured to use. Fix this by improving
the identification of the event source: use both device name and
device index.

Also, to make sure the link fatal state is cleared only when
the device is bound to the IP address used at NI creation,
subscribe to inetaddr events in addition to the netdev events.

Test-Parameters: trivial
Fixes: fc2df80e96dc ("LU-14742: detect link state to set fatal error")
Signed-off-by: Serguei Smirnov <ssmirnov@whamcloud.com>
Change-Id: Ib1996c66a8ae2596970d66e3d920702190851e3f
Reviewed-on: https://review.whamcloud.com/44732
Tested-by: jenkins <devops@whamcloud.com>
Reviewed-by: Amir Shehata <ashehata@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Cyril Bordage <cbordage@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lnet/klnds/socklnd/socklnd.c