@@ -428,6 +428,8 @@ dump_flow_action(struct ds *s, const struct rte_flow_action *actions)
} else {
ds_put_format(s, "vlan-encap: null\n");
}
+ } else if (actions->type == RTE_FLOW_ACTION_TYPE_OF_POP_VLAN) {
+ ds_put_format(s, "vlan-decap: nop\n");
} else if (actions->type == RTE_FLOW_ACTION_TYPE_SET_MAC_SRC ||
actions->type == RTE_FLOW_ACTION_TYPE_SET_MAC_DST) {
const struct rte_flow_action_set_mac *set_mac = actions->conf;
@@ -1210,6 +1212,8 @@ parse_clone_actions(struct netdev *netdev,
vlan_tci->ethertype = vlan->vlan_tci & ~htons(VLAN_CFI);
add_flow_action(actions, RTE_FLOW_ACTION_TYPE_OF_PUSH_VLAN,
vlan_tci);
+ } else if (clone_type == OVS_ACTION_ATTR_POP_VLAN) {
+ add_flow_action(actions, RTE_FLOW_ACTION_TYPE_OF_POP_VLAN, NULL);
} else {
VLOG_DBG_RL(&rl,
"Unsupported nested action inside clone(), "
@@ -1259,7 +1263,6 @@ parse_flow_actions(struct netdev *netdev,
clone_actions_len,info)) {
return -1;
}
-
} else if (nl_attr_type(nla) == OVS_ACTION_ATTR_PUSH_VLAN) {
const struct ovs_action_push_vlan *vlan = nl_attr_get(nla);
struct rte_flow_action_of_push_vlan *vlan_tci;
@@ -1268,6 +1271,8 @@ parse_flow_actions(struct netdev *netdev,
vlan_tci->ethertype = vlan->vlan_tci & ~htons(VLAN_CFI);
add_flow_action(actions, RTE_FLOW_ACTION_TYPE_OF_PUSH_VLAN,
vlan_tci);
+ } else if (nl_attr_type(nla) == OVS_ACTION_ATTR_POP_VLAN) {
+ add_flow_action(actions, RTE_FLOW_ACTION_TYPE_OF_POP_VLAN, NULL);
} else {
VLOG_DBG_RL(&rl, "Unsupported action type %d", nl_attr_type(nla));
return -1;
From: Liuchang <liuchang@cmss.chinamobile.com> Code Source From: Self Code Description: add vlan-pop action offloading mechanism Jira: #[Optional] 市场项目编号(名称):[Optional] --- lib/netdev-offload-dpdk.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-)