<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/include/net/act_api.h, branch v4.19</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v4.19</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v4.19'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2018-08-21T19:45:45Z</updated>
<entry>
<title>net_sched: remove unused tcfa_capab</title>
<updated>2018-08-21T19:45:45Z</updated>
<author>
<name>Cong Wang</name>
<email>xiyou.wangcong@gmail.com</email>
</author>
<published>2018-08-19T19:22:10Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=a0c2e90fe131d9a7440ac05c9c31fc35dfac2fa8'/>
<id>urn:sha1:a0c2e90fe131d9a7440ac05c9c31fc35dfac2fa8</id>
<content type='text'>
Cc: Jamal Hadi Salim &lt;jhs@mojatatu.com&gt;
Signed-off-by: Cong Wang &lt;xiyou.wangcong@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net_sched: remove list_head from tc_action</title>
<updated>2018-08-21T19:45:44Z</updated>
<author>
<name>Cong Wang</name>
<email>xiyou.wangcong@gmail.com</email>
</author>
<published>2018-08-19T19:22:09Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=244cd96adb5f5ab39551081fb1f9009a54bb12ee'/>
<id>urn:sha1:244cd96adb5f5ab39551081fb1f9009a54bb12ee</id>
<content type='text'>
After commit 90b73b77d08e, list_head is no longer needed.
Now we just need to convert the list iteration to array
iteration for drivers.

Fixes: 90b73b77d08e ("net: sched: change action API to use array of pointers to actions")
Cc: Jiri Pirko &lt;jiri@mellanox.com&gt;
Cc: Vlad Buslov &lt;vladbu@mellanox.com&gt;
Signed-off-by: Cong Wang &lt;xiyou.wangcong@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net_sched: remove unused tcf_idr_check()</title>
<updated>2018-08-21T19:45:44Z</updated>
<author>
<name>Cong Wang</name>
<email>xiyou.wangcong@gmail.com</email>
</author>
<published>2018-08-19T19:22:08Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=7d485c451fc82f8ae431cdb379521bc6d0641064'/>
<id>urn:sha1:7d485c451fc82f8ae431cdb379521bc6d0641064</id>
<content type='text'>
tcf_idr_check() is replaced by tcf_idr_check_alloc(),
and __tcf_idr_check() now can be folded into tcf_idr_search().

Fixes: 0190c1d452a9 ("net: sched: atomically check-allocate action")
Cc: Jiri Pirko &lt;jiri@mellanox.com&gt;
Cc: Vlad Buslov &lt;vladbu@mellanox.com&gt;
Signed-off-by: Cong Wang &lt;xiyou.wangcong@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net_sched: remove unnecessary ops-&gt;delete()</title>
<updated>2018-08-21T19:45:44Z</updated>
<author>
<name>Cong Wang</name>
<email>xiyou.wangcong@gmail.com</email>
</author>
<published>2018-08-19T19:22:06Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=97a3f84f2c84f81b859aedd2c186df09c2ee21a6'/>
<id>urn:sha1:97a3f84f2c84f81b859aedd2c186df09c2ee21a6</id>
<content type='text'>
All ops-&gt;delete() wants is getting the tn-&gt;idrinfo, but we already
have tc_action before calling ops-&gt;delete(), and tc_action has
a pointer -&gt;idrinfo.

More importantly, each type of action does the same thing, that is,
just calling tcf_idr_delete_index().

So it can be just removed.

Fixes: b409074e6693 ("net: sched: add 'delete' function to action ops")
Cc: Jiri Pirko &lt;jiri@mellanox.com&gt;
Cc: Vlad Buslov &lt;vladbu@mellanox.com&gt;
Signed-off-by: Cong Wang &lt;xiyou.wangcong@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: sched: extend action ops with put_dev callback</title>
<updated>2018-08-11T19:37:10Z</updated>
<author>
<name>Vlad Buslov</name>
<email>vladbu@mellanox.com</email>
</author>
<published>2018-08-10T17:51:52Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=84a75b329be84c108a21ab9c02a52a9bf9e5a919'/>
<id>urn:sha1:84a75b329be84c108a21ab9c02a52a9bf9e5a919</id>
<content type='text'>
As a preparation for removing dependency on rtnl lock from rules update
path, all users of shared objects must take reference while working with
them.

Extend action ops with put_dev() API to be used on net device returned by
get_dev().

Modify mirred action (only action that implements get_dev callback):
- Take reference to net device in get_dev.
- Implement put_dev API that releases reference to net device.

Signed-off-by: Vlad Buslov &lt;vladbu@mellanox.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>tc/act: remove unneeded RCU lock in action callback</title>
<updated>2018-07-30T16:31:13Z</updated>
<author>
<name>Paolo Abeni</name>
<email>pabeni@redhat.com</email>
</author>
<published>2018-07-30T12:30:43Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=7fd4b288ea6a3e45ad8afbcd5ec39554d57f1ae0'/>
<id>urn:sha1:7fd4b288ea6a3e45ad8afbcd5ec39554d57f1ae0</id>
<content type='text'>
Each lockless action currently does its own RCU locking in -&gt;act().
This allows using plain RCU accessor, even if the context
is really RCU BH.

This change drops the per action RCU lock, replace the accessors
with the _bh variant, cleans up a bit the surrounding code and
documents the RCU status in the relevant header.
No functional nor performance change is intended.

The goal of this patch is clarifying that the RCU critical section
used by the tc actions extends up to the classifier's caller.

v1 -&gt; v2:
 - preserve rcu lock in act_bpf: it's needed by eBPF helpers,
   as pointed out by Daniel

v3 -&gt; v4:
 - fixed some typos in the commit message (JiriP)

Signed-off-by: Paolo Abeni &lt;pabeni@redhat.com&gt;
Acked-by: Jiri Pirko &lt;jiri@mellanox.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: sched: change action API to use array of pointers to actions</title>
<updated>2018-07-08T03:42:29Z</updated>
<author>
<name>Vlad Buslov</name>
<email>vladbu@mellanox.com</email>
</author>
<published>2018-07-05T14:24:33Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=90b73b77d08ec395311411b545c756ca710aae59'/>
<id>urn:sha1:90b73b77d08ec395311411b545c756ca710aae59</id>
<content type='text'>
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 &lt;jiri@mellanox.com&gt;
Signed-off-by: Vlad Buslov &lt;vladbu@mellanox.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: sched: atomically check-allocate action</title>
<updated>2018-07-08T03:42:29Z</updated>
<author>
<name>Vlad Buslov</name>
<email>vladbu@mellanox.com</email>
</author>
<published>2018-07-05T14:24:32Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=0190c1d452a91c38a3462abdd81752be1b9006a8'/>
<id>urn:sha1:0190c1d452a91c38a3462abdd81752be1b9006a8</id>
<content type='text'>
Implement function that atomically checks if action exists and either takes
reference to it, or allocates idr slot for action index to prevent
concurrent allocations of actions with same index. Use EBUSY error pointer
to indicate that idr slot is reserved.

Implement cleanup helper function that removes temporary error pointer from
idr. (in case of error between idr allocation and insertion of newly
created action to specified index)

Refactor all action init functions to insert new action to idr using this
API.

Reviewed-by: Marcelo Ricardo Leitner &lt;marcelo.leitner@gmail.com&gt;
Signed-off-by: Vlad Buslov &lt;vladbu@mellanox.com&gt;
Signed-off-by: Jiri Pirko &lt;jiri@mellanox.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: sched: add 'delete' function to action ops</title>
<updated>2018-07-08T03:42:29Z</updated>
<author>
<name>Vlad Buslov</name>
<email>vladbu@mellanox.com</email>
</author>
<published>2018-07-05T14:24:28Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=b409074e6693bcdaa7abbee2a035f22a9eabda53'/>
<id>urn:sha1:b409074e6693bcdaa7abbee2a035f22a9eabda53</id>
<content type='text'>
Extend action ops with 'delete' function. Each action type to implements
its own delete function that doesn't depend on rtnl lock.

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 from deleting same action twice.

Reviewed-by: Marcelo Ricardo Leitner &lt;marcelo.leitner@gmail.com&gt;
Signed-off-by: Vlad Buslov &lt;vladbu@mellanox.com&gt;
Signed-off-by: Jiri Pirko &lt;jiri@mellanox.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: sched: implement action API that deletes action by index</title>
<updated>2018-07-08T03:42:28Z</updated>
<author>
<name>Vlad Buslov</name>
<email>vladbu@mellanox.com</email>
</author>
<published>2018-07-05T14:24:27Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=2a2ea349704fffade9526d5122299edbbfd122ca'/>
<id>urn:sha1:2a2ea349704fffade9526d5122299edbbfd122ca</id>
<content type='text'>
Implement new action API function that atomically finds and deletes action
from idr by index. Intended to be used by lockless actions that do not rely
on rtnl lock.

Reviewed-by: Marcelo Ricardo Leitner &lt;marcelo.leitner@gmail.com&gt;
Signed-off-by: Vlad Buslov &lt;vladbu@mellanox.com&gt;
Signed-off-by: Jiri Pirko &lt;jiri@mellanox.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
</feed>
