Skip to content

Commit c4a146c

Browse files
Tony Ludavem330
authored andcommitted
net/smc: Fix smc_link->llc_testlink_time overflow
The value of llc_testlink_time is set to the value stored in net->ipv4.sysctl_tcp_keepalive_time when linkgroup init. The value of sysctl_tcp_keepalive_time is already jiffies, so we don't need to multiply by HZ, which would cause smc_link->llc_testlink_time overflow, and test_link send flood. Signed-off-by: Tony Lu <[email protected]> Reviewed-by: Xuan Zhuo <[email protected]> Reviewed-by: Wen Gu <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent 90a881f commit c4a146c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

net/smc/smc_llc.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1822,7 +1822,7 @@ void smc_llc_link_active(struct smc_link *link)
18221822
link->smcibdev->ibdev->name, link->ibport);
18231823
link->state = SMC_LNK_ACTIVE;
18241824
if (link->lgr->llc_testlink_time) {
1825-
link->llc_testlink_time = link->lgr->llc_testlink_time * HZ;
1825+
link->llc_testlink_time = link->lgr->llc_testlink_time;
18261826
schedule_delayed_work(&link->llc_testlink_wrk,
18271827
link->llc_testlink_time);
18281828
}

0 commit comments

Comments
 (0)