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
Acked-by: Roi Dayan
@@ -1537,6 +1537,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) {
