Whamcloud - gitweb
LU-13005 lnet: don't use LNetEQPoll for ping replies. 42/36842/7
authorMr NeilBrown <neilb@suse.de>
Wed, 20 Nov 2019 00:54:28 +0000 (11:54 +1100)
committerOleg Drokin <green@whamcloud.com>
Thu, 5 Mar 2020 22:36:16 +0000 (22:36 +0000)
commit952109670beb638b70e71212b177e8b2a73b6910
treef091b3e2ba5ba481ac3faa21be943a12f6020742
parentf912153f468217cb2f77b69cbd61eea8d9466500
LU-13005 lnet: don't use LNetEQPoll for ping replies.

lnet_ping() is the only user of LNetEQPoll.  All other event queues
register a callback and don't make use of queuing.
The queuing provided by lib-eq isn't really needed in the kernel where
callbacks are so easy.

So as a step towards simplifying lib-eq, change lnet_ping() to
register a callback which uses a completion to notify when the ping is
finally complete.

Note that the handling of 'rc' in the current code is a little
confused.
If LNetGet() succeeds, but no LNET_EVENT_REPLY is received, then
rc will be set to -EIO.  There is code to try to set it to ETIMEOUT
or the return value from LNetEQPoll, but this code is ineffectual.

Signed-off-by: Mr NeilBrown <neilb@suse.de>
Change-Id: Ie937887524bfa3ca9c2828d673d431411720c7ae
Reviewed-on: https://review.whamcloud.com/36842
Tested-by: jenkins <devops@whamcloud.com>
Reviewed-by: Chris Horn <chris.horn@hpe.com>
Reviewed-by: James Simmons <jsimmons@infradead.org>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lnet/lnet/api-ni.c