#include <stdlib.h>
#include <string.h>
+#include "dpif.h"
#include "netlink.h"
#include "ofpbuf.h"
#include "odp-util.h"
static void
odp_execute_set_action(struct ofpbuf *packet, const struct nlattr *a,
- struct flow *md)
+ struct pkt_metadata *md)
{
enum ovs_key_attr type = nl_attr_type(a);
const struct ovs_key_ipv4 *ipv4_key;
}
static void
-odp_execute_actions__(void *dp, struct ofpbuf *packet, struct flow *key,
+odp_execute_actions__(void *dp, struct ofpbuf *packet, struct pkt_metadata *,
const struct nlattr *actions, size_t actions_len,
odp_execute_cb dp_execute_action, bool more_actions);
static void
-odp_execute_sample(void *dp, struct ofpbuf *packet, struct flow *md,
+odp_execute_sample(void *dp, struct ofpbuf *packet, struct pkt_metadata *md,
const struct nlattr *action,
odp_execute_cb dp_execute_action, bool more_actions)
{
}
static void
-odp_execute_actions__(void *dp, struct ofpbuf *packet, struct flow *md,
+odp_execute_actions__(void *dp, struct ofpbuf *packet, struct pkt_metadata *md,
const struct nlattr *actions, size_t actions_len,
odp_execute_cb dp_execute_action, bool more_actions)
{
case OVS_ACTION_ATTR_PUSH_VLAN: {
const struct ovs_action_push_vlan *vlan = nl_attr_get(a);
- eth_push_vlan(packet, vlan->vlan_tci);
+ eth_push_vlan(packet, htons(ETH_TYPE_VLAN), vlan->vlan_tci);
break;
}
}
void
-odp_execute_actions(void *dp, struct ofpbuf *packet, struct flow *md,
+odp_execute_actions(void *dp, struct ofpbuf *packet, struct pkt_metadata *md,
const struct nlattr *actions, size_t actions_len,
odp_execute_cb dp_execute_action)
{