On Mon, 2004-08-23 at 05:39, sandr8 wrote:
Let me just get to the bottom of your email:
> >A packet that gets enqueued is _guaranteed_ to be transmitted unless
> >overulled by admin policy.
> >Ok, how about the idea of adding skb->unbilled which gets set when
> >unbilling happens (in the aggregated stats_incr()). skb->unbilled gets
> >zeroed at the root qdisc after return from enqueueing.
> sorry?? i'm lost... maybe there's something implied i can't get...
> do you agree it's not the same skb that will be re-billed
Sure, its a cloned packet - from a billing perspective we can look at it
as a different flow. Contrack bills, qdisc unbills.
What i meant is packet still flowing within the qdisc infrastructure.
what i drew as:
..-->classification --> tcaction
return code1 --> enqueue
return code2 ...(packet may be freed here)--> dev.c
Thats the only place i see skb->unbilled as useful.
all components need to increment their won proivate stats and should
call stats_incr() but only the first one gets to unbill;
eg if action calls stats_incr to indicate drop; you unbill. When
qdisc enqueue calls stats_incr with a drop reason, you dont want to
We could talk in more details about code after - just discussing
concepts right now.