NXM_OF_VLAN_TCI(_W), a mask of ffff is equivalent to
NXM_OF_VLAN_TCI.
- - OF1.0 and OF1.1: wwww/x,yy/z means dl_vlan wwww, OFPFW_DL_VLAN
- x, dl_vlan_pcp yy, and OFPFW_DL_VLAN_PCP z. ? means that the
- given nibble is ignored (and conventionally 0 for wwww or yy,
- conventionally 1 for x or z). <none> means that the given match
- is not supported.
+ - OF1.0 and OF1.1: wwww/x,yy/z means dl_vlan wwww, OFPFW_DL_VLAN x,
+ dl_vlan_pcp yy, and OFPFW_DL_VLAN_PCP z. If OFPFW_DL_VLAN or
+ OFPFW_DL_VLAN_PCP is 1, the corresponding field value is
+ wildcarded, otherwise it is matched. ? means that the given bits
+ are ignored (their conventional values are 0000/x,00/0 in OF1.0,
+ 0000/x,00/1 in OF1.1; x is never ignored). <none> means that the
+ given match is not supported.
- OF1.2: xxxx/yyyy,zz means OXM_OF_VLAN_VID_W with value xxxx and
mask yyyy, and OXM_OF_VLAN_PCP (which is not maskable) with
} else if (match->wc.masks.vlan_tci & htons(VLAN_CFI)
&& !(match->flow.vlan_tci & htons(VLAN_CFI))) {
ofmatch->dl_vlan = htons(OFP10_VLAN_NONE);
- ofpfw |= OFPFW10_DL_VLAN_PCP;
} else {
if (!(match->wc.masks.vlan_tci & htons(VLAN_VID_MASK))) {
ofpfw |= OFPFW10_DL_VLAN;
#! /usr/bin/perl
-# Copyright (c) 2009, 2010, 2011, 2012 Nicira, Inc.
+# Copyright (c) 2009, 2010, 2011, 2012, 2015 Nicira, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
$packet .= pack_ethaddr($flow{DL_SRC});
if ($flow{DL_VLAN} != 0xffff) {
$packet .= pack('nn', 0x8100, $flow{DL_VLAN});
- } else {
- $wildcards |= 1 << 20; # OFPFW10_DL_VLAN_PCP
}
my $len_ofs = length($packet);
$packet .= pack('n', 0) if $attrs{DL_HEADER} =~ /^802.2/;
002820fd xxxx xxxxxxxxxxxx xxxxxxxxxxxx 0123 04 xx xxxx xx xx xxxx dnl
xxxxxxxx xxxxxxxx xxxx xxxx
+dnl dl_vlan_pcp doesn't make sense when 802.1Q is not present, so
+dnl OVS ignores it and drops it on output.
# vlan_tci=0x0000
+# 1: 38 -> 28
003820fd xxxx xxxxxxxxxxxx xxxxxxxxxxxx ffff xx xx xxxx xx xx xxxx dnl
xxxxxxxx xxxxxxxx xxxx xxxx
-dnl dl_vlan_pcp doesn't make sense when dl_vlan is "none", so
+dnl dl_vlan_pcp doesn't make sense when 802.1Q is not present, so
dnl OVS ignores it and drops it on output.
# vlan_tci=0x0000
-# 1: 28 -> 38
# 20: 05 -> 00
002820fd xxxx xxxxxxxxxxxx xxxxxxxxxxxx ffff 05 xx xxxx xx xx xxxx dnl
xxxxxxxx xxxxxxxx xxxx xxxx
vlan_tci=0x0000 -> 0000/ffff
NXM: NXM_OF_VLAN_TCI(0000) -> 0000/ffff
OXM: OXM_OF_VLAN_VID(0000) -> 0000/1fff,--
-OF1.0: ffff/0,00/1 -> 0000/ffff
+OF1.0: ffff/0,00/0 -> 0000/ffff
OF1.1: ffff/0,00/1 -> 0000/ffff
])
vlan_tci=0x0000/0xf000 -> 0000/f000
NXM: NXM_OF_VLAN_TCI_W(0000/f000) -> 0000/f000
OXM: OXM_OF_VLAN_VID_W(0000/1000) -> 0000/1000,--
-OF1.0: ffff/0,00/1 -> 0000/ffff
+OF1.0: ffff/0,00/0 -> 0000/ffff
OF1.1: ffff/0,00/1 -> 0000/ffff
])