Loading include/net/sch_generic.h +11 −6 Original line number Diff line number Diff line Loading @@ -306,6 +306,11 @@ static inline bool qdisc_tx_is_noop(const struct net_device *dev) return true; } static inline unsigned int qdisc_pkt_len(struct sk_buff *skb) { return skb->len; } static inline int qdisc_enqueue(struct sk_buff *skb, struct Qdisc *sch) { return sch->enqueue(skb, sch); Loading @@ -320,8 +325,8 @@ static inline int __qdisc_enqueue_tail(struct sk_buff *skb, struct Qdisc *sch, struct sk_buff_head *list) { __skb_queue_tail(list, skb); sch->qstats.backlog += skb->len; sch->bstats.bytes += skb->len; sch->qstats.backlog += qdisc_pkt_len(skb); sch->bstats.bytes += qdisc_pkt_len(skb); sch->bstats.packets++; return NET_XMIT_SUCCESS; Loading @@ -338,7 +343,7 @@ static inline struct sk_buff *__qdisc_dequeue_head(struct Qdisc *sch, struct sk_buff *skb = __skb_dequeue(list); if (likely(skb != NULL)) sch->qstats.backlog -= skb->len; sch->qstats.backlog -= qdisc_pkt_len(skb); return skb; } Loading @@ -354,7 +359,7 @@ static inline struct sk_buff *__qdisc_dequeue_tail(struct Qdisc *sch, struct sk_buff *skb = __skb_dequeue_tail(list); if (likely(skb != NULL)) sch->qstats.backlog -= skb->len; sch->qstats.backlog -= qdisc_pkt_len(skb); return skb; } Loading @@ -368,7 +373,7 @@ static inline int __qdisc_requeue(struct sk_buff *skb, struct Qdisc *sch, struct sk_buff_head *list) { __skb_queue_head(list, skb); sch->qstats.backlog += skb->len; sch->qstats.backlog += qdisc_pkt_len(skb); sch->qstats.requeues++; return NET_XMIT_SUCCESS; Loading Loading @@ -401,7 +406,7 @@ static inline unsigned int __qdisc_queue_drop(struct Qdisc *sch, struct sk_buff *skb = __qdisc_dequeue_tail(sch, list); if (likely(skb != NULL)) { unsigned int len = skb->len; unsigned int len = qdisc_pkt_len(skb); kfree_skb(skb); return len; } Loading net/sched/act_gact.c +1 −1 Original line number Diff line number Diff line Loading @@ -139,7 +139,7 @@ static int tcf_gact(struct sk_buff *skb, struct tc_action *a, struct tcf_result #else action = gact->tcf_action; #endif gact->tcf_bstats.bytes += skb->len; gact->tcf_bstats.bytes += qdisc_pkt_len(skb); gact->tcf_bstats.packets++; if (action == TC_ACT_SHOT) gact->tcf_qstats.drops++; Loading net/sched/act_ipt.c +1 −1 Original line number Diff line number Diff line Loading @@ -205,7 +205,7 @@ static int tcf_ipt(struct sk_buff *skb, struct tc_action *a, spin_lock(&ipt->tcf_lock); ipt->tcf_tm.lastuse = jiffies; ipt->tcf_bstats.bytes += skb->len; ipt->tcf_bstats.bytes += qdisc_pkt_len(skb); ipt->tcf_bstats.packets++; /* yes, we have to worry about both in and out dev Loading net/sched/act_mirred.c +2 −2 Original line number Diff line number Diff line Loading @@ -164,7 +164,7 @@ bad_mirred: if (skb2 != NULL) kfree_skb(skb2); m->tcf_qstats.overlimits++; m->tcf_bstats.bytes += skb->len; m->tcf_bstats.bytes += qdisc_pkt_len(skb); m->tcf_bstats.packets++; spin_unlock(&m->tcf_lock); /* should we be asking for packet to be dropped? Loading @@ -184,7 +184,7 @@ bad_mirred: goto bad_mirred; } m->tcf_bstats.bytes += skb2->len; m->tcf_bstats.bytes += qdisc_pkt_len(skb2); m->tcf_bstats.packets++; if (!(at & AT_EGRESS)) if (m->tcfm_ok_push) Loading net/sched/act_nat.c +1 −1 Original line number Diff line number Diff line Loading @@ -124,7 +124,7 @@ static int tcf_nat(struct sk_buff *skb, struct tc_action *a, egress = p->flags & TCA_NAT_FLAG_EGRESS; action = p->tcf_action; p->tcf_bstats.bytes += skb->len; p->tcf_bstats.bytes += qdisc_pkt_len(skb); p->tcf_bstats.packets++; spin_unlock(&p->tcf_lock); Loading Loading
include/net/sch_generic.h +11 −6 Original line number Diff line number Diff line Loading @@ -306,6 +306,11 @@ static inline bool qdisc_tx_is_noop(const struct net_device *dev) return true; } static inline unsigned int qdisc_pkt_len(struct sk_buff *skb) { return skb->len; } static inline int qdisc_enqueue(struct sk_buff *skb, struct Qdisc *sch) { return sch->enqueue(skb, sch); Loading @@ -320,8 +325,8 @@ static inline int __qdisc_enqueue_tail(struct sk_buff *skb, struct Qdisc *sch, struct sk_buff_head *list) { __skb_queue_tail(list, skb); sch->qstats.backlog += skb->len; sch->bstats.bytes += skb->len; sch->qstats.backlog += qdisc_pkt_len(skb); sch->bstats.bytes += qdisc_pkt_len(skb); sch->bstats.packets++; return NET_XMIT_SUCCESS; Loading @@ -338,7 +343,7 @@ static inline struct sk_buff *__qdisc_dequeue_head(struct Qdisc *sch, struct sk_buff *skb = __skb_dequeue(list); if (likely(skb != NULL)) sch->qstats.backlog -= skb->len; sch->qstats.backlog -= qdisc_pkt_len(skb); return skb; } Loading @@ -354,7 +359,7 @@ static inline struct sk_buff *__qdisc_dequeue_tail(struct Qdisc *sch, struct sk_buff *skb = __skb_dequeue_tail(list); if (likely(skb != NULL)) sch->qstats.backlog -= skb->len; sch->qstats.backlog -= qdisc_pkt_len(skb); return skb; } Loading @@ -368,7 +373,7 @@ static inline int __qdisc_requeue(struct sk_buff *skb, struct Qdisc *sch, struct sk_buff_head *list) { __skb_queue_head(list, skb); sch->qstats.backlog += skb->len; sch->qstats.backlog += qdisc_pkt_len(skb); sch->qstats.requeues++; return NET_XMIT_SUCCESS; Loading Loading @@ -401,7 +406,7 @@ static inline unsigned int __qdisc_queue_drop(struct Qdisc *sch, struct sk_buff *skb = __qdisc_dequeue_tail(sch, list); if (likely(skb != NULL)) { unsigned int len = skb->len; unsigned int len = qdisc_pkt_len(skb); kfree_skb(skb); return len; } Loading
net/sched/act_gact.c +1 −1 Original line number Diff line number Diff line Loading @@ -139,7 +139,7 @@ static int tcf_gact(struct sk_buff *skb, struct tc_action *a, struct tcf_result #else action = gact->tcf_action; #endif gact->tcf_bstats.bytes += skb->len; gact->tcf_bstats.bytes += qdisc_pkt_len(skb); gact->tcf_bstats.packets++; if (action == TC_ACT_SHOT) gact->tcf_qstats.drops++; Loading
net/sched/act_ipt.c +1 −1 Original line number Diff line number Diff line Loading @@ -205,7 +205,7 @@ static int tcf_ipt(struct sk_buff *skb, struct tc_action *a, spin_lock(&ipt->tcf_lock); ipt->tcf_tm.lastuse = jiffies; ipt->tcf_bstats.bytes += skb->len; ipt->tcf_bstats.bytes += qdisc_pkt_len(skb); ipt->tcf_bstats.packets++; /* yes, we have to worry about both in and out dev Loading
net/sched/act_mirred.c +2 −2 Original line number Diff line number Diff line Loading @@ -164,7 +164,7 @@ bad_mirred: if (skb2 != NULL) kfree_skb(skb2); m->tcf_qstats.overlimits++; m->tcf_bstats.bytes += skb->len; m->tcf_bstats.bytes += qdisc_pkt_len(skb); m->tcf_bstats.packets++; spin_unlock(&m->tcf_lock); /* should we be asking for packet to be dropped? Loading @@ -184,7 +184,7 @@ bad_mirred: goto bad_mirred; } m->tcf_bstats.bytes += skb2->len; m->tcf_bstats.bytes += qdisc_pkt_len(skb2); m->tcf_bstats.packets++; if (!(at & AT_EGRESS)) if (m->tcfm_ok_push) Loading
net/sched/act_nat.c +1 −1 Original line number Diff line number Diff line Loading @@ -124,7 +124,7 @@ static int tcf_nat(struct sk_buff *skb, struct tc_action *a, egress = p->flags & TCA_NAT_FLAG_EGRESS; action = p->tcf_action; p->tcf_bstats.bytes += skb->len; p->tcf_bstats.bytes += qdisc_pkt_len(skb); p->tcf_bstats.packets++; spin_unlock(&p->tcf_lock); Loading