ret = netem_delay(sch, skb); netem_run(sch); 
PSCHED_GET_TIME(cb->time_to_send); ret = q->qdisc->ops->requeue(skb, q->qdisc); 
static int netem_enqueue(struct sk_buff *skb, struct Qdisc *sch){	struct netem_sched_data *q = qdisc_priv(sch);	struct sk_buff *skb2;	int ret;	int count = 1;	pr_debug("netem_enqueue skb=%p\n", skb);	/* Random duplication */	if (q->duplicate && q->duplicate >= get_crandom(&q->dup_cor))		++count;	/* Random packet drop 0 => none, ~0 => all */	if (q->loss && q->loss >= get_crandom(&q->loss_cor))		--count;	if (count == 0) {		sch->qstats.drops++;		kfree_skb(skb);		return NET_XMIT_DROP;	}	/*	 * If we need to duplicate packet, then re-insert at top of the	 * qdisc tree, since parent queuer expects that only one	 * skb will be queued.	 */	if (count > 1 && (skb2 = skb_clone(skb, GFP_ATOMIC)) != NULL) {		struct Qdisc *rootq = sch->dev->qdisc;		u32 dupsave = q->duplicate; /* prevent duplicating a dup... */		q->duplicate = 0;		rootq->enqueue(skb2, rootq);		q->duplicate = dupsave;	}	/* If doing simple delay then gap == 0 so all packets	 * go into the delayed holding queue	 * otherwise if doing out of order only "1 out of gap"	 * packets will be delayed.	 */	if (q->counter < q->gap) {		++q->counter;		ret = q->qdisc->enqueue(skb, q->qdisc);	} else {		q->counter = 0;		ret = netem_delay(sch, skb);		netem_run(sch);	}	if (likely(ret == NET_XMIT_SUCCESS)) {		sch->q.qlen++;		sch->bstats.bytes += skb->len;		sch->bstats.packets++;	} else		sch->qstats.drops++;	pr_debug("netem: enqueue ret %d\n", ret);	return ret;}
10457	/local/tlutelli/issta_data/temp/c/2005_temp/2005/10457/0f9f32ac65ee4a452a912a8440cebbc4dff73852/sch_netem.c/clean/net/sched/sch_netem.c