ipv6: use ip6_flowinfo helper
authorFlorent Fourcot <florent.fourcot@enst-bretagne.fr>
Sun, 8 Dec 2013 14:47:01 +0000 (15:47 +0100)
committerDavid S. Miller <davem@davemloft.net>
Tue, 10 Dec 2013 02:03:50 +0000 (21:03 -0500)
Signed-off-by: Florent Fourcot <florent.fourcot@enst-bretagne.fr>
Reviewed-by: Hannes Frederic Sowa <hannes@stressinduktion.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv6/af_inet6.c

index 4fbdb70..027615a 100644 (file)
@@ -683,8 +683,7 @@ bool ipv6_opt_accepted(const struct sock *sk, const struct sk_buff *skb)
        if (np->rxopt.all) {
                if ((opt->hop && (np->rxopt.bits.hopopts ||
                                  np->rxopt.bits.ohopopts)) ||
-                   ((IPV6_FLOWINFO_MASK &
-                     *(__be32 *)skb_network_header(skb)) &&
+                   (ip6_flowinfo((struct ipv6hdr *) skb_network_header(skb)) &&
                     np->rxopt.bits.rxflow) ||
                    (opt->srcrt && (np->rxopt.bits.srcrt ||
                     np->rxopt.bits.osrcrt)) ||