Commit a913f889 authored by David S. Miller's avatar David S. Miller

Ingress packet scheduler: Fix compiler error when CONFIG_NET_CLS_POLICE is disabled.

parent 16b7bbb0
...@@ -146,8 +146,8 @@ static int ingress_enqueue(struct sk_buff *skb,struct Qdisc *sch) ...@@ -146,8 +146,8 @@ static int ingress_enqueue(struct sk_buff *skb,struct Qdisc *sch)
* Unlike normal "enqueue" functions, ingress_enqueue returns a * Unlike normal "enqueue" functions, ingress_enqueue returns a
* firewall FW_* code. * firewall FW_* code.
*/ */
switch (result) {
#ifdef CONFIG_NET_CLS_POLICE #ifdef CONFIG_NET_CLS_POLICE
switch (result) {
case TC_POLICE_SHOT: case TC_POLICE_SHOT:
result = NF_DROP; result = NF_DROP;
sch->stats.drops++; sch->stats.drops++;
...@@ -160,7 +160,7 @@ static int ingress_enqueue(struct sk_buff *skb,struct Qdisc *sch) ...@@ -160,7 +160,7 @@ static int ingress_enqueue(struct sk_buff *skb,struct Qdisc *sch)
sch->stats.bytes += skb->len; sch->stats.bytes += skb->len;
result = NF_ACCEPT; result = NF_ACCEPT;
break; break;
} };
#else #else
sch->stats.packets++; sch->stats.packets++;
sch->stats.bytes += skb->len; sch->stats.bytes += skb->len;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment