Whamcloud - gitweb
LU-15713 lnet: Ensure round robin across nets 76/46976/7
authorChris Horn <chris.horn@hpe.com>
Thu, 31 Mar 2022 01:49:46 +0000 (20:49 -0500)
committerOleg Drokin <green@whamcloud.com>
Mon, 11 Jul 2022 06:49:20 +0000 (06:49 +0000)
commit05413b3d84f7d1febb89cf4e9c86a7e017d147df
tree7bf5e7aea991b36b45dd6231e6f55efdb3b6c7b3
parentd9af9b5a7ee7066607d14d61f92aec5350a36008
LU-15713 lnet: Ensure round robin across nets

Introduce a global net sequence number and a peer sequence number.
These sequence numbers are used to ensure round robin selection of
local NIs and peer NIs across nets.

Also consolidate the sequence number accounting under
lnet_handle_send(). Previously the sequence number increment for
the final destination peer net/peer NI on a routed send was done
in lnet_handle_find_routed_path().

Some cleanup that is also in this patch:
 - Redundant check of null src_nid is removed from
   lnet_handle_find_routed_path() (LNET_NID_IS_ANY handles null arg)
 - Avoid comparing best_lpn with itself in
   lnet_handle_find_routed_path() on the first loop iteration
 - In lnet_find_best_ni_on_local_net() check whether we have
   a specified lp_disc_net_id outside of the loop to avoid doing
   that work on each loop iteration.

Added some debug statements to print information used when selecting
peer net/local net.

HPE-bug-id: LUS-10871
Test-Parameters: trivial
Signed-off-by: Chris Horn <chris.horn@hpe.com>
Change-Id: Ide07e832deda85735042835e3097b9bf92e1e4b0
Reviewed-on: https://review.whamcloud.com/46976
Reviewed-by: Serguei Smirnov <ssmirnov@whamcloud.com>
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Cyril Bordage <cbordage@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lnet/include/lnet/lib-types.h
lnet/lnet/lib-move.c