On Aug 2, 2013, at 11:13 PM, Ben Pfaff <b...@nicira.com> wrote:

> On Fri, Aug 02, 2013 at 10:57:53PM -0700, Justin Pettit wrote:
>> The ODP library has an optimization to not set a header if the field was
>> not changed, regardless of whether an action to set the field was
>> present.  That library is also responsible for un-wildcarding fields
>> that are bieng modified.  This leads to a problem where a packet matches
>> a flow that updates a field, but that particular packet's field already
>> has that value.  As such, an overly loose megaflow will be generated
>> that doesn't match on that field and the actions won't update it.  A
>> second packet that should have the field set will match that flow and
>> will not be modified.
>> 
>> This commit changes the behavior to always un-wildcard fields that are
>> being modified.  Since the ODP library updates the entire header if a
>> field in it is modified, and all those fields will be un-wildcarded, the
>> generated flows may be different.  However, they should be correct.
>> 
>> Bug #18946.
>> 
>> Reported-by: Jesse Gross <je...@nicira.com>
>> Signed-off-by: Justin Pettit <jpet...@nicira.com>
> 
> I would think that in the OFPACT_STRIP_VLAN and OFPACT_PUSH_VLAN cases
> we would need to set all the bits in wc->masks.vlan_tci to 1-bits, since
> we are potentially modifying all of them.

I went ahead and did as you suggested.  As Jesse pointed out, it wasn't really 
necessary, but I don't think it will hurt either.  If anyone would prefer to 
flipping it back to how it was, let me know, and I can add a new patch.

> Otherwise this looks fine to me, thanks.
> 
> Acked-by: Ben Pfaff <b...@nicira.com>

Thanks for the late night reviews.  I pushed this to all affected branches.

--Justin


_______________________________________________
dev mailing list
dev@openvswitch.org
http://openvswitch.org/mailman/listinfo/dev

Reply via email to