2 * net/dccp/ccids/ccid2.c
4 * Copyright (c) 2005, 2006 Andrea Bittau <a.bittau@cs.ucl.ac.uk>
6 * Changes to meet Linux coding standards, and DCCP infrastructure fixes.
8 * Copyright (c) 2006 Arnaldo Carvalho de Melo <acme@conectiva.com.br>
10 * This program is free software; you can redistribute it and/or modify
11 * it under the terms of the GNU General Public License as published by
12 * the Free Software Foundation; either version 2 of the License, or
13 * (at your option) any later version.
15 * This program is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU General Public License for more details.
20 * You should have received a copy of the GNU General Public License
21 * along with this program; if not, write to the Free Software
22 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
26 * This implementation should follow: draft-ietf-dccp-ccid2-10.txt
29 * - sequence number wrapping
37 static int ccid2_debug;
41 #define ccid2_pr_debug(format, a...) \
42 do { if (ccid2_debug) \
43 printk(KERN_DEBUG "%s: " format, __FUNCTION__, ##a); \
46 #define ccid2_pr_debug(format, a...)
49 static const int ccid2_seq_len = 128;
52 static void ccid2_hc_tx_check_sanity(const struct ccid2_hc_tx_sock *hctx)
56 struct ccid2_seq *seqp = hctx->ccid2hctx_seqh;
58 /* there is data in the chain */
59 if (seqp != hctx->ccid2hctx_seqt) {
60 seqp = seqp->ccid2s_prev;
62 if (!seqp->ccid2s_acked)
65 while (seqp != hctx->ccid2hctx_seqt) {
66 struct ccid2_seq *prev = seqp->ccid2s_prev;
69 if (!prev->ccid2s_acked)
72 /* packets are sent sequentially */
73 BUG_ON(seqp->ccid2s_seq <= prev->ccid2s_seq);
74 BUG_ON(seqp->ccid2s_sent < prev->ccid2s_sent);
75 BUG_ON(len > ccid2_seq_len);
81 BUG_ON(pipe != hctx->ccid2hctx_pipe);
82 ccid2_pr_debug("len of chain=%d\n", len);
85 seqp = seqp->ccid2s_prev;
87 BUG_ON(len > ccid2_seq_len);
88 } while (seqp != hctx->ccid2hctx_seqh);
90 BUG_ON(len != ccid2_seq_len);
91 ccid2_pr_debug("total len=%d\n", len);
94 #define ccid2_hc_tx_check_sanity(hctx) do {} while (0)
97 static int ccid2_hc_tx_send_packet(struct sock *sk,
98 struct sk_buff *skb, int len)
100 struct ccid2_hc_tx_sock *hctx;
102 switch (DCCP_SKB_CB(skb)->dccpd_type) {
103 case 0: /* XXX data packets from userland come through like this */
105 case DCCP_PKT_DATAACK:
107 /* No congestion control on other packets */
112 hctx = ccid2_hc_tx_sk(sk);
114 ccid2_pr_debug("pipe=%d cwnd=%d\n", hctx->ccid2hctx_pipe,
115 hctx->ccid2hctx_cwnd);
117 if (hctx->ccid2hctx_pipe < hctx->ccid2hctx_cwnd) {
118 /* OK we can send... make sure previous packet was sent off */
119 if (!hctx->ccid2hctx_sendwait) {
120 hctx->ccid2hctx_sendwait = 1;
125 return 100; /* XXX */
128 static void ccid2_change_l_ack_ratio(struct sock *sk, int val)
130 struct dccp_sock *dp = dccp_sk(sk);
132 * XXX I don't really agree with val != 2. If cwnd is 1, ack ratio
133 * should be 1... it shouldn't be allowed to become 2.
137 const struct ccid2_hc_tx_sock *hctx = ccid2_hc_tx_sk(sk);
138 int max = hctx->ccid2hctx_cwnd / 2;
141 if (hctx->ccid2hctx_cwnd & 1)
148 ccid2_pr_debug("changing local ack ratio to %d\n", val);
150 dp->dccps_l_ack_ratio = val;
153 static void ccid2_change_cwnd(struct sock *sk, int val)
155 struct ccid2_hc_tx_sock *hctx = ccid2_hc_tx_sk(sk);
160 /* XXX do we need to change ack ratio? */
161 ccid2_pr_debug("change cwnd to %d\n", val);
164 hctx->ccid2hctx_cwnd = val;
167 static void ccid2_start_rto_timer(struct sock *sk);
169 static void ccid2_hc_tx_rto_expire(unsigned long data)
171 struct sock *sk = (struct sock *)data;
172 struct ccid2_hc_tx_sock *hctx = ccid2_hc_tx_sk(sk);
176 if (sock_owned_by_user(sk)) {
177 sk_reset_timer(sk, &hctx->ccid2hctx_rtotimer,
182 ccid2_pr_debug("RTO_EXPIRE\n");
184 ccid2_hc_tx_check_sanity(hctx);
187 hctx->ccid2hctx_rto <<= 1;
189 s = hctx->ccid2hctx_rto / HZ;
191 hctx->ccid2hctx_rto = 60 * HZ;
193 ccid2_start_rto_timer(sk);
195 /* adjust pipe, cwnd etc */
196 hctx->ccid2hctx_pipe = 0;
197 hctx->ccid2hctx_ssthresh = hctx->ccid2hctx_cwnd >> 1;
198 if (hctx->ccid2hctx_ssthresh < 2)
199 hctx->ccid2hctx_ssthresh = 2;
200 ccid2_change_cwnd(sk, 1);
202 /* clear state about stuff we sent */
203 hctx->ccid2hctx_seqt = hctx->ccid2hctx_seqh;
204 hctx->ccid2hctx_ssacks = 0;
205 hctx->ccid2hctx_acks = 0;
206 hctx->ccid2hctx_sent = 0;
208 /* clear ack ratio state. */
209 hctx->ccid2hctx_arsent = 0;
210 hctx->ccid2hctx_ackloss = 0;
211 hctx->ccid2hctx_rpseq = 0;
212 hctx->ccid2hctx_rpdupack = -1;
213 ccid2_change_l_ack_ratio(sk, 1);
214 ccid2_hc_tx_check_sanity(hctx);
220 static void ccid2_start_rto_timer(struct sock *sk)
222 struct ccid2_hc_tx_sock *hctx = ccid2_hc_tx_sk(sk);
224 ccid2_pr_debug("setting RTO timeout=%ld\n", hctx->ccid2hctx_rto);
226 BUG_ON(timer_pending(&hctx->ccid2hctx_rtotimer));
227 sk_reset_timer(sk, &hctx->ccid2hctx_rtotimer,
228 jiffies + hctx->ccid2hctx_rto);
231 static void ccid2_hc_tx_packet_sent(struct sock *sk, int more, int len)
233 struct dccp_sock *dp = dccp_sk(sk);
234 struct ccid2_hc_tx_sock *hctx = ccid2_hc_tx_sk(sk);
237 ccid2_hc_tx_check_sanity(hctx);
239 BUG_ON(!hctx->ccid2hctx_sendwait);
240 hctx->ccid2hctx_sendwait = 0;
241 hctx->ccid2hctx_pipe++;
242 BUG_ON(hctx->ccid2hctx_pipe < 0);
244 /* There is an issue. What if another packet is sent between
245 * packet_send() and packet_sent(). Then the sequence number would be
251 hctx->ccid2hctx_seqh->ccid2s_seq = seq;
252 hctx->ccid2hctx_seqh->ccid2s_acked = 0;
253 hctx->ccid2hctx_seqh->ccid2s_sent = jiffies;
254 hctx->ccid2hctx_seqh = hctx->ccid2hctx_seqh->ccid2s_next;
256 ccid2_pr_debug("cwnd=%d pipe=%d\n", hctx->ccid2hctx_cwnd,
257 hctx->ccid2hctx_pipe);
259 if (hctx->ccid2hctx_seqh == hctx->ccid2hctx_seqt) {
260 /* XXX allocate more space */
264 hctx->ccid2hctx_sent++;
266 /* Ack Ratio. Need to maintain a concept of how many windows we sent */
267 hctx->ccid2hctx_arsent++;
268 /* We had an ack loss in this window... */
269 if (hctx->ccid2hctx_ackloss) {
270 if (hctx->ccid2hctx_arsent >= hctx->ccid2hctx_cwnd) {
271 hctx->ccid2hctx_arsent = 0;
272 hctx->ccid2hctx_ackloss = 0;
275 /* No acks lost up to now... */
276 /* decrease ack ratio if enough packets were sent */
277 if (dp->dccps_l_ack_ratio > 1) {
278 /* XXX don't calculate denominator each time */
279 int denom = dp->dccps_l_ack_ratio * dp->dccps_l_ack_ratio -
280 dp->dccps_l_ack_ratio;
282 denom = hctx->ccid2hctx_cwnd * hctx->ccid2hctx_cwnd / denom;
284 if (hctx->ccid2hctx_arsent >= denom) {
285 ccid2_change_l_ack_ratio(sk, dp->dccps_l_ack_ratio - 1);
286 hctx->ccid2hctx_arsent = 0;
289 /* we can't increase ack ratio further [1] */
290 hctx->ccid2hctx_arsent = 0; /* or maybe set it to cwnd*/
294 /* setup RTO timer */
295 if (!timer_pending(&hctx->ccid2hctx_rtotimer))
296 ccid2_start_rto_timer(sk);
299 ccid2_pr_debug("pipe=%d\n", hctx->ccid2hctx_pipe);
300 ccid2_pr_debug("Sent: seq=%llu\n", seq);
302 struct ccid2_seq *seqp = hctx->ccid2hctx_seqt;
304 while (seqp != hctx->ccid2hctx_seqh) {
305 ccid2_pr_debug("out seq=%llu acked=%d time=%lu\n",
306 seqp->ccid2s_seq, seqp->ccid2s_acked,
308 seqp = seqp->ccid2s_next;
311 ccid2_pr_debug("=========\n");
312 ccid2_hc_tx_check_sanity(hctx);
316 /* XXX Lame code duplication!
317 * returns -1 if none was found.
318 * else returns the next offset to use in the function call.
320 static int ccid2_ackvector(struct sock *sk, struct sk_buff *skb, int offset,
321 unsigned char **vec, unsigned char *veclen)
323 const struct dccp_hdr *dh = dccp_hdr(skb);
324 unsigned char *options = (unsigned char *)dh + dccp_hdr_len(skb);
325 unsigned char *opt_ptr;
326 const unsigned char *opt_end = (unsigned char *)dh +
327 (dh->dccph_doff * 4);
328 unsigned char opt, len;
329 unsigned char *value;
334 if (opt_ptr >= opt_end)
337 while (opt_ptr != opt_end) {
342 /* Check if this isn't a single byte option */
343 if (opt > DCCPO_MAX_RESERVED) {
344 if (opt_ptr == opt_end)
345 goto out_invalid_option;
349 goto out_invalid_option;
351 * Remove the type and len fields, leaving
352 * just the value size
358 if (opt_ptr > opt_end)
359 goto out_invalid_option;
363 case DCCPO_ACK_VECTOR_0:
364 case DCCPO_ACK_VECTOR_1:
367 return offset + (opt_ptr - options);
374 BUG_ON(1); /* should never happen... options were previously parsed ! */
378 static void ccid2_hc_tx_kill_rto_timer(struct sock *sk)
380 struct ccid2_hc_tx_sock *hctx = ccid2_hc_tx_sk(sk);
382 sk_stop_timer(sk, &hctx->ccid2hctx_rtotimer);
383 ccid2_pr_debug("deleted RTO timer\n");
386 static inline void ccid2_new_ack(struct sock *sk,
387 struct ccid2_seq *seqp,
388 unsigned int *maxincr)
390 struct ccid2_hc_tx_sock *hctx = ccid2_hc_tx_sk(sk);
393 if (hctx->ccid2hctx_cwnd < hctx->ccid2hctx_ssthresh) {
394 hctx->ccid2hctx_acks = 0;
396 /* We can increase cwnd at most maxincr [ack_ratio/2] */
398 /* increase every 2 acks */
399 hctx->ccid2hctx_ssacks++;
400 if (hctx->ccid2hctx_ssacks == 2) {
401 ccid2_change_cwnd(sk, hctx->ccid2hctx_cwnd + 1);
402 hctx->ccid2hctx_ssacks = 0;
403 *maxincr = *maxincr - 1;
406 /* increased cwnd enough for this single ack */
407 hctx->ccid2hctx_ssacks = 0;
410 hctx->ccid2hctx_ssacks = 0;
411 hctx->ccid2hctx_acks++;
413 if (hctx->ccid2hctx_acks >= hctx->ccid2hctx_cwnd) {
414 ccid2_change_cwnd(sk, hctx->ccid2hctx_cwnd + 1);
415 hctx->ccid2hctx_acks = 0;
420 if (hctx->ccid2hctx_srtt == -1 ||
421 (jiffies - hctx->ccid2hctx_lastrtt) >= hctx->ccid2hctx_srtt) {
422 unsigned long r = jiffies - seqp->ccid2s_sent;
425 /* first measurement */
426 if (hctx->ccid2hctx_srtt == -1) {
427 ccid2_pr_debug("R: %lu Time=%lu seq=%llu\n",
428 r, jiffies, seqp->ccid2s_seq);
429 hctx->ccid2hctx_srtt = r;
430 hctx->ccid2hctx_rttvar = r >> 1;
433 long tmp = hctx->ccid2hctx_srtt - r;
438 hctx->ccid2hctx_rttvar *= 3;
439 hctx->ccid2hctx_rttvar >>= 2;
440 hctx->ccid2hctx_rttvar += tmp;
443 hctx->ccid2hctx_srtt *= 7;
444 hctx->ccid2hctx_srtt >>= 3;
446 hctx->ccid2hctx_srtt += tmp;
448 s = hctx->ccid2hctx_rttvar << 2;
449 /* clock granularity is 1 when based on jiffies */
452 hctx->ccid2hctx_rto = hctx->ccid2hctx_srtt + s;
454 /* must be at least a second */
455 s = hctx->ccid2hctx_rto / HZ;
456 /* DCCP doesn't require this [but I like it cuz my code sux] */
459 hctx->ccid2hctx_rto = HZ;
463 hctx->ccid2hctx_rto = HZ * 60;
465 hctx->ccid2hctx_lastrtt = jiffies;
467 ccid2_pr_debug("srtt: %ld rttvar: %ld rto: %ld (HZ=%d) R=%lu\n",
468 hctx->ccid2hctx_srtt, hctx->ccid2hctx_rttvar,
469 hctx->ccid2hctx_rto, HZ, r);
470 hctx->ccid2hctx_sent = 0;
473 /* we got a new ack, so re-start RTO timer */
474 ccid2_hc_tx_kill_rto_timer(sk);
475 ccid2_start_rto_timer(sk);
478 static void ccid2_hc_tx_dec_pipe(struct sock *sk)
480 struct ccid2_hc_tx_sock *hctx = ccid2_hc_tx_sk(sk);
482 hctx->ccid2hctx_pipe--;
483 BUG_ON(hctx->ccid2hctx_pipe < 0);
485 if (hctx->ccid2hctx_pipe == 0)
486 ccid2_hc_tx_kill_rto_timer(sk);
489 static void ccid2_hc_tx_packet_recv(struct sock *sk, struct sk_buff *skb)
491 struct dccp_sock *dp = dccp_sk(sk);
492 struct ccid2_hc_tx_sock *hctx = ccid2_hc_tx_sk(sk);
494 struct ccid2_seq *seqp;
495 unsigned char *vector;
496 unsigned char veclen;
500 unsigned int maxincr = 0;
502 ccid2_hc_tx_check_sanity(hctx);
503 /* check reverse path congestion */
504 seqno = DCCP_SKB_CB(skb)->dccpd_seq;
506 /* XXX this whole "algorithm" is broken. Need to fix it to keep track
507 * of the seqnos of the dupacks so that rpseq and rpdupack are correct
510 /* need to bootstrap */
511 if (hctx->ccid2hctx_rpdupack == -1) {
512 hctx->ccid2hctx_rpdupack = 0;
513 hctx->ccid2hctx_rpseq = seqno;
515 /* check if packet is consecutive */
516 if ((hctx->ccid2hctx_rpseq + 1) == seqno)
517 hctx->ccid2hctx_rpseq++;
518 /* it's a later packet */
519 else if (after48(seqno, hctx->ccid2hctx_rpseq)) {
520 hctx->ccid2hctx_rpdupack++;
522 /* check if we got enough dupacks */
523 if (hctx->ccid2hctx_rpdupack >=
524 hctx->ccid2hctx_numdupack) {
525 hctx->ccid2hctx_rpdupack = -1; /* XXX lame */
526 hctx->ccid2hctx_rpseq = 0;
528 ccid2_change_l_ack_ratio(sk, dp->dccps_l_ack_ratio << 1);
533 /* check forward path congestion */
534 /* still didn't send out new data packets */
535 if (hctx->ccid2hctx_seqh == hctx->ccid2hctx_seqt)
538 switch (DCCP_SKB_CB(skb)->dccpd_type) {
540 case DCCP_PKT_DATAACK:
546 ackno = DCCP_SKB_CB(skb)->dccpd_ack_seq;
547 seqp = hctx->ccid2hctx_seqh->ccid2s_prev;
549 /* If in slow-start, cwnd can increase at most Ack Ratio / 2 packets for
550 * this single ack. I round up.
553 maxincr = dp->dccps_l_ack_ratio >> 1;
556 /* go through all ack vectors */
557 while ((offset = ccid2_ackvector(sk, skb, offset,
558 &vector, &veclen)) != -1) {
559 /* go through this ack vector */
561 const u8 rl = *vector & DCCP_ACKVEC_LEN_MASK;
564 dccp_set_seqno(&ackno_end_rl, ackno - rl);
565 ccid2_pr_debug("ackvec start:%llu end:%llu\n", ackno,
567 /* if the seqno we are analyzing is larger than the
568 * current ackno, then move towards the tail of our
571 while (after48(seqp->ccid2s_seq, ackno)) {
572 if (seqp == hctx->ccid2hctx_seqt) {
576 seqp = seqp->ccid2s_prev;
581 /* check all seqnos in the range of the vector
584 while (between48(seqp->ccid2s_seq,ackno_end_rl,ackno)) {
585 const u8 state = (*vector &
586 DCCP_ACKVEC_STATE_MASK) >> 6;
588 /* new packet received or marked */
589 if (state != DCCP_ACKVEC_STATE_NOT_RECEIVED &&
590 !seqp->ccid2s_acked) {
592 DCCP_ACKVEC_STATE_ECN_MARKED) {
595 ccid2_new_ack(sk, seqp,
598 seqp->ccid2s_acked = 1;
599 ccid2_pr_debug("Got ack for %llu\n",
601 ccid2_hc_tx_dec_pipe(sk);
603 if (seqp == hctx->ccid2hctx_seqt) {
607 seqp = seqp->ccid2s_next;
613 dccp_set_seqno(&ackno, ackno_end_rl - 1);
620 /* The state about what is acked should be correct now
621 * Check for NUMDUPACK
623 seqp = hctx->ccid2hctx_seqh->ccid2s_prev;
626 if (seqp->ccid2s_acked) {
628 if (done == hctx->ccid2hctx_numdupack)
631 if (seqp == hctx->ccid2hctx_seqt)
633 seqp = seqp->ccid2s_prev;
636 /* If there are at least 3 acknowledgements, anything unacknowledged
637 * below the last sequence number is considered lost
639 if (done == hctx->ccid2hctx_numdupack) {
640 struct ccid2_seq *last_acked = seqp;
642 /* check for lost packets */
644 if (!seqp->ccid2s_acked) {
646 ccid2_hc_tx_dec_pipe(sk);
648 if (seqp == hctx->ccid2hctx_seqt)
650 seqp = seqp->ccid2s_prev;
653 hctx->ccid2hctx_seqt = last_acked;
656 /* trim acked packets in tail */
657 while (hctx->ccid2hctx_seqt != hctx->ccid2hctx_seqh) {
658 if (!hctx->ccid2hctx_seqt->ccid2s_acked)
661 hctx->ccid2hctx_seqt = hctx->ccid2hctx_seqt->ccid2s_next;
665 /* XXX do bit shifts guarantee a 0 as the new bit? */
666 ccid2_change_cwnd(sk, hctx->ccid2hctx_cwnd >> 1);
667 hctx->ccid2hctx_ssthresh = hctx->ccid2hctx_cwnd;
668 if (hctx->ccid2hctx_ssthresh < 2)
669 hctx->ccid2hctx_ssthresh = 2;
672 ccid2_hc_tx_check_sanity(hctx);
675 static int ccid2_hc_tx_init(struct ccid *ccid, struct sock *sk)
677 struct ccid2_hc_tx_sock *hctx = ccid_priv(ccid);
678 int seqcount = ccid2_seq_len;
681 /* XXX init variables with proper values */
682 hctx->ccid2hctx_cwnd = 1;
683 hctx->ccid2hctx_ssthresh = 10;
684 hctx->ccid2hctx_numdupack = 3;
686 /* XXX init ~ to window size... */
687 hctx->ccid2hctx_seqbuf = kmalloc(sizeof(*hctx->ccid2hctx_seqbuf) *
688 seqcount, gfp_any());
689 if (hctx->ccid2hctx_seqbuf == NULL)
692 for (i = 0; i < (seqcount - 1); i++) {
693 hctx->ccid2hctx_seqbuf[i].ccid2s_next =
694 &hctx->ccid2hctx_seqbuf[i + 1];
695 hctx->ccid2hctx_seqbuf[i + 1].ccid2s_prev =
696 &hctx->ccid2hctx_seqbuf[i];
698 hctx->ccid2hctx_seqbuf[seqcount - 1].ccid2s_next =
699 hctx->ccid2hctx_seqbuf;
700 hctx->ccid2hctx_seqbuf->ccid2s_prev =
701 &hctx->ccid2hctx_seqbuf[seqcount - 1];
703 hctx->ccid2hctx_seqh = hctx->ccid2hctx_seqbuf;
704 hctx->ccid2hctx_seqt = hctx->ccid2hctx_seqh;
705 hctx->ccid2hctx_sent = 0;
706 hctx->ccid2hctx_rto = 3 * HZ;
707 hctx->ccid2hctx_srtt = -1;
708 hctx->ccid2hctx_rttvar = -1;
709 hctx->ccid2hctx_lastrtt = 0;
710 hctx->ccid2hctx_rpdupack = -1;
712 hctx->ccid2hctx_rtotimer.function = &ccid2_hc_tx_rto_expire;
713 hctx->ccid2hctx_rtotimer.data = (unsigned long)sk;
714 init_timer(&hctx->ccid2hctx_rtotimer);
716 ccid2_hc_tx_check_sanity(hctx);
720 static void ccid2_hc_tx_exit(struct sock *sk)
722 struct ccid2_hc_tx_sock *hctx = ccid2_hc_tx_sk(sk);
724 ccid2_hc_tx_kill_rto_timer(sk);
725 kfree(hctx->ccid2hctx_seqbuf);
726 hctx->ccid2hctx_seqbuf = NULL;
729 static void ccid2_hc_rx_packet_recv(struct sock *sk, struct sk_buff *skb)
731 const struct dccp_sock *dp = dccp_sk(sk);
732 struct ccid2_hc_rx_sock *hcrx = ccid2_hc_rx_sk(sk);
734 switch (DCCP_SKB_CB(skb)->dccpd_type) {
736 case DCCP_PKT_DATAACK:
737 hcrx->ccid2hcrx_data++;
738 if (hcrx->ccid2hcrx_data >= dp->dccps_r_ack_ratio) {
740 hcrx->ccid2hcrx_data = 0;
746 static struct ccid_operations ccid2 = {
748 .ccid_name = "ccid2",
749 .ccid_owner = THIS_MODULE,
750 .ccid_hc_tx_obj_size = sizeof(struct ccid2_hc_tx_sock),
751 .ccid_hc_tx_init = ccid2_hc_tx_init,
752 .ccid_hc_tx_exit = ccid2_hc_tx_exit,
753 .ccid_hc_tx_send_packet = ccid2_hc_tx_send_packet,
754 .ccid_hc_tx_packet_sent = ccid2_hc_tx_packet_sent,
755 .ccid_hc_tx_packet_recv = ccid2_hc_tx_packet_recv,
756 .ccid_hc_rx_obj_size = sizeof(struct ccid2_hc_rx_sock),
757 .ccid_hc_rx_packet_recv = ccid2_hc_rx_packet_recv,
760 module_param(ccid2_debug, int, 0444);
761 MODULE_PARM_DESC(ccid2_debug, "Enable debug messages");
763 static __init int ccid2_module_init(void)
765 return ccid_register(&ccid2);
767 module_init(ccid2_module_init);
769 static __exit void ccid2_module_exit(void)
771 ccid_unregister(&ccid2);
773 module_exit(ccid2_module_exit);
775 MODULE_AUTHOR("Andrea Bittau <a.bittau@cs.ucl.ac.uk>");
776 MODULE_DESCRIPTION("DCCP TCP-Like (CCID2) CCID");
777 MODULE_LICENSE("GPL");
778 MODULE_ALIAS("net-dccp-ccid-2");