diff options
author | Ben Pfaff <blp@nicira.com> | 2011-11-14 17:19:41 -0800 |
---|---|---|
committer | Ben Pfaff <blp@nicira.com> | 2011-11-14 20:23:17 -0800 |
commit | 8ddc056dd1e2c150c3bf8bb16811815736beb554 (patch) | |
tree | 005060795a94245b5742413408f6237f720c73c8 /include | |
parent | fea393b1d6b2729a784b898dbdd48d30d42e3ff7 (diff) |
datapath: Don't drop packets with partial vlan tags.
In the future it is likely that our vlan support will expand to
include multiply tagged packets. When this happens, we would
ideally like for it to be consistent with our current tagging.
Currently, if we receive a packet with a partial VLAN tag we will
automatically drop it in the kernel, which is unique among the
protocols we support. The only other reason to drop a packet is
a memory allocation error. For a doubly tagged packet, we will
parse the first tag and indicate that another tag was present but
do not drop if the second tag is incorrect as we do not parse it.
This changes the behavior of the vlan parser to match other protocols
and also deeper tags by indicating the presence of a broken tag with
the 802.1Q EtherType but no vlan information. This shifts the policy
decision to userspace on whether to drop broken tags and allows us to
uniformly add new levels of tag parsing.
Although additional levels of control are provided to userspace, this
maintains the current behavior of dropping packets with a broken
tag when using the NORMAL action because that is the correct behavior
for an 802.1Q-aware switch. The userspace flow parser actually
already had the new behavior so this corrects an inconsistency.
Reported-by: Jesse Gross <jesse@nicira.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
Acked-by: Jesse Gross <jesse@nicira.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/openvswitch.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/include/linux/openvswitch.h b/include/linux/openvswitch.h index 2d141e0d..4f081369 100644 --- a/include/linux/openvswitch.h +++ b/include/linux/openvswitch.h @@ -439,8 +439,8 @@ enum ovs_userspace_attr { /** * struct ovs_action_push_vlan - %OVS_ACTION_ATTR_PUSH_VLAN action argument. * @vlan_tpid: Tag protocol identifier (TPID) to push. - * @vlan_tci: Tag control identifier (TCI) to push. The CFI bit must not be - * set. + * @vlan_tci: Tag control identifier (TCI) to push. The CFI bit must be set + * (but it will not be set in the 802.1Q header that is pushed). * * The @vlan_tpid value is typically %ETH_P_8021Q. The only acceptable TPID * values are those that the kernel module also parses as 802.1Q headers, to |