[ovs-dev] [PATCH] ofp-util: For OF1.0, don't wildcard PCP field when 802.1Q header absent.
blp at nicira.com
Mon Aug 24 18:04:30 UTC 2015
On Mon, Aug 24, 2015 at 10:52:10AM -0700, Jarno Rajahalme wrote:
> > On Aug 20, 2015, at 5:09 PM, Ben Pfaff <blp at nicira.com> wrote:
> > On Thu, Aug 06, 2015 at 01:10:04PM -0700, Jarno Rajahalme wrote:
> >>> On Aug 5, 2015, at 9:59 PM, Ben Pfaff <blp at nicira.com> wrote:
> >>> OpenFlow 1.0.1 says:
> >>> The dl_vlan_pcp field must be ignored when the OFPFW_DL_VLAN wildcard
> >>> bit is set or when the dl_vlan value is set to OFP_VLAN_NONE. Fields
> >>> that are ignored don’t need to be wildcarded and should be set to 0.
> >>> Previously, OVS wildcarded the PCP field when dl_vlan was OFP_VLAN_NONE,
> >>> but this commit changes the behavior to that suggested above: the PCP
> >>> field should not be wildcarded (and should be set to 0, but the code
> >>> already did that).
> >> This feels highly counter-intuitive, but it works due to flow parser
> >> setting the PCP bits to zeroes when there is no vlan in the
> >> packet. However, this change will make matching a bit less efficient,
> >> as generally it is faster to wildcard bits than match them. Good to
> >> see that this was changed in OF 1.1.
> > I don't think this changes the behavior in this area. It should only
> > affect the treatment on OFP_VLAN_NONE on translation to OpenFlow 1.0.
> > OFP_VLAN_NONE was already a special-case in translation from OpenFlow
> > 1.0 to struct flow in ofputil_match_from_ofp10_match(), and I believe
> > that there should be no change there.
> > Do you see a change?
> No, I did not notice that this changes only the mapping to OF 1.0 from
> the internal representation. No comment then :-)
> Acked-by: Jarno Rajahalme <jrajahalme at nicira.com>
Thanks. To make that really clear I added a paragraph to the commit
This commit only changes the translation from OVS's internal flow format
to the OpenFlow 1.0 wire format. Translation in the other direction and
to other formats is unaffected.
I applied this to master.
More information about the dev