aboutsummaryrefslogtreecommitdiffstats
path: root/net/dccp/timer.c
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@mandriva.com>2005-08-13 19:34:54 -0400
committerDavid S. Miller <davem@sunset.davemloft.net>2005-08-29 18:59:26 -0400
commit7690af3fff7633e40b1b9950eb8489129251d074 (patch)
tree92fa07234a7547c4a7dd74877972b5a291673fcf /net/dccp/timer.c
parentc173437669967301facff151bfeb7bae67354e4c (diff)
[DCCP]: Just reflow the source code to fit in 80 columns
Andrew Morton should be happy now 8) Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/dccp/timer.c')
-rw-r--r--net/dccp/timer.c36
1 files changed, 23 insertions, 13 deletions
diff --git a/net/dccp/timer.c b/net/dccp/timer.c
index 9f1f1ab9e2b4..47b1616e6189 100644
--- a/net/dccp/timer.c
+++ b/net/dccp/timer.c
@@ -45,11 +45,13 @@ static int dccp_write_timeout(struct sock *sk)
45 if (sk->sk_state == DCCP_REQUESTING || sk->sk_state == DCCP_PARTOPEN) { 45 if (sk->sk_state == DCCP_REQUESTING || sk->sk_state == DCCP_PARTOPEN) {
46 if (icsk->icsk_retransmits != 0) 46 if (icsk->icsk_retransmits != 0)
47 dst_negative_advice(&sk->sk_dst_cache); 47 dst_negative_advice(&sk->sk_dst_cache);
48 retry_until = icsk->icsk_syn_retries ? : /* FIXME! */ 3 /* FIXME! sysctl_tcp_syn_retries */; 48 retry_until = icsk->icsk_syn_retries ? :
49 /* FIXME! */ 3 /* FIXME! sysctl_tcp_syn_retries */;
49 } else { 50 } else {
50 if (icsk->icsk_retransmits >= /* FIXME! sysctl_tcp_retries1 */ 5 /* FIXME! */) { 51 if (icsk->icsk_retransmits >=
51 /* NOTE. draft-ietf-tcpimpl-pmtud-01.txt requires pmtu black 52 /* FIXME! sysctl_tcp_retries1 */ 5 /* FIXME! */) {
52 hole detection. :-( 53 /* NOTE. draft-ietf-tcpimpl-pmtud-01.txt requires pmtu
54 black hole detection. :-(
53 55
54 It is place to make it. It is not made. I do not want 56 It is place to make it. It is not made. I do not want
55 to make it. It is disguisting. It does not work in any 57 to make it. It is disguisting. It does not work in any
@@ -96,14 +98,17 @@ static void dccp_delack_timer(unsigned long data)
96 /* Try again later. */ 98 /* Try again later. */
97 icsk->icsk_ack.blocked = 1; 99 icsk->icsk_ack.blocked = 1;
98 NET_INC_STATS_BH(LINUX_MIB_DELAYEDACKLOCKED); 100 NET_INC_STATS_BH(LINUX_MIB_DELAYEDACKLOCKED);
99 sk_reset_timer(sk, &icsk->icsk_delack_timer, jiffies + TCP_DELACK_MIN); 101 sk_reset_timer(sk, &icsk->icsk_delack_timer,
102 jiffies + TCP_DELACK_MIN);
100 goto out; 103 goto out;
101 } 104 }
102 105
103 if (sk->sk_state == DCCP_CLOSED || !(icsk->icsk_ack.pending & ICSK_ACK_TIMER)) 106 if (sk->sk_state == DCCP_CLOSED ||
107 !(icsk->icsk_ack.pending & ICSK_ACK_TIMER))
104 goto out; 108 goto out;
105 if (time_after(icsk->icsk_ack.timeout, jiffies)) { 109 if (time_after(icsk->icsk_ack.timeout, jiffies)) {
106 sk_reset_timer(sk, &icsk->icsk_delack_timer, icsk->icsk_ack.timeout); 110 sk_reset_timer(sk, &icsk->icsk_delack_timer,
111 icsk->icsk_ack.timeout);
107 goto out; 112 goto out;
108 } 113 }
109 114
@@ -112,7 +117,8 @@ static void dccp_delack_timer(unsigned long data)
112 if (inet_csk_ack_scheduled(sk)) { 117 if (inet_csk_ack_scheduled(sk)) {
113 if (!icsk->icsk_ack.pingpong) { 118 if (!icsk->icsk_ack.pingpong) {
114 /* Delayed ACK missed: inflate ATO. */ 119 /* Delayed ACK missed: inflate ATO. */
115 icsk->icsk_ack.ato = min(icsk->icsk_ack.ato << 1, icsk->icsk_rto); 120 icsk->icsk_ack.ato = min(icsk->icsk_ack.ato << 1,
121 icsk->icsk_rto);
116 } else { 122 } else {
117 /* Delayed ACK missed: leave pingpong mode and 123 /* Delayed ACK missed: leave pingpong mode and
118 * deflate ATO. 124 * deflate ATO.
@@ -167,7 +173,7 @@ static void dccp_retransmit_timer(struct sock *sk)
167 inet_csk_reset_xmit_timer(sk, ICSK_TIME_RETRANS, 173 inet_csk_reset_xmit_timer(sk, ICSK_TIME_RETRANS,
168 min(icsk->icsk_rto, 174 min(icsk->icsk_rto,
169 TCP_RESOURCE_PROBE_INTERVAL), 175 TCP_RESOURCE_PROBE_INTERVAL),
170 TCP_RTO_MAX); 176 DCCP_RTO_MAX);
171 goto out; 177 goto out;
172 } 178 }
173 179
@@ -175,7 +181,8 @@ static void dccp_retransmit_timer(struct sock *sk)
175 icsk->icsk_retransmits++; 181 icsk->icsk_retransmits++;
176 182
177 icsk->icsk_rto = min(icsk->icsk_rto << 1, DCCP_RTO_MAX); 183 icsk->icsk_rto = min(icsk->icsk_rto << 1, DCCP_RTO_MAX);
178 inet_csk_reset_xmit_timer(sk, ICSK_TIME_RETRANS, icsk->icsk_rto, TCP_RTO_MAX); 184 inet_csk_reset_xmit_timer(sk, ICSK_TIME_RETRANS, icsk->icsk_rto,
185 DCCP_RTO_MAX);
179 if (icsk->icsk_retransmits > 3 /* FIXME: sysctl_dccp_retries1 */) 186 if (icsk->icsk_retransmits > 3 /* FIXME: sysctl_dccp_retries1 */)
180 __sk_dst_reset(sk); 187 __sk_dst_reset(sk);
181out:; 188out:;
@@ -190,7 +197,8 @@ static void dccp_write_timer(unsigned long data)
190 bh_lock_sock(sk); 197 bh_lock_sock(sk);
191 if (sock_owned_by_user(sk)) { 198 if (sock_owned_by_user(sk)) {
192 /* Try again later */ 199 /* Try again later */
193 sk_reset_timer(sk, &icsk->icsk_retransmit_timer, jiffies + (HZ / 20)); 200 sk_reset_timer(sk, &icsk->icsk_retransmit_timer,
201 jiffies + (HZ / 20));
194 goto out; 202 goto out;
195 } 203 }
196 204
@@ -198,7 +206,8 @@ static void dccp_write_timer(unsigned long data)
198 goto out; 206 goto out;
199 207
200 if (time_after(icsk->icsk_timeout, jiffies)) { 208 if (time_after(icsk->icsk_timeout, jiffies)) {
201 sk_reset_timer(sk, &icsk->icsk_retransmit_timer, icsk->icsk_timeout); 209 sk_reset_timer(sk, &icsk->icsk_retransmit_timer,
210 icsk->icsk_timeout);
202 goto out; 211 goto out;
203 } 212 }
204 213
@@ -220,7 +229,8 @@ out:
220 */ 229 */
221static void dccp_response_timer(struct sock *sk) 230static void dccp_response_timer(struct sock *sk)
222{ 231{
223 inet_csk_reqsk_queue_prune(sk, TCP_SYNQ_INTERVAL, DCCP_TIMEOUT_INIT, DCCP_RTO_MAX); 232 inet_csk_reqsk_queue_prune(sk, TCP_SYNQ_INTERVAL, DCCP_TIMEOUT_INIT,
233 DCCP_RTO_MAX);
224} 234}
225 235
226static void dccp_keepalive_timer(unsigned long data) 236static void dccp_keepalive_timer(unsigned long data)