X-Git-Url: http://ftp.safe.ca/?a=blobdiff_plain;f=net%2Fsched%2Fsch_atm.c;h=417ec8fb7f1a6373f7184cabf2a4c50b0ab85ce4;hb=9ee476a56c3ee119a02b6823659f5698b1241f04;hp=9b458c403fa02d6adb722bea6f23b0d3995715c0;hpb=b0188d4dbe5f4285372dd033acf7c92a97006629;p=safe%2Fjmp%2Flinux-2.6 diff --git a/net/sched/sch_atm.c b/net/sched/sch_atm.c index 9b458c4..417ec8f 100644 --- a/net/sched/sch_atm.c +++ b/net/sched/sch_atm.c @@ -396,8 +396,9 @@ static int atm_tc_enqueue(struct sk_buff *skb, struct Qdisc *sch) !(flow = (struct atm_flow_data *)atm_tc_get(sch, skb->priority))) for (flow = p->flows; flow; flow = flow->next) if (flow->filter_list) { - result = tc_classify(skb, flow->filter_list, - &res); + result = tc_classify_compat(skb, + flow->filter_list, + &res); if (result < 0) continue; flow = (struct atm_flow_data *)res.class; @@ -411,31 +412,27 @@ static int atm_tc_enqueue(struct sk_buff *skb, struct Qdisc *sch) if (flow->vcc) ATM_SKB(skb)->atm_options = flow->vcc->atm_options; /*@@@ looks good ... but it's not supposed to work :-) */ -#ifdef CONFIG_NET_CLS_POLICE +#ifdef CONFIG_NET_CLS_ACT switch (result) { - case TC_POLICE_SHOT: + case TC_ACT_QUEUED: + case TC_ACT_STOLEN: kfree_skb(skb); - break; + return NET_XMIT_SUCCESS; + case TC_ACT_SHOT: + kfree_skb(skb); + goto drop; case TC_POLICE_RECLASSIFY: if (flow->excess) flow = flow->excess; - else { + else ATM_SKB(skb)->atm_options |= ATM_ATMOPT_CLP; - break; - } - /* fall through */ - case TC_POLICE_OK: - /* fall through */ - default: break; } #endif } - if ( -#ifdef CONFIG_NET_CLS_POLICE - result == TC_POLICE_SHOT || -#endif - (ret = flow->q->enqueue(skb, flow->q)) != 0) { + + if ((ret = flow->q->enqueue(skb, flow->q)) != 0) { +drop: __maybe_unused sch->qstats.drops++; if (flow) flow->qstats.drops++;