Re: [PATCH net-next 2/8] net: sched: cls_api: handle generic cls errors

2018-01-17 Thread Jamal Hadi Salim
On 18-01-16 10:22 PM, David Ahern wrote: tp = tcf_chain_tp_find(chain, _info, protocol, prio, prio_allocate); if (IS_ERR(tp)) { err = PTR_ERR(tp); goto errout; } > if (tp == NULL) {

Re: [PATCH net-next 2/8] net: sched: cls_api: handle generic cls errors

2018-01-16 Thread David Ahern
On 1/16/18 4:19 PM, Jamal Hadi Salim wrote: > On 18-01-16 06:58 PM, David Ahern wrote: >> On 1/16/18 9:20 AM, Alexander Aring wrote: > > >>>   } >>>     if (n->nlmsg_type != RTM_NEWTFILTER || >>>   !(n->nlmsg_flags & NLM_F_CREATE)) { >>> +   

Re: [PATCH net-next 2/8] net: sched: cls_api: handle generic cls errors

2018-01-16 Thread Jamal Hadi Salim
On 18-01-16 06:58 PM, David Ahern wrote: On 1/16/18 9:20 AM, Alexander Aring wrote: } if (n->nlmsg_type != RTM_NEWTFILTER || !(n->nlmsg_flags & NLM_F_CREATE)) { + NL_SET_ERR_MSG(extack, "Need both RTM_NEWTFILTER and

Re: [PATCH net-next 2/8] net: sched: cls_api: handle generic cls errors

2018-01-16 Thread David Ahern
On 1/16/18 9:20 AM, Alexander Aring wrote: > This patch adds extack support for generic cls handling. The extack > will be set deeper to each called function which is not part of netdev > core api. > > Cc: David Ahern > Signed-off-by: Alexander Aring > ---

Re: [PATCH net-next 2/8] net: sched: cls_api: handle generic cls errors

2018-01-16 Thread Cong Wang
On Tue, Jan 16, 2018 at 9:20 AM, Alexander Aring wrote: > @@ -1117,8 +1146,10 @@ int tcf_exts_validate(struct net *net, struct > tcf_proto *tp, struct nlattr **tb, > } > #else > if ((exts->action && tb[exts->action]) || > - (exts->police &&

[PATCH net-next 2/8] net: sched: cls_api: handle generic cls errors

2018-01-16 Thread Alexander Aring
This patch adds extack support for generic cls handling. The extack will be set deeper to each called function which is not part of netdev core api. Cc: David Ahern Signed-off-by: Alexander Aring --- net/sched/cls_api.c | 55