diff for duplicates of <20071204134810.GB18084@ghostprotocols.net> diff --git a/a/1.txt b/N1/1.txt index d600745..ebe9321 100644 --- a/a/1.txt +++ b/N1/1.txt @@ -43,7 +43,7 @@ error path. + + for (i = 0; i <= TFRC_NDUPACK; i++) { + h->ring[i] = kmem_cache_alloc(tfrc_rx_hist_slab, GFP_ATOMIC); -+ if (h->ring[i] = NULL) ++ if (h->ring[i] == NULL) + goto out_free; + } + @@ -60,7 +60,7 @@ error path. - Arnaldo -From 317c1ce69711fe7b0f89e23e84390a14c98c0f7e Mon Sep 17 00:00:00 2001 +>From 317c1ce69711fe7b0f89e23e84390a14c98c0f7e Mon Sep 17 00:00:00 2001 From: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Tue, 4 Dec 2007 11:46:19 -0200 Subject: [PATCH 7/7] [TFRC]: New rx history code @@ -135,7 +135,7 @@ index 5ff5aab..af64c1d 100644 ccid3_pr_debug("%s(%p) - entry \n", dccp_role(sk), sk); -+ if (unlikely(hcrx->ccid3hcrx_state = TFRC_RSTATE_TERM)) ++ if (unlikely(hcrx->ccid3hcrx_state == TFRC_RSTATE_TERM)) + return; + now = ktime_get_real(); @@ -151,7 +151,8 @@ index 5ff5aab..af64c1d 100644 - delta = ktime_us_delta(now, - hcrx->ccid3hcrx_tstamp_last_feedback); - DCCP_BUG_ON(delta < 0); -- hcrx->ccid3hcrx_x_recv - scaled_div32(hcrx->ccid3hcrx_bytes_recv, delta); +- hcrx->ccid3hcrx_x_recv = +- scaled_div32(hcrx->ccid3hcrx_bytes_recv, delta); + case CCID3_FBACK_PARAM_CHANGE: + /* + * When parameters change (new loss or p > p_prev), we do not @@ -171,7 +172,8 @@ index 5ff5aab..af64c1d 100644 + if (delta <= 0) + DCCP_BUG("delta (%ld) <= 0", (long)delta); + else -+ hcrx->ccid3hcrx_x_recv + scaled_div32(hcrx->ccid3hcrx_bytes_recv, delta); ++ hcrx->ccid3hcrx_x_recv = ++ scaled_div32(hcrx->ccid3hcrx_bytes_recv, delta); break; - case TFRC_RSTATE_TERM: - DCCP_BUG("%s(%p) - Illegal state TERM", dccp_role(sk), sk); @@ -180,7 +182,7 @@ index 5ff5aab..af64c1d 100644 } - packet = tfrc_rx_hist_find_data_packet(&hcrx->ccid3hcrx_hist); -- if (unlikely(packet = NULL)) { +- if (unlikely(packet == NULL)) { - DCCP_WARN("%s(%p), no data packet in history!\n", - dccp_role(sk), sk); - return; @@ -193,7 +195,7 @@ index 5ff5aab..af64c1d 100644 + hcrx->ccid3hcrx_last_counter = dccp_hdr(skb)->dccph_ccval; hcrx->ccid3hcrx_bytes_recv = 0; -- if (hcrx->ccid3hcrx_p = 0) +- if (hcrx->ccid3hcrx_p == 0) - hcrx->ccid3hcrx_pinv = ~0U; /* see RFC 4342, 8.5 */ - else if (hcrx->ccid3hcrx_p > 1000000) { - DCCP_WARN("p (%u) > 100%%\n", hcrx->ccid3hcrx_p); @@ -209,7 +211,8 @@ index 5ff5aab..af64c1d 100644 struct tfrc_rx_hist_entry *packet) { - struct ccid3_hc_rx_sock *hcrx = ccid3_hc_rx_sk(sk); -- struct tfrc_rx_hist_entry *rx_hist - tfrc_rx_hist_head(&hcrx->ccid3hcrx_hist); +- struct tfrc_rx_hist_entry *rx_hist = +- tfrc_rx_hist_head(&hcrx->ccid3hcrx_hist); - u64 seqno = packet->tfrchrx_seqno; - u64 tmp_seqno; - int loss = 0; @@ -282,18 +285,18 @@ index 5ff5aab..af64c1d 100644 - switch (DCCP_SKB_CB(skb)->dccpd_type) { - case DCCP_PKT_ACK: -- if (hcrx->ccid3hcrx_state = TFRC_RSTATE_NO_DATA) +- if (hcrx->ccid3hcrx_state == TFRC_RSTATE_NO_DATA) + if (hcrx->ccid3hcrx_state != TFRC_RSTATE_NO_DATA) { + if (tfrc_rx_hist_duplicate(&hcrx->ccid3hcrx_hist, skb)) return; - case DCCP_PKT_DATAACK: -- if (opt_recv->dccpor_timestamp_echo = 0) +- if (opt_recv->dccpor_timestamp_echo == 0) - break; - r_sample = dccp_timestamp() - opt_recv->dccpor_timestamp_echo; - rtt_prev = hcrx->ccid3hcrx_rtt; - r_sample = dccp_sample_rtt(sk, 10 * r_sample); - -- if (hcrx->ccid3hcrx_state = TFRC_RSTATE_NO_DATA) +- if (hcrx->ccid3hcrx_state == TFRC_RSTATE_NO_DATA) - hcrx->ccid3hcrx_rtt = r_sample; - else - hcrx->ccid3hcrx_rtt = (hcrx->ccid3hcrx_rtt * 9) / 10 + @@ -311,7 +314,7 @@ index 5ff5aab..af64c1d 100644 - } - - packet = tfrc_rx_hist_entry_new(opt_recv->dccpor_ndp, skb, GFP_ATOMIC); -- if (unlikely(packet = NULL)) { +- if (unlikely(packet == NULL)) { - DCCP_WARN("%s(%p), Not enough mem to add rx packet " - "to history, consider it lost!\n", dccp_role(sk), sk); - return; @@ -319,7 +322,7 @@ index 5ff5aab..af64c1d 100644 - - loss = ccid3_hc_rx_detect_loss(sk, packet); - -- if (DCCP_SKB_CB(skb)->dccpd_type = DCCP_PKT_ACK) +- if (DCCP_SKB_CB(skb)->dccpd_type == DCCP_PKT_ACK) - return; - - payload_size = skb->len - dccp_hdr(skb)->dccph_doff * 4; @@ -352,7 +355,8 @@ index 5ff5aab..af64c1d 100644 + if (list_empty(&hcrx->ccid3hcrx_li_hist)) { /* no loss so far: p = 0 */ + const u32 sample = tfrc_rx_hist_sample_rtt(&hcrx->ccid3hcrx_hist, skb); + if (sample != 0) -+ hcrx->ccid3hcrx_rtt + tfrc_ewma(hcrx->ccid3hcrx_rtt, sample, 9); ++ hcrx->ccid3hcrx_rtt = ++ tfrc_ewma(hcrx->ccid3hcrx_rtt, sample, 9); + } + + ccid3_hc_rx_update_s(hcrx, payload_size); @@ -405,7 +409,8 @@ index 5ff5aab..af64c1d 100644 hcrx->ccid3hcrx_state = TFRC_RSTATE_NO_DATA; - INIT_LIST_HEAD(&hcrx->ccid3hcrx_hist); INIT_LIST_HEAD(&hcrx->ccid3hcrx_li_hist); -- hcrx->ccid3hcrx_tstamp_last_feedback - hcrx->ccid3hcrx_tstamp_last_ack = ktime_get_real(); +- hcrx->ccid3hcrx_tstamp_last_feedback = +- hcrx->ccid3hcrx_tstamp_last_ack = ktime_get_real(); - return 0; + return tfrc_rx_hist_alloc(&hcrx->ccid3hcrx_hist); } @@ -483,7 +488,7 @@ index a5f59af..71080ca 100644 dccp_pr_debug("%s(%p), receive rate=%u bytes/s, implied " "loss rate=%u\n", dccp_role(sk), sk, x_recv, p); -- if (p = 0) +- if (p == 0) - return ~0; - else + if (p != 0) @@ -600,7 +605,7 @@ index 255cca1..56a0254 100644 + int i; - list_for_each_entry(entry, list, tfrchrx_node) -- if (entry->tfrchrx_seqno = seq) { +- if (entry->tfrchrx_seqno == seq) { - packet = entry; - break; - } @@ -610,7 +615,7 @@ index 255cca1..56a0254 100644 - if (packet) - *ccval = packet->tfrchrx_ccval; + for (i = 1; i <= h->loss_count; i++) -+ if (tfrc_rx_hist_entry(h, i)->tfrchrx_seqno = seq) ++ if (tfrc_rx_hist_entry(h, i)->tfrchrx_seqno == seq) + return 1; - return packet != NULL; @@ -627,8 +632,8 @@ index 255cca1..56a0254 100644 - struct tfrc_rx_hist_entry *entry, *packet = NULL; - - list_for_each_entry(entry, list, tfrchrx_node) -- if (entry->tfrchrx_type = DCCP_PKT_DATA || -- entry->tfrchrx_type = DCCP_PKT_DATAACK) { +- if (entry->tfrchrx_type == DCCP_PKT_DATA || +- entry->tfrchrx_type == DCCP_PKT_DATAACK) { - packet = entry; - break; - } @@ -672,7 +677,7 @@ index 255cca1..56a0254 100644 - - if (!list_empty(li_list)) { - list_for_each_entry_safe(entry, next, rx_list, tfrchrx_node) { -- if (num_later = 0) { +- if (num_later == 0) { - if (after48(nonloss_seqno, - entry->tfrchrx_seqno)) { - list_del_init(&entry->tfrchrx_node); @@ -690,7 +695,7 @@ index 255cca1..56a0254 100644 - * rtt:s of data packets to approximate rtt. - */ - list_for_each_entry_safe(entry, next, rx_list, tfrchrx_node) { -- if (num_later = 0) { +- if (num_later == 0) { - switch (step) { - case 0: - step = 1; @@ -739,7 +744,7 @@ index 255cca1..56a0254 100644 + + for (i = 0; i <= TFRC_NDUPACK; i++) { + h->ring[i] = kmem_cache_alloc(tfrc_rx_hist_slab, GFP_ATOMIC); -+ if (h->ring[i] = NULL) ++ if (h->ring[i] == NULL) + goto out_free; + } + @@ -791,7 +796,7 @@ index 255cca1..56a0254 100644 + tfrc_rx_hist_rtt_last_s(h)->tfrchrx_ccval); + + if (delta_v < 1 || delta_v > 4) { /* unsuitable CCVal delta */ -+ if (h->rtt_sample_prev = 2) { /* previous candidate stored */ ++ if (h->rtt_sample_prev == 2) { /* previous candidate stored */ + sample = SUB16(tfrc_rx_hist_rtt_prev_s(h)->tfrchrx_ccval, + tfrc_rx_hist_rtt_last_s(h)->tfrchrx_ccval); + if (sample) @@ -813,7 +818,7 @@ index 255cca1..56a0254 100644 + goto keep_ref_for_next_time; + } + -+ } else if (delta_v = 4) /* optimal match */ ++ } else if (delta_v == 4) /* optimal match */ + sample = ktime_to_us(net_timedelta(tfrc_rx_hist_rtt_last_s(h)->tfrchrx_tstamp)); + else { /* suboptimal match */ + h->rtt_sample_prev = 2; @@ -924,8 +929,8 @@ index 5b0b983..dac275f 100644 -static inline int - tfrc_rx_hist_entry_data_packet(const struct tfrc_rx_hist_entry *entry) -{ -- return entry->tfrchrx_type = DCCP_PKT_DATA || -- entry->tfrchrx_type = DCCP_PKT_DATAACK; +- return entry->tfrchrx_type == DCCP_PKT_DATA || +- entry->tfrchrx_type == DCCP_PKT_DATAACK; -} +extern void tfrc_rx_hist_add_packet(struct tfrc_rx_hist *h, + const struct sk_buff *skb, const u32 ndp); @@ -1007,10 +1012,10 @@ index 0000000..70d5c31 + +static inline bool tfrc_rx_hist_entry_data_packet(const struct tfrc_rx_hist_entry *h) +{ -+ return h->tfrchrx_type = DCCP_PKT_DATA || -+ h->tfrchrx_type = DCCP_PKT_DATAACK || -+ h->tfrchrx_type = DCCP_PKT_REQUEST || -+ h->tfrchrx_type = DCCP_PKT_RESPONSE; ++ return h->tfrchrx_type == DCCP_PKT_DATA || ++ h->tfrchrx_type == DCCP_PKT_DATAACK || ++ h->tfrchrx_type == DCCP_PKT_REQUEST || ++ h->tfrchrx_type == DCCP_PKT_RESPONSE; +} + +#endif /* _DCCP_PKT_HIST_INT_ */ diff --git a/a/content_digest b/N1/content_digest index 8f29df4..9d0d752 100644 --- a/a/content_digest +++ b/N1/content_digest @@ -1,7 +1,19 @@ + "ref\01196631416-17778-1-git-send-email-acme@redhat.com\0" + "ref\01196631416-17778-2-git-send-email-acme@redhat.com\0" + "ref\01196631416-17778-3-git-send-email-acme@redhat.com\0" + "ref\01196631416-17778-4-git-send-email-acme@redhat.com\0" + "ref\01196631416-17778-5-git-send-email-acme@redhat.com\0" + "ref\01196631416-17778-6-git-send-email-acme@redhat.com\0" + "ref\01196631416-17778-7-git-send-email-acme@redhat.com\0" + "ref\01196631416-17778-8-git-send-email-acme@redhat.com\0" + "ref\020071204065517.GA4404@gerrit.erg.abdn.ac.uk\0" + "ref\020071204115939.GA18084@ghostprotocols.net\0" "From\0Arnaldo Carvalho de Melo <acme@redhat.com>\0" "Subject\0[PATCH 7/7][TAKE 2][TFRC] New rx history code\0" - "Date\0Tue, 04 Dec 2007 13:48:10 +0000\0" - "To\0dccp@vger.kernel.org\0" + "Date\0Tue, 4 Dec 2007 11:48:10 -0200\0" + "To\0Gerrit Renker <gerrit@erg.abdn.ac.uk>" + netdev@vger.kernel.org + " dccp@vger.kernel.org\0" "\00:1\0" "b\0" "Em Tue, Dec 04, 2007 at 09:59:39AM -0200, Arnaldo Carvalho de Melo escreveu:\n" @@ -49,7 +61,7 @@ "+\n" "+\tfor (i = 0; i <= TFRC_NDUPACK; i++) {\n" "+\t\th->ring[i] = kmem_cache_alloc(tfrc_rx_hist_slab, GFP_ATOMIC);\n" - "+\t\tif (h->ring[i] = NULL)\n" + "+\t\tif (h->ring[i] == NULL)\n" "+\t\t\tgoto out_free;\n" "+\t}\n" "+\n" @@ -66,7 +78,7 @@ "\n" "- Arnaldo\n" "\n" - "From 317c1ce69711fe7b0f89e23e84390a14c98c0f7e Mon Sep 17 00:00:00 2001\n" + ">From 317c1ce69711fe7b0f89e23e84390a14c98c0f7e Mon Sep 17 00:00:00 2001\n" "From: Arnaldo Carvalho de Melo <acme@redhat.com>\n" "Date: Tue, 4 Dec 2007 11:46:19 -0200\n" "Subject: [PATCH 7/7] [TFRC]: New rx history code\n" @@ -141,7 +153,7 @@ " \n" " \tccid3_pr_debug(\"%s(%p) - entry \\n\", dccp_role(sk), sk);\n" " \n" - "+\tif (unlikely(hcrx->ccid3hcrx_state = TFRC_RSTATE_TERM))\n" + "+\tif (unlikely(hcrx->ccid3hcrx_state == TFRC_RSTATE_TERM))\n" "+\t\treturn;\n" "+\n" " \tnow = ktime_get_real();\n" @@ -157,7 +169,8 @@ "-\t\tdelta = ktime_us_delta(now,\n" "-\t\t\t\t hcrx->ccid3hcrx_tstamp_last_feedback);\n" "-\t\tDCCP_BUG_ON(delta < 0);\n" - "-\t\thcrx->ccid3hcrx_x_recv -\t\t\tscaled_div32(hcrx->ccid3hcrx_bytes_recv, delta);\n" + "-\t\thcrx->ccid3hcrx_x_recv =\n" + "-\t\t\tscaled_div32(hcrx->ccid3hcrx_bytes_recv, delta);\n" "+\tcase CCID3_FBACK_PARAM_CHANGE:\n" "+\t\t/*\n" "+\t\t * When parameters change (new loss or p > p_prev), we do not\n" @@ -177,7 +190,8 @@ "+\t\tif (delta <= 0)\n" "+\t\t\tDCCP_BUG(\"delta (%ld) <= 0\", (long)delta);\n" "+\t\telse\n" - "+\t\t\thcrx->ccid3hcrx_x_recv +\t\t\t\tscaled_div32(hcrx->ccid3hcrx_bytes_recv, delta);\n" + "+\t\t\thcrx->ccid3hcrx_x_recv =\n" + "+\t\t\t\tscaled_div32(hcrx->ccid3hcrx_bytes_recv, delta);\n" " \t\tbreak;\n" "-\tcase TFRC_RSTATE_TERM:\n" "-\t\tDCCP_BUG(\"%s(%p) - Illegal state TERM\", dccp_role(sk), sk);\n" @@ -186,7 +200,7 @@ " \t}\n" " \n" "-\tpacket = tfrc_rx_hist_find_data_packet(&hcrx->ccid3hcrx_hist);\n" - "-\tif (unlikely(packet = NULL)) {\n" + "-\tif (unlikely(packet == NULL)) {\n" "-\t\tDCCP_WARN(\"%s(%p), no data packet in history!\\n\",\n" "-\t\t\t dccp_role(sk), sk);\n" "-\t\treturn;\n" @@ -199,7 +213,7 @@ "+\thcrx->ccid3hcrx_last_counter\t = dccp_hdr(skb)->dccph_ccval;\n" " \thcrx->ccid3hcrx_bytes_recv\t = 0;\n" " \n" - "-\tif (hcrx->ccid3hcrx_p = 0)\n" + "-\tif (hcrx->ccid3hcrx_p == 0)\n" "-\t\thcrx->ccid3hcrx_pinv = ~0U;\t/* see RFC 4342, 8.5 */\n" "-\telse if (hcrx->ccid3hcrx_p > 1000000) {\n" "-\t\tDCCP_WARN(\"p (%u) > 100%%\\n\", hcrx->ccid3hcrx_p);\n" @@ -215,7 +229,8 @@ " \t\t\t\t struct tfrc_rx_hist_entry *packet)\n" " {\n" "-\tstruct ccid3_hc_rx_sock *hcrx = ccid3_hc_rx_sk(sk);\n" - "-\tstruct tfrc_rx_hist_entry *rx_hist -\t\t\t\ttfrc_rx_hist_head(&hcrx->ccid3hcrx_hist);\n" + "-\tstruct tfrc_rx_hist_entry *rx_hist =\n" + "-\t\t\t\ttfrc_rx_hist_head(&hcrx->ccid3hcrx_hist);\n" "-\tu64 seqno = packet->tfrchrx_seqno;\n" "-\tu64 tmp_seqno;\n" "-\tint loss = 0;\n" @@ -288,18 +303,18 @@ " \n" "-\tswitch (DCCP_SKB_CB(skb)->dccpd_type) {\n" "-\tcase DCCP_PKT_ACK:\n" - "-\t\tif (hcrx->ccid3hcrx_state = TFRC_RSTATE_NO_DATA)\n" + "-\t\tif (hcrx->ccid3hcrx_state == TFRC_RSTATE_NO_DATA)\n" "+\tif (hcrx->ccid3hcrx_state != TFRC_RSTATE_NO_DATA) {\n" "+\t\tif (tfrc_rx_hist_duplicate(&hcrx->ccid3hcrx_hist, skb))\n" " \t\t\treturn;\n" "-\tcase DCCP_PKT_DATAACK:\n" - "-\t\tif (opt_recv->dccpor_timestamp_echo = 0)\n" + "-\t\tif (opt_recv->dccpor_timestamp_echo == 0)\n" "-\t\t\tbreak;\n" "-\t\tr_sample = dccp_timestamp() - opt_recv->dccpor_timestamp_echo;\n" "-\t\trtt_prev = hcrx->ccid3hcrx_rtt;\n" "-\t\tr_sample = dccp_sample_rtt(sk, 10 * r_sample);\n" "-\n" - "-\t\tif (hcrx->ccid3hcrx_state = TFRC_RSTATE_NO_DATA)\n" + "-\t\tif (hcrx->ccid3hcrx_state == TFRC_RSTATE_NO_DATA)\n" "-\t\t\thcrx->ccid3hcrx_rtt = r_sample;\n" "-\t\telse\n" "-\t\t\thcrx->ccid3hcrx_rtt = (hcrx->ccid3hcrx_rtt * 9) / 10 +\n" @@ -317,7 +332,7 @@ "-\t}\n" "-\n" "-\tpacket = tfrc_rx_hist_entry_new(opt_recv->dccpor_ndp, skb, GFP_ATOMIC);\n" - "-\tif (unlikely(packet = NULL)) {\n" + "-\tif (unlikely(packet == NULL)) {\n" "-\t\tDCCP_WARN(\"%s(%p), Not enough mem to add rx packet \"\n" "-\t\t\t \"to history, consider it lost!\\n\", dccp_role(sk), sk);\n" "-\t\treturn;\n" @@ -325,7 +340,7 @@ "-\n" "-\tloss = ccid3_hc_rx_detect_loss(sk, packet);\n" "-\n" - "-\tif (DCCP_SKB_CB(skb)->dccpd_type = DCCP_PKT_ACK)\n" + "-\tif (DCCP_SKB_CB(skb)->dccpd_type == DCCP_PKT_ACK)\n" "-\t\treturn;\n" "-\n" "-\tpayload_size = skb->len - dccp_hdr(skb)->dccph_doff * 4;\n" @@ -358,7 +373,8 @@ "+\t\t\tif (list_empty(&hcrx->ccid3hcrx_li_hist)) { /* no loss so far: p = 0 */\n" "+\t\t\t\tconst u32 sample = tfrc_rx_hist_sample_rtt(&hcrx->ccid3hcrx_hist, skb);\n" "+\t\t\t\tif (sample != 0)\n" - "+\t\t\t\t\thcrx->ccid3hcrx_rtt +\t\t\t\t\t\ttfrc_ewma(hcrx->ccid3hcrx_rtt, sample, 9);\n" + "+\t\t\t\t\thcrx->ccid3hcrx_rtt =\n" + "+\t\t\t\t\t\ttfrc_ewma(hcrx->ccid3hcrx_rtt, sample, 9);\n" "+\t\t\t}\n" "+\n" "+\t\t\tccid3_hc_rx_update_s(hcrx, payload_size);\n" @@ -411,7 +427,8 @@ " \thcrx->ccid3hcrx_state = TFRC_RSTATE_NO_DATA;\n" "-\tINIT_LIST_HEAD(&hcrx->ccid3hcrx_hist);\n" " \tINIT_LIST_HEAD(&hcrx->ccid3hcrx_li_hist);\n" - "-\thcrx->ccid3hcrx_tstamp_last_feedback -\t\thcrx->ccid3hcrx_tstamp_last_ack = ktime_get_real();\n" + "-\thcrx->ccid3hcrx_tstamp_last_feedback =\n" + "-\t\thcrx->ccid3hcrx_tstamp_last_ack = ktime_get_real();\n" "-\treturn 0;\n" "+\treturn tfrc_rx_hist_alloc(&hcrx->ccid3hcrx_hist);\n" " }\n" @@ -489,7 +506,7 @@ " \tdccp_pr_debug(\"%s(%p), receive rate=%u bytes/s, implied \"\n" " \t\t \"loss rate=%u\\n\", dccp_role(sk), sk, x_recv, p);\n" " \n" - "-\tif (p = 0)\n" + "-\tif (p == 0)\n" "-\t\treturn ~0;\n" "-\telse\n" "+\tif (p != 0)\n" @@ -606,7 +623,7 @@ "+\tint i;\n" " \n" "-\tlist_for_each_entry(entry, list, tfrchrx_node)\n" - "-\t\tif (entry->tfrchrx_seqno = seq) {\n" + "-\t\tif (entry->tfrchrx_seqno == seq) {\n" "-\t\t\tpacket = entry;\n" "-\t\t\tbreak;\n" "-\t\t}\n" @@ -616,7 +633,7 @@ "-\tif (packet)\n" "-\t\t*ccval = packet->tfrchrx_ccval;\n" "+\tfor (i = 1; i <= h->loss_count; i++)\n" - "+\t\tif (tfrc_rx_hist_entry(h, i)->tfrchrx_seqno = seq)\n" + "+\t\tif (tfrc_rx_hist_entry(h, i)->tfrchrx_seqno == seq)\n" "+\t\t\treturn 1;\n" " \n" "-\treturn packet != NULL;\n" @@ -633,8 +650,8 @@ "-\tstruct tfrc_rx_hist_entry *entry, *packet = NULL;\n" "-\n" "-\tlist_for_each_entry(entry, list, tfrchrx_node)\n" - "-\t\tif (entry->tfrchrx_type = DCCP_PKT_DATA ||\n" - "-\t\t entry->tfrchrx_type = DCCP_PKT_DATAACK) {\n" + "-\t\tif (entry->tfrchrx_type == DCCP_PKT_DATA ||\n" + "-\t\t entry->tfrchrx_type == DCCP_PKT_DATAACK) {\n" "-\t\t\tpacket = entry;\n" "-\t\t\tbreak;\n" "-\t\t}\n" @@ -678,7 +695,7 @@ "-\n" "-\tif (!list_empty(li_list)) {\n" "-\t\tlist_for_each_entry_safe(entry, next, rx_list, tfrchrx_node) {\n" - "-\t\t\tif (num_later = 0) {\n" + "-\t\t\tif (num_later == 0) {\n" "-\t\t\t\tif (after48(nonloss_seqno,\n" "-\t\t\t\t entry->tfrchrx_seqno)) {\n" "-\t\t\t\t\tlist_del_init(&entry->tfrchrx_node);\n" @@ -696,7 +713,7 @@ "-\t\t * rtt:s of data packets to approximate rtt.\n" "-\t\t */\n" "-\t\tlist_for_each_entry_safe(entry, next, rx_list, tfrchrx_node) {\n" - "-\t\t\tif (num_later = 0) {\n" + "-\t\t\tif (num_later == 0) {\n" "-\t\t\t\tswitch (step) {\n" "-\t\t\t\tcase 0:\n" "-\t\t\t\t\tstep = 1;\n" @@ -745,7 +762,7 @@ "+\n" "+\tfor (i = 0; i <= TFRC_NDUPACK; i++) {\n" "+\t\th->ring[i] = kmem_cache_alloc(tfrc_rx_hist_slab, GFP_ATOMIC);\n" - "+\t\tif (h->ring[i] = NULL)\n" + "+\t\tif (h->ring[i] == NULL)\n" "+\t\t\tgoto out_free;\n" "+\t}\n" "+\n" @@ -797,7 +814,7 @@ "+\t \t\t tfrc_rx_hist_rtt_last_s(h)->tfrchrx_ccval);\n" "+\n" "+\tif (delta_v < 1 || delta_v > 4) {\t/* unsuitable CCVal delta */\n" - "+\t\tif (h->rtt_sample_prev = 2) {\t/* previous candidate stored */\n" + "+\t\tif (h->rtt_sample_prev == 2) {\t/* previous candidate stored */\n" "+\t\t\tsample = SUB16(tfrc_rx_hist_rtt_prev_s(h)->tfrchrx_ccval,\n" "+\t\t\t\t tfrc_rx_hist_rtt_last_s(h)->tfrchrx_ccval);\n" "+\t\t\tif (sample)\n" @@ -819,7 +836,7 @@ "+\t\t\tgoto keep_ref_for_next_time;\n" "+\t\t}\n" "+\n" - "+\t} else if (delta_v = 4) /* optimal match */\n" + "+\t} else if (delta_v == 4) /* optimal match */\n" "+\t\tsample = ktime_to_us(net_timedelta(tfrc_rx_hist_rtt_last_s(h)->tfrchrx_tstamp));\n" "+\telse {\t\t\t /* suboptimal match */\n" "+\t\th->rtt_sample_prev = 2;\n" @@ -930,8 +947,8 @@ "-static inline int\n" "-\ttfrc_rx_hist_entry_data_packet(const struct tfrc_rx_hist_entry *entry)\n" "-{\n" - "-\treturn entry->tfrchrx_type = DCCP_PKT_DATA ||\n" - "-\t entry->tfrchrx_type = DCCP_PKT_DATAACK;\n" + "-\treturn entry->tfrchrx_type == DCCP_PKT_DATA ||\n" + "-\t entry->tfrchrx_type == DCCP_PKT_DATAACK;\n" "-}\n" "+extern void tfrc_rx_hist_add_packet(struct tfrc_rx_hist *h,\n" "+\t\t\t\t const struct sk_buff *skb, const u32 ndp);\n" @@ -1013,14 +1030,14 @@ "+\n" "+static inline bool tfrc_rx_hist_entry_data_packet(const struct tfrc_rx_hist_entry *h)\n" "+{\n" - "+\treturn h->tfrchrx_type = DCCP_PKT_DATA\t ||\n" - "+\t h->tfrchrx_type = DCCP_PKT_DATAACK ||\n" - "+\t h->tfrchrx_type = DCCP_PKT_REQUEST ||\n" - "+\t h->tfrchrx_type = DCCP_PKT_RESPONSE;\n" + "+\treturn h->tfrchrx_type == DCCP_PKT_DATA\t ||\n" + "+\t h->tfrchrx_type == DCCP_PKT_DATAACK ||\n" + "+\t h->tfrchrx_type == DCCP_PKT_REQUEST ||\n" + "+\t h->tfrchrx_type == DCCP_PKT_RESPONSE;\n" "+}\n" "+\n" "+#endif /* _DCCP_PKT_HIST_INT_ */\n" "-- \n" 1.5.3.4 -a280234545c996e96d5997bb0e7624a8184f0a8c3f9262ef2dc1f354f9a5e28a +7f8780330610ae5af6c23fd71e927d0db22b9244ea15cb132a99a2d818f5b52f
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.