[ovs-dev] [PATCH 6/8] Add connection tracking label support.

Joe Stringer joestringer at nicira.com
Wed Sep 16 20:42:42 UTC 2015


On 11 September 2015 at 16:22, Jarno Rajahalme <jrajahalme at nicira.com> wrote:
>> @@ -4177,6 +4181,32 @@ put_ct_mark(const struct flow *flow, struct flow *base_flow,
>>  }
>>
>>  static void
>> +put_ct_label(const struct flow *flow, struct flow *base_flow,
>> +             struct ofpbuf *odp_actions, struct flow_wildcards *wc)
>> +{
>> +    const ovs_u128 *key;
>> +    ovs_u128 *mask, *base;
>> +
>> +    key = &flow->ct_label;
>> +    base = &base_flow->ct_label;
>> +    mask = &wc->masks.ct_label;
>> +
>> +    if (!is_all_zeros(mask, sizeof(*mask)) && memcmp(key, base, sizeof(*key))) {
> We have u128 specific functions for both uses here.
>
> Also, what if we have multiple ct actions with labels?

Can you elaborate what you mean here?

If the mask expects the label to be modified, and the current value is
different from when it came in, we will apply the (flattened) changes.

If multiple ct() actions are executed in a single flow, none of them
should see the changes from the previous label change because they
should only appear after recirculation. (This isn't the case in this
version, but it will be in the next series I send out).



More information about the dev mailing list