Commit 645a1e39e4e3e84a275c5e4a7c8049041146f9b5
Committed by
David S. Miller
1 parent
c6ee877f2e
[NET_SCHED]: sch_ingress: move dependencies to Kconfig
Instead of complaining at scheduler initialization time, check the dependencies in Kconfig. Signed-off-by: Patrick McHardy <kaber@trash.net> Acked-by: Jamal Hadi Salim <hadi@cyberus.ca> Signed-off-by: David S. Miller <davem@davemloft.net>
Showing 2 changed files with 2 additions and 10 deletions Side-by-side Diff
net/sched/Kconfig
net/sched/sch_ingress.c
... | ... | @@ -162,19 +162,10 @@ |
162 | 162 | |
163 | 163 | static int ingress_init(struct Qdisc *sch, struct rtattr *opt) |
164 | 164 | { |
165 | - /* Make sure either netfilter or preferably CLS_ACT is | |
166 | - * compiled in */ | |
167 | 165 | #ifndef CONFIG_NET_CLS_ACT |
168 | -#ifndef CONFIG_NETFILTER | |
169 | - printk("You MUST compile classifier actions into the kernel\n"); | |
170 | - return -EINVAL; | |
171 | -#else | |
166 | +#ifdef CONFIG_NETFILTER | |
172 | 167 | printk("Ingress scheduler: Classifier actions prefered over netfilter\n"); |
173 | -#endif | |
174 | -#endif | |
175 | 168 | |
176 | -#ifndef CONFIG_NET_CLS_ACT | |
177 | -#ifdef CONFIG_NETFILTER | |
178 | 169 | if (!nf_registered) { |
179 | 170 | if (nf_register_hooks(ing_ops, ARRAY_SIZE(ing_ops)) < 0) { |
180 | 171 | printk("ingress qdisc registration error \n"); |