]> git.baikalelectronics.ru Git - kernel.git/commit
net/sched: cls_api: Fix flow action initialization
authorOz Shlomo <ozsh@nvidia.com>
Tue, 19 Jul 2022 12:24:09 +0000 (15:24 +0300)
committerDavid S. Miller <davem@davemloft.net>
Wed, 20 Jul 2022 09:54:27 +0000 (10:54 +0100)
commitbde0320a76208dc3f44ef0af0aea1f26a64edfac
tree0627944e9f924c863319ac5b55c384564578b32d
parent16ee222b2339f4c59abf340d2d7f7162e3b2e8c1
net/sched: cls_api: Fix flow action initialization

The cited commit refactored the flow action initialization sequence to
use an interface method when translating tc action instances to flow
offload objects. The refactored version skips the initialization of the
generic flow action attributes for tc actions, such as pedit, that allocate
more than one offload entry. This can cause potential issues for drivers
mapping flow action ids.

Populate the generic flow action fields for all the flow action entries.

Fixes: 62e9a851648a ("flow_offload: add ops to tc_action_ops for flow action setup")
Signed-off-by: Oz Shlomo <ozsh@nvidia.com>
Reviewed-by: Roi Dayan <roid@nvidia.com>
----
v1 -> v2:
 - coalese the generic flow action fields initialization to a single loop
Reviewed-by: Baowen Zheng <baowen.zheng@corigine.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/sched/cls_api.c