OSDN Git Service

net/smc: switch connections to alternate link
authorKarsten Graul <kgraul@linux.ibm.com>
Mon, 4 May 2020 12:18:38 +0000 (14:18 +0200)
committerDavid S. Miller <davem@davemloft.net>
Mon, 4 May 2020 17:54:39 +0000 (10:54 -0700)
commitc6f02ebeea3a0ff4bddddf0fd82303190ebb3dd1
tree479101eb52292f12f891c45f3615c16d15e16d37
parentf0ec4f1d32ad49a23b93156949208dd9348e3590
net/smc: switch connections to alternate link

Add smc_switch_conns() to switch all connections from a link that is
going down. Find an other link to switch the connections to, and
switch each connection to the new link. smc_switch_cursor() updates the
cursors of a connection to the state of the last successfully sent CDC
message. When there is no link to switch to, terminate the link group.
Call smc_switch_conns() when a link is going down.
And with the possibility that links of connections can switch adapt CDC
and TX functions to detect and handle link switches.

Signed-off-by: Karsten Graul <kgraul@linux.ibm.com>
Reviewed-by: Ursula Braun <ubraun@linux.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/smc/smc_cdc.c
net/smc/smc_cdc.h
net/smc/smc_core.c
net/smc/smc_core.h
net/smc/smc_llc.c
net/smc/smc_tx.c