aboutsummaryrefslogtreecommitdiffstats
path: root/net/sched/sch_gred.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/sched/sch_gred.c')
-rw-r--r--net/sched/sch_gred.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/net/sched/sch_gred.c b/net/sched/sch_gred.c
index c89fba56db56..c1ad6b8de105 100644
--- a/net/sched/sch_gred.c
+++ b/net/sched/sch_gred.c
@@ -164,7 +164,7 @@ static int gred_enqueue(struct sk_buff *skb, struct Qdisc* sch)
164 * if no default DP has been configured. This 164 * if no default DP has been configured. This
165 * allows for DP flows to be left untouched. 165 * allows for DP flows to be left untouched.
166 */ 166 */
167 if (skb_queue_len(&sch->q) < sch->dev->tx_queue_len) 167 if (skb_queue_len(&sch->q) < qdisc_dev(sch)->tx_queue_len)
168 return qdisc_enqueue_tail(skb, sch); 168 return qdisc_enqueue_tail(skb, sch);
169 else 169 else
170 goto drop; 170 goto drop;
@@ -188,7 +188,7 @@ static int gred_enqueue(struct sk_buff *skb, struct Qdisc* sch)
188 } 188 }
189 189
190 q->packetsin++; 190 q->packetsin++;
191 q->bytesin += skb->len; 191 q->bytesin += qdisc_pkt_len(skb);
192 192
193 if (gred_wred_mode(t)) 193 if (gred_wred_mode(t))
194 gred_load_wred_set(t, q); 194 gred_load_wred_set(t, q);
@@ -226,8 +226,8 @@ static int gred_enqueue(struct sk_buff *skb, struct Qdisc* sch)
226 break; 226 break;
227 } 227 }
228 228
229 if (q->backlog + skb->len <= q->limit) { 229 if (q->backlog + qdisc_pkt_len(skb) <= q->limit) {
230 q->backlog += skb->len; 230 q->backlog += qdisc_pkt_len(skb);
231 return qdisc_enqueue_tail(skb, sch); 231 return qdisc_enqueue_tail(skb, sch);
232 } 232 }
233 233
@@ -254,7 +254,7 @@ static int gred_requeue(struct sk_buff *skb, struct Qdisc* sch)
254 } else { 254 } else {
255 if (red_is_idling(&q->parms)) 255 if (red_is_idling(&q->parms))
256 red_end_of_idle_period(&q->parms); 256 red_end_of_idle_period(&q->parms);
257 q->backlog += skb->len; 257 q->backlog += qdisc_pkt_len(skb);
258 } 258 }
259 259
260 return qdisc_requeue(skb, sch); 260 return qdisc_requeue(skb, sch);
@@ -277,7 +277,7 @@ static struct sk_buff *gred_dequeue(struct Qdisc* sch)
277 "VQ 0x%x after dequeue, screwing up " 277 "VQ 0x%x after dequeue, screwing up "
278 "backlog.\n", tc_index_to_dp(skb)); 278 "backlog.\n", tc_index_to_dp(skb));
279 } else { 279 } else {
280 q->backlog -= skb->len; 280 q->backlog -= qdisc_pkt_len(skb);
281 281
282 if (!q->backlog && !gred_wred_mode(t)) 282 if (!q->backlog && !gred_wred_mode(t))
283 red_start_of_idle_period(&q->parms); 283 red_start_of_idle_period(&q->parms);
@@ -299,7 +299,7 @@ static unsigned int gred_drop(struct Qdisc* sch)
299 299
300 skb = qdisc_dequeue_tail(sch); 300 skb = qdisc_dequeue_tail(sch);
301 if (skb) { 301 if (skb) {
302 unsigned int len = skb->len; 302 unsigned int len = qdisc_pkt_len(skb);
303 struct gred_sched_data *q; 303 struct gred_sched_data *q;
304 u16 dp = tc_index_to_dp(skb); 304 u16 dp = tc_index_to_dp(skb);
305 305