sctp: fix the transport error_count check
authorXin Long <lucien.xin@gmail.com>
Mon, 12 Aug 2019 12:49:12 +0000 (20:49 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 25 Aug 2019 08:51:52 +0000 (10:51 +0200)
commitf85c2f3ab4a074a23946a480b7c0755637a04f93
tree5103d3c2a317bbd4f2d19032403684fa18dc9121
parent7876df0500d23e353803318297d5b42944a2e369
sctp: fix the transport error_count check

[ Upstream commit a1794de8b92ea6bc2037f445b296814ac826693e ]

As the annotation says in sctp_do_8_2_transport_strike():

  "If the transport error count is greater than the pf_retrans
   threshold, and less than pathmaxrtx ..."

It should be transport->error_count checked with pathmaxrxt,
instead of asoc->pf_retrans.

Fixes: 5aa93bcf66f4 ("sctp: Implement quick failover draft from tsvwg")
Signed-off-by: Xin Long <lucien.xin@gmail.com>
Acked-by: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/sctp/sm_sideeffect.c