[ovs-dev] [PATCH 1/2] tunnel: Only un-wildcard the ECN bits for IP traffic.

Ben Pfaff blp at nicira.com
Wed Jun 26 04:28:39 UTC 2013


That's good, thanks. Looks good.
On Jun 25, 2013 9:26 PM, "Justin Pettit" <jpettit at nicira.com> wrote:

> I found this by inspection, but how about something like the following?
>
> -=-=-=-=-=-=-=-=-=-
> With tunnels carrying IP packets, ECN bits are always inherited by the
> encapsulating tunnel.  However, it doesn't make sense to unwildcard the
> inner packet's TOS fields if the packet is not IP.
>
> Found by inspection.
> -=-=-=-=-=-=-=-=-=-
>
> --Justin
>
>
> On Jun 25, 2013, at 8:49 PM, Ben Pfaff <blp at nicira.com> wrote:
>
> > The change log could use some explanation of why, e.g. a description of
> what bug this fixes.
> >
> > On Jun 25, 2013 6:29 PM, "Justin Pettit" <jpettit at nicira.com> wrote:
> > Signed-off-by: Justin Pettit <jpettit at nicira.com>
> > ---
> >  ofproto/tunnel.c |    7 +++++--
> >  1 file changed, 5 insertions(+), 2 deletions(-)
> >
> > diff --git a/ofproto/tunnel.c b/ofproto/tunnel.c
> > index dedfca8..1a39aea 100644
> > --- a/ofproto/tunnel.c
> > +++ b/ofproto/tunnel.c
> > @@ -253,11 +253,14 @@ tnl_port_send(const struct tnl_port *tnl_port,
> struct flow *flow,
> >          wc->masks.nw_tos = 0xff;
> >          flow->tunnel.ip_tos = flow->nw_tos & IP_DSCP_MASK;
> >      } else {
> > -        /* ECN fields are always inherited. */
> > -        wc->masks.nw_tos |= IP_ECN_MASK;
> >          flow->tunnel.ip_tos = cfg->tos;
> >      }
> >
> > +    /* ECN fields are always inherited. */
> > +    if (is_ip_any(flow)) {
> > +        wc->masks.nw_tos |= IP_ECN_MASK;
> > +    }
> > +
> >      if ((flow->nw_tos & IP_ECN_MASK) == IP_ECN_CE) {
> >          flow->tunnel.ip_tos |= IP_ECN_ECT_0;
> >      } else {
> > --
> > 1.7.9.5
> >
> > _______________________________________________
> > dev mailing list
> > dev at openvswitch.org
> > http://openvswitch.org/mailman/listinfo/dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openvswitch.org/pipermail/ovs-dev/attachments/20130625/2dfbcb1c/attachment-0003.html>


More information about the dev mailing list