Lines Matching refs:tp
71 static void dctcp_reset(const struct tcp_sock *tp, struct dctcp *ca) in dctcp_reset() argument
73 ca->next_seq = tp->snd_nxt; in dctcp_reset()
81 const struct tcp_sock *tp = tcp_sk(sk); in dctcp_init() local
83 if ((tp->ecn_flags & TCP_ECN_OK) || in dctcp_init()
88 ca->prior_snd_una = tp->snd_una; in dctcp_init()
89 ca->prior_rcv_nxt = tp->rcv_nxt; in dctcp_init()
96 dctcp_reset(tp, ca); in dctcp_init()
110 struct tcp_sock *tp = tcp_sk(sk); in dctcp_ssthresh() local
112 ca->loss_cwnd = tp->snd_cwnd; in dctcp_ssthresh()
113 return max(tp->snd_cwnd - ((tp->snd_cwnd * ca->dctcp_alpha) >> 11U), 2U); in dctcp_ssthresh()
125 struct tcp_sock *tp = tcp_sk(sk); in dctcp_ce_state_0_to_1() local
137 ca->prior_rcv_nxt = tp->rcv_nxt; in dctcp_ce_state_0_to_1()
140 tp->ecn_flags |= TCP_ECN_DEMAND_CWR; in dctcp_ce_state_0_to_1()
146 struct tcp_sock *tp = tcp_sk(sk); in dctcp_ce_state_1_to_0() local
158 ca->prior_rcv_nxt = tp->rcv_nxt; in dctcp_ce_state_1_to_0()
161 tp->ecn_flags &= ~TCP_ECN_DEMAND_CWR; in dctcp_ce_state_1_to_0()
166 const struct tcp_sock *tp = tcp_sk(sk); in dctcp_update_alpha() local
168 u32 acked_bytes = tp->snd_una - ca->prior_snd_una; in dctcp_update_alpha()
177 ca->prior_snd_una = tp->snd_una; in dctcp_update_alpha()
184 if (!before(tp->snd_una, ca->next_seq)) { in dctcp_update_alpha()
205 dctcp_reset(tp, ca); in dctcp_update_alpha()
212 struct tcp_sock *tp = tcp_sk(sk); in dctcp_react_to_loss() local
214 ca->loss_cwnd = tp->snd_cwnd; in dctcp_react_to_loss()
215 tp->snd_ssthresh = max(tp->snd_cwnd >> 1U, 2U); in dctcp_react_to_loss()