Re: [PATCH net-next V2 03/10] net/sched: Macro instead of CONFIG_NET_CLS_ACT ifdef

2016-03-06 Thread Amir Vadai
On Fri, Mar 04, 2016 at 10:20:18AM -0800, Cong Wang wrote: > On Thu, Mar 3, 2016 at 11:51 AM, Amir Vadai wrote: > > On Thu, Mar 03, 2016 at 09:45:28AM -0800, Cong Wang wrote: > >> > >> So why? > > The struct will not be used, and without exposing it, the compiler will > > complain on code like I h

Re: [PATCH net-next V2 03/10] net/sched: Macro instead of CONFIG_NET_CLS_ACT ifdef

2016-03-04 Thread Cong Wang
On Thu, Mar 3, 2016 at 11:51 AM, Amir Vadai wrote: > On Thu, Mar 03, 2016 at 09:45:28AM -0800, Cong Wang wrote: >> >> So why? > The struct will not be used, and without exposing it, the compiler will > complain on code like I have in patch 9/10 ("net/mlx5e: Support offload > cls_flower with drop a

Re: [PATCH net-next V2 03/10] net/sched: Macro instead of CONFIG_NET_CLS_ACT ifdef

2016-03-04 Thread John Fastabend
On 16-03-03 06:55 AM, Amir Vadai wrote: > Introduce the macros tc_no_actions and tc_for_each_action to make code > clearer. > > Suggested-by: Jiri Pirko > Signed-off-by: Amir Vadai > --- Acked-by: John Fastabend This should clean up the driver implementation a bit thanks.

Re: [PATCH net-next V2 03/10] net/sched: Macro instead of CONFIG_NET_CLS_ACT ifdef

2016-03-03 Thread Amir Vadai
On Thu, Mar 03, 2016 at 09:45:28AM -0800, Cong Wang wrote: > On Thu, Mar 3, 2016 at 6:55 AM, Amir Vadai wrote: > > Introduce the macros tc_no_actions and tc_for_each_action to make code > > clearer. > > > > Suggested-by: Jiri Pirko > > Signed-off-by: Amir Vadai > > --- > > include/net/act_api.h

Re: [PATCH net-next V2 03/10] net/sched: Macro instead of CONFIG_NET_CLS_ACT ifdef

2016-03-03 Thread Cong Wang
On Thu, Mar 3, 2016 at 6:55 AM, Amir Vadai wrote: > Introduce the macros tc_no_actions and tc_for_each_action to make code > clearer. > > Suggested-by: Jiri Pirko > Signed-off-by: Amir Vadai > --- > include/net/act_api.h| 21 - > include/net/tc_act/tc_gact.h | 4 ++-

Re: [PATCH net-next V2 03/10] net/sched: Macro instead of CONFIG_NET_CLS_ACT ifdef

2016-03-03 Thread Jiri Pirko
Thu, Mar 03, 2016 at 03:55:53PM CET, a...@vadai.me wrote: >Introduce the macros tc_no_actions and tc_for_each_action to make code >clearer. > >Suggested-by: Jiri Pirko >Signed-off-by: Amir Vadai Acked-by: Jiri Pirko

[PATCH net-next V2 03/10] net/sched: Macro instead of CONFIG_NET_CLS_ACT ifdef

2016-03-03 Thread Amir Vadai
Introduce the macros tc_no_actions and tc_for_each_action to make code clearer. Suggested-by: Jiri Pirko Signed-off-by: Amir Vadai --- include/net/act_api.h| 21 - include/net/tc_act/tc_gact.h | 4 ++-- 2 files changed, 18 insertions(+), 7 deletions(-) diff --git a