Patent ID: 7660252

Claim:
A method for controlling a packet passing through a network device, the method comprising: timestamping the packet with an arrival time when the packet arrives at a queue in the network device; timestamping the packet with an exit time when the packet exits the queue; determining a queue time that is a length of time the packet has been in the queue; determining a regulating level for labeling packets, wherein the regulating level is based on a weighted average time, wherein the weighted average time is based on the queue time of the packet, an average queue time of a predefined number of packets that previously spent time in the queue, and a weight factor, and wherein the weight factor gives more weight to either the queue time of the packet or to the average queue time; labeling the packet to be dropped if the regulating level is greater than a predefined threshold; and processing the packet in the network device based on the labeling.