On Thu, May 18, 2017 at 9:24 AM, Sabrina Dubroca <s...@queasysnail.net> wrote: > This also changes tcf_chain_get() to return an error pointer instead of > NULL, so that tcf_action_goto_chain_init() can differentiate memory > allocation failure from lack of support. > > Fixes: 5bc1701881e3 ("net: sched: introduce multichain support for filters") > Signed-off-by: Sabrina Dubroca <s...@queasysnail.net> > --- > I'm not sure this EOPNOTSUPP is really necessary, ie if we can really > reach the tcf_action_goto_chain_init() call when CONFIG_NET_CLS=n. > If not, a simpler patch would add a tcf_chain_get() stub that just > returns NULL, as we wouldn't have to care about returning an incorrect > error code from tcf_action_goto_chain_init().
I wonder if we should just make CONFIG_NET_CLS_ACT depending on CONFIG_NET_CLS. Although without filters we can still have standalone actions but no one can use them.