diff options
Diffstat (limited to 'net/sched')
| -rw-r--r-- | net/sched/em_meta.c | 46 | ||||
| -rw-r--r-- | net/sched/em_text.c | 3 | ||||
| -rw-r--r-- | net/sched/sch_generic.c | 7 |
3 files changed, 6 insertions, 50 deletions
diff --git a/net/sched/em_meta.c b/net/sched/em_meta.c index 53d98f8d3d80..a18b924743d9 100644 --- a/net/sched/em_meta.c +++ b/net/sched/em_meta.c | |||
| @@ -27,17 +27,17 @@ | |||
| 27 | * lvalue rvalue | 27 | * lvalue rvalue |
| 28 | * +-----------+ +-----------+ | 28 | * +-----------+ +-----------+ |
| 29 | * | type: INT | | type: INT | | 29 | * | type: INT | | type: INT | |
| 30 | * def | id: INDEV | | id: VALUE | | 30 | * def | id: DEV | | id: VALUE | |
| 31 | * | data: | | data: 3 | | 31 | * | data: | | data: 3 | |
| 32 | * +-----------+ +-----------+ | 32 | * +-----------+ +-----------+ |
| 33 | * | | | 33 | * | | |
| 34 | * ---> meta_ops[INT][INDEV](...) | | 34 | * ---> meta_ops[INT][DEV](...) | |
| 35 | * | | | 35 | * | | |
| 36 | * ----------- | | 36 | * ----------- | |
| 37 | * V V | 37 | * V V |
| 38 | * +-----------+ +-----------+ | 38 | * +-----------+ +-----------+ |
| 39 | * | type: INT | | type: INT | | 39 | * | type: INT | | type: INT | |
| 40 | * obj | id: INDEV | | id: VALUE | | 40 | * obj | id: DEV | | id: VALUE | |
| 41 | * | data: 2 |<--data got filled out | data: 3 | | 41 | * | data: 2 |<--data got filled out | data: 3 | |
| 42 | * +-----------+ +-----------+ | 42 | * +-----------+ +-----------+ |
| 43 | * | | | 43 | * | | |
| @@ -170,26 +170,6 @@ META_COLLECTOR(var_dev) | |||
| 170 | *err = var_dev(skb->dev, dst); | 170 | *err = var_dev(skb->dev, dst); |
| 171 | } | 171 | } |
| 172 | 172 | ||
| 173 | META_COLLECTOR(int_indev) | ||
| 174 | { | ||
| 175 | *err = int_dev(skb->input_dev, dst); | ||
| 176 | } | ||
| 177 | |||
| 178 | META_COLLECTOR(var_indev) | ||
| 179 | { | ||
| 180 | *err = var_dev(skb->input_dev, dst); | ||
| 181 | } | ||
| 182 | |||
| 183 | META_COLLECTOR(int_realdev) | ||
| 184 | { | ||
| 185 | *err = int_dev(skb->real_dev, dst); | ||
| 186 | } | ||
| 187 | |||
| 188 | META_COLLECTOR(var_realdev) | ||
| 189 | { | ||
| 190 | *err = var_dev(skb->real_dev, dst); | ||
| 191 | } | ||
| 192 | |||
| 193 | /************************************************************************** | 173 | /************************************************************************** |
| 194 | * skb attributes | 174 | * skb attributes |
| 195 | **************************************************************************/ | 175 | **************************************************************************/ |
| @@ -245,18 +225,6 @@ META_COLLECTOR(int_tcindex) | |||
| 245 | dst->value = skb->tc_index; | 225 | dst->value = skb->tc_index; |
| 246 | } | 226 | } |
| 247 | 227 | ||
| 248 | #ifdef CONFIG_NET_CLS_ACT | ||
| 249 | META_COLLECTOR(int_tcverd) | ||
| 250 | { | ||
| 251 | dst->value = skb->tc_verd; | ||
| 252 | } | ||
| 253 | |||
| 254 | META_COLLECTOR(int_tcclassid) | ||
| 255 | { | ||
| 256 | dst->value = skb->tc_classid; | ||
| 257 | } | ||
| 258 | #endif | ||
| 259 | |||
| 260 | /************************************************************************** | 228 | /************************************************************************** |
| 261 | * Routing | 229 | * Routing |
| 262 | **************************************************************************/ | 230 | **************************************************************************/ |
| @@ -505,8 +473,6 @@ struct meta_ops | |||
| 505 | static struct meta_ops __meta_ops[TCF_META_TYPE_MAX+1][TCF_META_ID_MAX+1] = { | 473 | static struct meta_ops __meta_ops[TCF_META_TYPE_MAX+1][TCF_META_ID_MAX+1] = { |
| 506 | [TCF_META_TYPE_VAR] = { | 474 | [TCF_META_TYPE_VAR] = { |
| 507 | [META_ID(DEV)] = META_FUNC(var_dev), | 475 | [META_ID(DEV)] = META_FUNC(var_dev), |
| 508 | [META_ID(INDEV)] = META_FUNC(var_indev), | ||
| 509 | [META_ID(REALDEV)] = META_FUNC(var_realdev), | ||
| 510 | [META_ID(SK_BOUND_IF)] = META_FUNC(var_sk_bound_if), | 476 | [META_ID(SK_BOUND_IF)] = META_FUNC(var_sk_bound_if), |
| 511 | }, | 477 | }, |
| 512 | [TCF_META_TYPE_INT] = { | 478 | [TCF_META_TYPE_INT] = { |
| @@ -515,8 +481,6 @@ static struct meta_ops __meta_ops[TCF_META_TYPE_MAX+1][TCF_META_ID_MAX+1] = { | |||
| 515 | [META_ID(LOADAVG_1)] = META_FUNC(int_loadavg_1), | 481 | [META_ID(LOADAVG_1)] = META_FUNC(int_loadavg_1), |
| 516 | [META_ID(LOADAVG_2)] = META_FUNC(int_loadavg_2), | 482 | [META_ID(LOADAVG_2)] = META_FUNC(int_loadavg_2), |
| 517 | [META_ID(DEV)] = META_FUNC(int_dev), | 483 | [META_ID(DEV)] = META_FUNC(int_dev), |
| 518 | [META_ID(INDEV)] = META_FUNC(int_indev), | ||
| 519 | [META_ID(REALDEV)] = META_FUNC(int_realdev), | ||
| 520 | [META_ID(PRIORITY)] = META_FUNC(int_priority), | 484 | [META_ID(PRIORITY)] = META_FUNC(int_priority), |
| 521 | [META_ID(PROTOCOL)] = META_FUNC(int_protocol), | 485 | [META_ID(PROTOCOL)] = META_FUNC(int_protocol), |
| 522 | [META_ID(PKTTYPE)] = META_FUNC(int_pkttype), | 486 | [META_ID(PKTTYPE)] = META_FUNC(int_pkttype), |
| @@ -527,10 +491,6 @@ static struct meta_ops __meta_ops[TCF_META_TYPE_MAX+1][TCF_META_ID_MAX+1] = { | |||
| 527 | [META_ID(NFMARK)] = META_FUNC(int_nfmark), | 491 | [META_ID(NFMARK)] = META_FUNC(int_nfmark), |
| 528 | #endif | 492 | #endif |
| 529 | [META_ID(TCINDEX)] = META_FUNC(int_tcindex), | 493 | [META_ID(TCINDEX)] = META_FUNC(int_tcindex), |
| 530 | #ifdef CONFIG_NET_CLS_ACT | ||
| 531 | [META_ID(TCVERDICT)] = META_FUNC(int_tcverd), | ||
| 532 | [META_ID(TCCLASSID)] = META_FUNC(int_tcclassid), | ||
| 533 | #endif | ||
| 534 | #ifdef CONFIG_NET_CLS_ROUTE | 494 | #ifdef CONFIG_NET_CLS_ROUTE |
| 535 | [META_ID(RTCLASSID)] = META_FUNC(int_rtclassid), | 495 | [META_ID(RTCLASSID)] = META_FUNC(int_rtclassid), |
| 536 | #endif | 496 | #endif |
diff --git a/net/sched/em_text.c b/net/sched/em_text.c index 873840d8d072..77beabc91fa3 100644 --- a/net/sched/em_text.c +++ b/net/sched/em_text.c | |||
| @@ -55,9 +55,6 @@ static int em_text_change(struct tcf_proto *tp, void *data, int len, | |||
| 55 | struct ts_config *ts_conf; | 55 | struct ts_config *ts_conf; |
| 56 | int flags = 0; | 56 | int flags = 0; |
| 57 | 57 | ||
| 58 | printk("Configuring text: %s from %d:%d to %d:%d len %d\n", conf->algo, conf->from_offset, | ||
| 59 | conf->from_layer, conf->to_offset, conf->to_layer, conf->pattern_len); | ||
| 60 | |||
| 61 | if (len < sizeof(*conf) || len < (sizeof(*conf) + conf->pattern_len)) | 58 | if (len < sizeof(*conf) || len < (sizeof(*conf) + conf->pattern_len)) |
| 62 | return -EINVAL; | 59 | return -EINVAL; |
| 63 | 60 | ||
diff --git a/net/sched/sch_generic.c b/net/sched/sch_generic.c index 73e218e646ac..8edefd5d095d 100644 --- a/net/sched/sch_generic.c +++ b/net/sched/sch_generic.c | |||
| @@ -331,11 +331,10 @@ static struct sk_buff *pfifo_fast_dequeue(struct Qdisc* qdisc) | |||
| 331 | int prio; | 331 | int prio; |
| 332 | struct sk_buff_head *list = qdisc_priv(qdisc); | 332 | struct sk_buff_head *list = qdisc_priv(qdisc); |
| 333 | 333 | ||
| 334 | for (prio = 0; prio < PFIFO_FAST_BANDS; prio++, list++) { | 334 | for (prio = 0; prio < PFIFO_FAST_BANDS; prio++) { |
| 335 | struct sk_buff *skb = __qdisc_dequeue_head(qdisc, list); | 335 | if (!skb_queue_empty(list + prio)) { |
| 336 | if (skb) { | ||
| 337 | qdisc->q.qlen--; | 336 | qdisc->q.qlen--; |
| 338 | return skb; | 337 | return __qdisc_dequeue_head(qdisc, list + prio); |
| 339 | } | 338 | } |
| 340 | } | 339 | } |
| 341 | 340 | ||
