[ovs-dev] [PATCH] datapath: Don't update flow key when applying actions.

Jesse Gross jesse at nicira.com
Thu Jul 15 20:14:28 UTC 2010


On Thu, Jul 15, 2010 at 1:09 PM, Ben Pfaff <blp at nicira.com> wrote:

> On Thu, Jul 15, 2010 at 01:03:58PM -0700, Jesse Gross wrote:
> > Currently the flow key is updated to match an action that is applied
> > to a packet but these field are never looked at again.  Not only is
> > this a waste of time it also makes optimizations involving caching
> > the flow key more difficult.
>
> We deliberately un-optimized this back in March, on the basis that "we
> sometimes use the key for checks later on":
>
> commit 11cdf5e612949b61ee0f531d355a911e0c59d6de
> Author: Jesse Gross <jesse at nicira.com>
> Date:   Fri Mar 12 16:36:58 2010 -0500
>
>    datapath: Consistently maintain flow key.
>
>    After executing an action that changes a packet sometimes we update
>    the flow key and sometimes we don't.  This is potentially problematic
>    because we sometimes use the key for checks later on.  This consistently
>    maintains the key.
>
> Are you only removing updates that we actually use?
>

I know I did this before.  Really, I'm just trying to boost my commit
count...

We do look at the key at certain points but not for fields that change (the
fields we look at are dl_type and nw_proto).  Before I really just wanted to
be consistent about and thought that it was best to always keep it up to
date.  However, this causes problems with some of the optimizations I'm
planning, so now I think we should be consistent in the opposite direction.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openvswitch.org/pipermail/ovs-dev/attachments/20100715/09ad5dd9/attachment-0003.html>


More information about the dev mailing list