diff options
author | Eelco Chaudron <echaudro@redhat.com> | 2022-02-22 16:26:10 +0100 |
---|---|---|
committer | Ilya Maximets <i.maximets@ovn.org> | 2022-04-06 13:35:58 +0200 |
commit | 632b73870a14d5219c25a10922c677ec328778cc (patch) | |
tree | b936048079ef6696a60dbec8e1b9425fa1a98722 | |
parent | 37df323243de5481bc9aed52d6eac88af54e7d60 (diff) | |
download | openvswitch-632b73870a14d5219c25a10922c677ec328778cc.tar.gz |
netdev-offload-tc: Check for ct_state flag combinations that are not offloadable.
This patch checks for none offloadable ct_state match flag combinations.
If they exist force the +trk flag down to TC Flower
Signed-off-by: Eelco Chaudron <echaudro@redhat.com>
Acked-by: Roi Dayan <roid@nvidia.com>
Signed-off-by: Ilya Maximets <i.maximets@ovn.org>
-rw-r--r-- | lib/netdev-offload-tc.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/netdev-offload-tc.c b/lib/netdev-offload-tc.c index 193e8f64c..30032e836 100644 --- a/lib/netdev-offload-tc.c +++ b/lib/netdev-offload-tc.c @@ -1441,6 +1441,12 @@ parse_match_ct_state_to_flower(struct tc_flower *flower, struct match *match) flower->key.ct_state &= ~(TCA_FLOWER_KEY_CT_FLAGS_NEW); flower->mask.ct_state &= ~(TCA_FLOWER_KEY_CT_FLAGS_NEW); } + + if (flower->key.ct_state && + !(flower->key.ct_state & TCA_FLOWER_KEY_CT_FLAGS_TRACKED)) { + flower->key.ct_state |= TCA_FLOWER_KEY_CT_FLAGS_TRACKED; + flower->mask.ct_state |= TCA_FLOWER_KEY_CT_FLAGS_TRACKED; + } } if (mask->ct_zone) { |