net/smc: periodic testlink support
Add periodic LLC testlink support to ensure the link is still active. The interval time is initialized using the value of sysctl_tcp_keepalive_time. Signed-off-by: Karsten Graul <kgraul@linux.ibm.com> Signed-off-by: Ursula Braun <ubraun@linux.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committad av
David S. Miller

förälder
e90c1a1090
incheckning
877ae5be42
@@ -294,6 +294,7 @@ static void smc_copy_sock_settings_to_smc(struct smc_sock *smc)
|
||||
|
||||
static int smc_clnt_conf_first_link(struct smc_sock *smc)
|
||||
{
|
||||
struct net *net = sock_net(smc->clcsock->sk);
|
||||
struct smc_link_group *lgr = smc->conn.lgr;
|
||||
struct smc_link *link;
|
||||
int rest;
|
||||
@@ -353,7 +354,7 @@ static int smc_clnt_conf_first_link(struct smc_sock *smc)
|
||||
if (rc < 0)
|
||||
return SMC_CLC_DECL_TCL;
|
||||
|
||||
link->state = SMC_LNK_ACTIVE;
|
||||
smc_llc_link_active(link, net->ipv4.sysctl_tcp_keepalive_time);
|
||||
|
||||
return 0;
|
||||
}
|
||||
@@ -715,6 +716,7 @@ void smc_close_non_accepted(struct sock *sk)
|
||||
|
||||
static int smc_serv_conf_first_link(struct smc_sock *smc)
|
||||
{
|
||||
struct net *net = sock_net(smc->clcsock->sk);
|
||||
struct smc_link_group *lgr = smc->conn.lgr;
|
||||
struct smc_link *link;
|
||||
int rest;
|
||||
@@ -769,7 +771,7 @@ static int smc_serv_conf_first_link(struct smc_sock *smc)
|
||||
return rc;
|
||||
}
|
||||
|
||||
link->state = SMC_LNK_ACTIVE;
|
||||
smc_llc_link_active(link, net->ipv4.sysctl_tcp_keepalive_time);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
Referens i nytt ärende
Block a user