]> git.baikalelectronics.ru Git - kernel.git/commit
net: sched: change action API to use array of pointers to actions
authorVlad Buslov <vladbu@mellanox.com>
Thu, 5 Jul 2018 14:24:33 +0000 (17:24 +0300)
committerDavid S. Miller <davem@davemloft.net>
Sun, 8 Jul 2018 03:42:29 +0000 (12:42 +0900)
commiteaf578bf81adfa2a242afbbad102494f4a71ed96
tree50c929a316f5c3049e38fdc42e18a3baad8deaaa
parent514093d812c16d9035c982c299cb1203230624d4
net: sched: change action API to use array of pointers to actions

Act API used linked list to pass set of actions to functions. It is
intrusive data structure that stores list nodes inside action structure
itself, which means it is not safe to modify such list concurrently.
However, action API doesn't use any linked list specific operations on this
set of actions, so it can be safely refactored into plain pointer array.

Refactor action API to use array of pointers to tc_actions instead of
linked list. Change argument 'actions' type of exported action init,
destroy and dump functions.

Acked-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: Vlad Buslov <vladbu@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/net/act_api.h
net/sched/act_api.c
net/sched/cls_api.c