X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=datapath%2Fdatapath.c;fp=datapath%2Fdatapath.c;h=f990b738a3b72f103f21b304c56352f0fdeed91f;hb=72e8bf28bb38e8816435c64859fb350215b6a9e6;hp=ade9de53b8e4381d86acef71f47a884cb94cae10;hpb=24f974c481bc5230552b23d96312f645f7533cd3;p=openvswitch diff --git a/datapath/datapath.c b/datapath/datapath.c index ade9de53..f990b738 100644 --- a/datapath/datapath.c +++ b/datapath/datapath.c @@ -595,6 +595,13 @@ static int validate_set(const struct nlattr *a, case OVS_KEY_ATTR_ETHERNET: break; + case OVS_KEY_ATTR_SKB_MARK: +#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,20) && !defined(CONFIG_NETFILTER) + if (nla_get_u32(ovs_key) != 0) + return -EINVAL; +#endif + break; + case OVS_KEY_ATTR_IPV4_TUNNEL: tun_key = nla_data(ovs_key); if (!tun_key->ipv4_dst) @@ -826,6 +833,7 @@ static int ovs_packet_cmd_execute(struct sk_buff *skb, struct genl_info *info) OVS_CB(packet)->flow = flow; packet->priority = flow->key.phy.priority; + skb_set_mark(packet, flow->key.phy.skb_mark); rcu_read_lock(); dp = get_dp(sock_net(skb->sk), ovs_header->dp_ifindex);