Skip to contentSkip to conversation

tc pfifo queue length

LARTC john zhou 2 participants 2 messages Jul 18, 2002 – Jul 19, 2002

lore
Share & tools
lore

john zhou

author
#0 lore raw

hi,

when I read following part in sch_fifo.c, in pfifo_enqueue:

static int
105 pfifo_enqueue(struct sk_buff *skb, struct Qdisc* sch) 106 {
107 struct fifo_sched_data *q = (struct fifo_sched_data *)sch->data;
108
109 if (sch->q.qlen <= q->limit) {

110                 __skb_queue_tail(&sch->q, skb);
111                 sch->stats.bytes += skb->len;
112                 sch->stats.packets++;
113                 return 0;

114 }
115 sch->stats.drops++;
116 #ifdef CONFIG_NET_CLS_POLICE
117 if (sch->reshape_fail=NULL || sch->reshape_fail(skb, sch))
118 #endif
119 kfree_skb(skb);
120 return NET_XMIT_DROP;

After enqueue, sch->q.qlen++ should be there, why in above part no this kind of sentence, sch->q.qlen updated in other place???

in bfifo, sch->stats.backlog += skb->len exists.

please give some suggestion, thanks.

John Zhou

_________________________________________________________________
MSN Photos is the easiest way to share and print your photos:
http://photos.msn.com/support/worldwide.aspx

_______________________________________________
LARTC mailing list / [email protected]
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

#1 lore raw
Quoted 2 lines

110 __skb_queue_tail(&sch->q, skb);

Its updated there. grep is your friend :)

Quoted 12 lines

After enqueue, sch->q.qlen++ should be there, why in above part no this kind of sentence, sch->q.qlen updated in other place???

in bfifo, sch->stats.backlog += skb->len exists.

please give some suggestion, thanks.

John Zhou

Quoted 8 lines

_________________________________________________________________
MSN Photos is the easiest way to share and print your photos:
http://photos.msn.com/support/worldwide.aspx

_______________________________________________
LARTC mailing list / [email protected]
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

_______________________________________________
LARTC mailing list / [email protected]
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/