diff options
author | John Crispin <john@phrozen.org> | 2016-12-25 20:11:34 +0100 |
---|---|---|
committer | John Crispin <john@phrozen.org> | 2017-08-05 08:46:36 +0200 |
commit | 74d00a8c3849c1340efd713eb94b786e304c201f (patch) | |
tree | de481743de61c34da96ab5f9dba3af3edcfb8260 /target/linux/generic/pending-4.4/034-fq_codel-fix-memory-limitation-drift.patch | |
parent | de350550ef648d9728351b986b0516fa29465c45 (diff) | |
download | mtk-20170518-74d00a8c3849c1340efd713eb94b786e304c201f.zip mtk-20170518-74d00a8c3849c1340efd713eb94b786e304c201f.tar.gz mtk-20170518-74d00a8c3849c1340efd713eb94b786e304c201f.tar.bz2 |
kernel: split patches folder up into backport, pending and hack folders
* properly format/comment all patches
* merge debloat patches
* merge Kconfig patches
* merge swconfig patches
* merge hotplug patches
* drop 200-fix_localversion.patch - upstream
* drop 222-arm_zimage_none.patch - unused
* drop 252-mv_cesa_depends.patch - no longer required
* drop 410-mtd-move-forward-declaration-of-struct-mtd_info.patch - unused
* drop 661-fq_codel_keep_dropped_stats.patch - outdated
* drop 702-phy_add_aneg_done_function.patch - upstream
* drop 840-rtc7301.patch - unused
* drop 841-rtc_pt7c4338.patch - upstream
* drop 921-use_preinit_as_init.patch - unused
* drop spio-gpio-old and gpio-mmc - unused
Signed-off-by: John Crispin <john@phrozen.org>
Diffstat (limited to 'target/linux/generic/pending-4.4/034-fq_codel-fix-memory-limitation-drift.patch')
-rw-r--r-- | target/linux/generic/pending-4.4/034-fq_codel-fix-memory-limitation-drift.patch | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/target/linux/generic/pending-4.4/034-fq_codel-fix-memory-limitation-drift.patch b/target/linux/generic/pending-4.4/034-fq_codel-fix-memory-limitation-drift.patch new file mode 100644 index 0000000..45fff7b --- /dev/null +++ b/target/linux/generic/pending-4.4/034-fq_codel-fix-memory-limitation-drift.patch @@ -0,0 +1,40 @@ +From: Eric Dumazet <edumazet@google.com> +Date: Sun, 15 May 2016 18:16:38 -0700 +Subject: [PATCH] fq_codel: fix memory limitation drift + +memory_usage must be decreased in dequeue_func(), not in +fq_codel_dequeue(), otherwise packets dropped by Codel algo +are missing this decrease. + +Also we need to clear memory_usage in fq_codel_reset() + +Fixes: 95b58430abe7 ("fq_codel: add memory limitation per queue") +Signed-off-by: Eric Dumazet <edumazet@google.com> +--- + +--- a/net/sched/sch_fq_codel.c ++++ b/net/sched/sch_fq_codel.c +@@ -259,6 +259,7 @@ static struct sk_buff *dequeue(struct co + if (flow->head) { + skb = dequeue_head(flow); + q->backlogs[flow - q->flows] -= qdisc_pkt_len(skb); ++ q->memory_usage -= skb->truesize; + sch->q.qlen--; + } + return skb; +@@ -306,7 +307,6 @@ begin: + list_del_init(&flow->flowchain); + goto begin; + } +- q->memory_usage -= skb->truesize; + qdisc_bstats_update(sch, skb); + flow->deficit -= qdisc_pkt_len(skb); + /* We cant call qdisc_tree_reduce_backlog() if our qlen is 0, +@@ -343,6 +343,7 @@ static void fq_codel_reset(struct Qdisc + } + memset(q->backlogs, 0, q->flows_cnt * sizeof(u32)); + sch->q.qlen = 0; ++ q->memory_usage = 0; + } + + static const struct nla_policy fq_codel_policy[TCA_FQ_CODEL_MAX + 1] = { |