Merge branch 'tc_action_ops-refactor'
authorDavid S. Miller <davem@davemloft.net>
Fri, 9 Sep 2022 07:24:43 +0000 (08:24 +0100)
committerDavid S. Miller <davem@davemloft.net>
Fri, 9 Sep 2022 07:24:43 +0000 (08:24 +0100)
Zhengchao Shao says:

====================
net: refactor the walk and lookup hook functions in tc_action_ops

The implementation logic of the walk/lookup hook function in each action
module is the same. Therefore, the two functions can be reconstructed.
When registering tc_action_ops of each action module, the corresponding
net_id is saved to tc_action_ops. In this way, the net_id of the
corresponding module can be directly obtained in act_api without executing
the specific walk and lookup hook functions. Then, generic functions can
be added to replace the walk and lookup hook functions of each action
module. Last, modify each action module in alphabetical order.

Reserve the walk and lookup interfaces and delete them when they are no
longer used.

This patchset has been tested by using TDC, and I will add selftest in
other patchset.

Last, thanks to Jamal Hadi Salim and Cong Wang for their advice.
---
v3: remove hole from the structure tc_action_ops
v2: save the net_id of each TC action module to the tc_action_ops structure
====================

Signed-off-by: David S. Miller <davem@davemloft.net>

Trivial merge