datapath: Don't use ipv6_addr_copy().
authorJesse Gross <jesse@nicira.com>
Wed, 30 Nov 2011 18:46:54 +0000 (10:46 -0800)
committerJesse Gross <jesse@nicira.com>
Wed, 30 Nov 2011 18:53:35 +0000 (10:53 -0800)
It was dropped upstream in favor of direct structure assignment.

Signed-off-by: Jesse Gross <jesse@nicira.com>
Acked-by: Ben Pfaff <blp@nicira.com>
datapath/flow.c
datapath/tunnel.c

index 78f737abda2d087a2cc505e1bd5b855b53a19900..c6f591afe166ecaf17ef98ca742b8bed991435e1 100644 (file)
@@ -212,8 +212,8 @@ static int parse_ipv6hdr(struct sk_buff *skb, struct sw_flow_key *key,
        key->ip.tos = ipv6_get_dsfield(nh);
        key->ip.ttl = nh->hop_limit;
        key->ipv6.label = *(__be32 *)nh & htonl(IPV6_FLOWINFO_FLOWLABEL);
-       ipv6_addr_copy(&key->ipv6.addr.src, &nh->saddr);
-       ipv6_addr_copy(&key->ipv6.addr.dst, &nh->daddr);
+       key->ipv6.addr.src = nh->saddr;
+       key->ipv6.addr.dst = nh->daddr;
 
        payload_ofs = skip_exthdr(skb, payload_ofs, &nexthdr, &key->ip.frag);
        if (unlikely(payload_ofs < 0))
@@ -572,7 +572,7 @@ static int parse_icmpv6(struct sk_buff *skb, struct sw_flow_key *key,
                }
 
                nd = (struct nd_msg *)skb_transport_header(skb);
-               ipv6_addr_copy(&key->ipv6.nd.target, &nd->target);
+               key->ipv6.nd.target = nd->target;
                key_len = SW_FLOW_KEY_OFFSET(ipv6.nd);
 
                icmp_len -= sizeof(*nd);
index 41907b95e039e0699421e42fb86a96bbd7f51ea7..4ce830ff65a3d212a387ea408d95ee0e8cbd36b1 100644 (file)
@@ -587,8 +587,8 @@ static void ipv6_build_icmp(struct sk_buff *skb, struct sk_buff *nskb,
                                              + payload_length);
        ipv6h->nexthdr          =       NEXTHDR_ICMP;
        ipv6h->hop_limit        =       IPV6_DEFAULT_HOPLIMIT;
-       ipv6_addr_copy(&ipv6h->daddr, &old_ipv6h->saddr);
-       ipv6_addr_copy(&ipv6h->saddr, &old_ipv6h->daddr);
+       ipv6h->daddr            =       old_ipv6h->saddr;
+       ipv6h->saddr            =       old_ipv6h->daddr;
 
        /* ICMPv6 */
        icmp6h->icmp6_type      =       ICMPV6_PKT_TOOBIG;