mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2025-01-01 02:36:02 +00:00
sctp: check pl.raise_count separately from its increment
As Marcelo's suggestion this will make code more clear to read. Signed-off-by: Xin Long <lucien.xin@gmail.com> Acked-by: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
5a3c680aa2
commit
650b2a846d
@ -335,10 +335,13 @@ void sctp_transport_pl_recv(struct sctp_transport *t)
|
||||
t->pathmtu = t->pl.pmtu + sctp_transport_pl_hlen(t);
|
||||
sctp_assoc_sync_pmtu(t->asoc);
|
||||
}
|
||||
} else if (t->pl.state == SCTP_PL_COMPLETE && ++t->pl.raise_count == 30) {
|
||||
/* Raise probe_size again after 30 * interval in Search Complete */
|
||||
t->pl.state = SCTP_PL_SEARCH; /* Search Complete -> Search */
|
||||
t->pl.probe_size += SCTP_PL_MIN_STEP;
|
||||
} else if (t->pl.state == SCTP_PL_COMPLETE) {
|
||||
t->pl.raise_count++;
|
||||
if (t->pl.raise_count == 30) {
|
||||
/* Raise probe_size again after 30 * interval in Search Complete */
|
||||
t->pl.state = SCTP_PL_SEARCH; /* Search Complete -> Search */
|
||||
t->pl.probe_size += SCTP_PL_MIN_STEP;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user