Re: [PATCH 06/14] net: sched: implement reference counted action release

2018-05-20 Thread Jiri Pirko
Sat, May 19, 2018 at 11:43:27PM CEST, marcelo.leit...@gmail.com wrote: >On Mon, May 14, 2018 at 05:27:07PM +0300, Vlad Buslov wrote: >... >> @@ -1052,6 +1088,36 @@ static int tca_action_flush(struct net *net, struct >> nlattr *nla, >> return err; >> } >> >> +static int

Re: [PATCH 12/14] net: sched: retry action check-insert on concurrent modification

2018-05-16 Thread Jiri Pirko
Wed, May 16, 2018 at 04:26:40PM CEST, vla...@mellanox.com wrote: > >On Wed 16 May 2018 at 14:13, Jiri Pirko <j...@resnulli.us> wrote: >> Wed, May 16, 2018 at 03:52:20PM CEST, vla...@mellanox.com wrote: >>> >>>On Wed 16 May 2018 at 13:21, Jiri Pirko <j...@res

Re: [PATCH 12/14] net: sched: retry action check-insert on concurrent modification

2018-05-16 Thread Jiri Pirko
Wed, May 16, 2018 at 03:52:20PM CEST, vla...@mellanox.com wrote: > >On Wed 16 May 2018 at 13:21, Jiri Pirko <j...@resnulli.us> wrote: >> Wed, May 16, 2018 at 02:43:58PM CEST, vla...@mellanox.com wrote: >>> >>>On Wed 16 May 2018 at 12:26, Jiri Pirko <j...@res

Re: [PATCH 12/14] net: sched: retry action check-insert on concurrent modification

2018-05-16 Thread Jiri Pirko
Wed, May 16, 2018 at 02:43:58PM CEST, vla...@mellanox.com wrote: > >On Wed 16 May 2018 at 12:26, Jiri Pirko <j...@resnulli.us> wrote: >> Wed, May 16, 2018 at 01:55:06PM CEST, vla...@mellanox.com wrote: >>> >>>On Wed 16 May 2018 at 09:59, Jiri Pirko <j...@res

Re: [PATCH 12/14] net: sched: retry action check-insert on concurrent modification

2018-05-16 Thread Jiri Pirko
Wed, May 16, 2018 at 01:55:06PM CEST, vla...@mellanox.com wrote: > >On Wed 16 May 2018 at 09:59, Jiri Pirko <j...@resnulli.us> wrote: >> Mon, May 14, 2018 at 04:27:13PM CEST, vla...@mellanox.com wrote: >>>Retry check-insert sequence in action init functions i

Re: [PATCH 12/14] net: sched: retry action check-insert on concurrent modification

2018-05-16 Thread Jiri Pirko
Mon, May 14, 2018 at 04:27:13PM CEST, vla...@mellanox.com wrote: >Retry check-insert sequence in action init functions if action with same >index was inserted concurrently. > >Signed-off-by: Vlad Buslov >--- > net/sched/act_bpf.c| 8 +++- > net/sched/act_connmark.c

Re: [PATCH 11/14] net: core: add new/replace rate estimator lock parameter

2018-05-16 Thread Jiri Pirko
Mon, May 14, 2018 at 04:27:12PM CEST, vla...@mellanox.com wrote: >Extend rate estimator new and replace APIs with additional spinlock >parameter used by lockless actions to protect rate_est pointer from >concurrent modification. > >Signed-off-by: Vlad Buslov [...] > /** >

Re: [PATCH 13/14] net: sched: use unique idr insert function in unlocked actions

2018-05-16 Thread Jiri Pirko
Mon, May 14, 2018 at 04:27:14PM CEST, vla...@mellanox.com wrote: >Substitute calls to action insert function with calls to action insert >unique function that warns if insertion overwrites index in idr. > >Signed-off-by: Vlad Buslov >--- > net/sched/act_bpf.c| 2 +- >

Re: [PATCH 14/14] net: sched: implement delete for all actions

2018-05-16 Thread Jiri Pirko
Mon, May 14, 2018 at 04:27:15PM CEST, vla...@mellanox.com wrote: >Implement delete function that is required to delete actions without >holding rtnl lock. Use action API function that atomically deletes action >only if it is still in action idr. This implementation prevents concurrent >threads

Re: [PATCH 10/14] net: sched: extend act API for lockless actions

2018-05-16 Thread Jiri Pirko
Wed, May 16, 2018 at 10:16:13AM CEST, vla...@mellanox.com wrote: > >On Wed 16 May 2018 at 07:50, Jiri Pirko <j...@resnulli.us> wrote: >> Mon, May 14, 2018 at 04:27:11PM CEST, vla...@mellanox.com wrote: >>>Implement new action API function to atomically delete act

Re: [PATCH 10/14] net: sched: extend act API for lockless actions

2018-05-16 Thread Jiri Pirko
Mon, May 14, 2018 at 04:27:11PM CEST, vla...@mellanox.com wrote: >Implement new action API function to atomically delete action with >specified index and to atomically insert unique action. These functions are >required to implement init and delete functions for specific actions that >do not rely

Re: [PATCH 09/14] net: sched: don't release reference on action overwrite

2018-05-16 Thread Jiri Pirko
Wed, May 16, 2018 at 09:47:32AM CEST, vla...@mellanox.com wrote: > >On Wed 16 May 2018 at 07:43, Jiri Pirko <j...@resnulli.us> wrote: >> Mon, May 14, 2018 at 04:27:10PM CEST, vla...@mellanox.com wrote: >>>Return from action init function with reference to action take

Re: [PATCH 09/14] net: sched: don't release reference on action overwrite

2018-05-16 Thread Jiri Pirko
Mon, May 14, 2018 at 04:27:10PM CEST, vla...@mellanox.com wrote: >Return from action init function with reference to action taken, >even when overwriting existing action. > >Action init API initializes its fourth argument (pointer to pointer to >tc action) to either existing action with same index

Re: [PATCH 07/14] net: sched: use reference counting action init

2018-05-15 Thread Jiri Pirko
Tue, May 15, 2018 at 01:41:45PM CEST, vla...@mellanox.com wrote: > >On Tue 15 May 2018 at 11:39, Jiri Pirko <j...@resnulli.us> wrote: >> Tue, May 15, 2018 at 01:32:51PM CEST, vla...@mellanox.com wrote: >>> >>>On Tue 15 May 2018 at 11:24, Jiri Pirko <j...@res

Re: [PATCH 07/14] net: sched: use reference counting action init

2018-05-15 Thread Jiri Pirko
Tue, May 15, 2018 at 01:32:51PM CEST, vla...@mellanox.com wrote: > >On Tue 15 May 2018 at 11:24, Jiri Pirko <j...@resnulli.us> wrote: >> Mon, May 14, 2018 at 04:27:08PM CEST, vla...@mellanox.com wrote: >>>Change action API to assume that action init function always t

Re: [PATCH 07/14] net: sched: use reference counting action init

2018-05-15 Thread Jiri Pirko
Mon, May 14, 2018 at 04:27:08PM CEST, vla...@mellanox.com wrote: >Change action API to assume that action init function always takes >reference to action, even when overwriting existing action. This is >necessary because action API continues to use action pointer after init >function is done. At

Re: [PATCH 06/14] net: sched: implement reference counted action release

2018-05-15 Thread Jiri Pirko
Mon, May 14, 2018 at 09:07:06PM CEST, vla...@mellanox.com wrote: > >On Mon 14 May 2018 at 16:47, Jiri Pirko <j...@resnulli.us> wrote: >> Mon, May 14, 2018 at 04:27:07PM CEST, vla...@mellanox.com wrote: >> >> [...] >> >> >>>+static int tcf_

Re: [PATCH 05/14] net: sched: always take reference to action

2018-05-15 Thread Jiri Pirko
Mon, May 14, 2018 at 08:49:07PM CEST, vla...@mellanox.com wrote: > >On Mon 14 May 2018 at 16:23, Jiri Pirko <j...@resnulli.us> wrote: >> Mon, May 14, 2018 at 04:27:06PM CEST, vla...@mellanox.com wrote: >>>Without rtnl lock protection it is no longer safe to use poin

Re: [PATCH 00/14] Modify action API for implementing lockless actions

2018-05-15 Thread Jiri Pirko
Mon, May 14, 2018 at 08:03:20PM CEST, j...@mojatatu.com wrote: >On 14/05/18 10:27 AM, Vlad Buslov wrote: >> Currently, all netlink protocol handlers for updating rules, actions and >> qdiscs are protected with single global rtnl lock which removes any >> possibility for parallelism. This patch set

Re: [PATCH 06/14] net: sched: implement reference counted action release

2018-05-14 Thread Jiri Pirko
Mon, May 14, 2018 at 04:27:07PM CEST, vla...@mellanox.com wrote: [...] >+static int tcf_action_del_1(struct net *net, char *kind, u32 index, >+ struct netlink_ext_ack *extack) >+{ >+ const struct tc_action_ops *ops; >+ int err = -EINVAL; >+ >+ ops =

Re: [PATCH 03/14] net: sched: add 'delete' function to action ops

2018-05-14 Thread Jiri Pirko
Mon, May 14, 2018 at 05:12:22PM CEST, j...@resnulli.us wrote: >Mon, May 14, 2018 at 04:27:04PM CEST, vla...@mellanox.com wrote: >>Extend action ops with 'delete' function. Each action type to implement its >>own delete function that doesn't depend on rtnl lock. >> >>Signed-off-by: Vlad Buslov

Re: [PATCH 06/14] net: sched: implement reference counted action release

2018-05-14 Thread Jiri Pirko
Mon, May 14, 2018 at 04:27:07PM CEST, vla...@mellanox.com wrote: >Implement helper function to delete action using new action ops delete >function implemented by each action for lockless execution. Reading this sentense for 4 times. I still don't understand what you say :( > >Implement action

Re: [PATCH 05/14] net: sched: always take reference to action

2018-05-14 Thread Jiri Pirko
Mon, May 14, 2018 at 04:27:06PM CEST, vla...@mellanox.com wrote: >Without rtnl lock protection it is no longer safe to use pointer to tc >action without holding reference to it. (it can be destroyed concurrently) > >Remove unsafe action idr lookup function. Instead of it, implement safe tcf >idr

Re: [PATCH 04/14] net: sched: implement unlocked action init API

2018-05-14 Thread Jiri Pirko
Mon, May 14, 2018 at 04:27:05PM CEST, vla...@mellanox.com wrote: >Add additional 'unlocked' argument to act API init functions. >Argument is true when rtnl lock is not taken and false otherwise. >It is required to implement actions that need to release rtnl lock before >loading kernel module and

Re: [PATCH 03/14] net: sched: add 'delete' function to action ops

2018-05-14 Thread Jiri Pirko
Mon, May 14, 2018 at 04:27:04PM CEST, vla...@mellanox.com wrote: >Extend action ops with 'delete' function. Each action type to implement its >own delete function that doesn't depend on rtnl lock. > >Signed-off-by: Vlad Buslov >--- > include/net/act_api.h | 1 + > 1 file

Re: [PATCH 02/14] net: sched: change type of reference and bind counters

2018-05-14 Thread Jiri Pirko
-by: Vlad Buslov <vla...@mellanox.com> Signed-off-by: Jiri Pirko <j...@mellanox.com> -- To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH 01/14] net: sched: use rcu for action cookie update

2018-05-14 Thread Jiri Pirko
Mon, May 14, 2018 at 04:27:02PM CEST, vla...@mellanox.com wrote: >Implement functions to atomically update and free action cookie >using rcu mechanism. > >Signed-off-by: Vlad Buslov <vla...@mellanox.com> Signed-off-by: Jiri Pirko <j...@mellanox.com> -- To unsubscribe from

Re: net-next STATUS page

2017-07-11 Thread Jiri Pirko
Tue, Jul 11, 2017 at 04:24:16PM CEST, da...@davemloft.net wrote: > >It has gotten to the point that even casually walking around >Faro, Portugal last week, random German tourists would stop >me in the street and ask if net-next was open or not. > >Therefore, in order to avoid any and all confusion