]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - include/net/ipv6.h
ARM: OMAP: Fix 32k timer unsupported one-shot mode
[linux-2.6-omap-h63xx.git] / include / net / ipv6.h
index f70afef9c3cc9fde793fdf3aa29bb0de23742cdf..9059e0ed7fe375e70d12740a1703526d89aba944 100644 (file)
@@ -17,6 +17,7 @@
 
 #include <linux/ipv6.h>
 #include <linux/hardirq.h>
+#include <net/if_inet6.h>
 #include <net/ndisc.h>
 #include <net/flow.h>
 #include <net/snmp.h>
@@ -204,9 +205,9 @@ struct ip6_flowlabel
 {
        struct ip6_flowlabel    *next;
        __be32                  label;
+       atomic_t                users;
        struct in6_addr         dst;
        struct ipv6_txoptions   *opt;
-       atomic_t                users;
        unsigned long           linger;
        u8                      share;
        u32                     owner;
@@ -291,7 +292,7 @@ static inline int ipv6_addr_src_scope(const struct in6_addr *addr)
 
 static inline int ipv6_addr_cmp(const struct in6_addr *a1, const struct in6_addr *a2)
 {
-       return memcmp((const void *) a1, (const void *) a2, sizeof(struct in6_addr));
+       return memcmp(a1, a2, sizeof(struct in6_addr));
 }
 
 static inline int
@@ -308,7 +309,7 @@ ipv6_masked_addr_cmp(const struct in6_addr *a1, const struct in6_addr *m,
 
 static inline void ipv6_addr_copy(struct in6_addr *a1, const struct in6_addr *a2)
 {
-       memcpy((void *) a1, (const void *) a2, sizeof(struct in6_addr));
+       memcpy(a1, a2, sizeof(struct in6_addr));
 }
 
 static inline void ipv6_addr_prefix(struct in6_addr *pfx, 
@@ -319,16 +320,12 @@ static inline void ipv6_addr_prefix(struct in6_addr *pfx,
        int o = plen >> 3,
            b = plen & 0x7;
 
+       memset(pfx->s6_addr, 0, sizeof(pfx->s6_addr));
        memcpy(pfx->s6_addr, addr, o);
-       if (b != 0) {
+       if (b != 0)
                pfx->s6_addr[o] = addr->s6_addr[o] & (0xff00 >> b);
-               o++;
-       }
-       if (o < 16)
-               memset(pfx->s6_addr + o, 0, 16 - o);
 }
 
-#ifndef __HAVE_ARCH_ADDR_SET
 static inline void ipv6_addr_set(struct in6_addr *addr, 
                                     __be32 w1, __be32 w2,
                                     __be32 w3, __be32 w4)
@@ -338,7 +335,6 @@ static inline void ipv6_addr_set(struct in6_addr *addr,
        addr->s6_addr32[2] = w3;
        addr->s6_addr32[3] = w4;
 }
-#endif
 
 static inline int ipv6_addr_equal(const struct in6_addr *a1,
                                  const struct in6_addr *a2)
@@ -474,6 +470,9 @@ extern void                 ip6_flush_pending_frames(struct sock *sk);
 extern int                     ip6_dst_lookup(struct sock *sk,
                                               struct dst_entry **dst,
                                               struct flowi *fl);
+extern int                     ip6_dst_blackhole(struct sock *sk,
+                                                 struct dst_entry **dst,
+                                                 struct flowi *fl);
 extern int                     ip6_sk_dst_lookup(struct sock *sk,
                                                  struct dst_entry **dst,
                                                  struct flowi *fl);
@@ -514,10 +513,6 @@ extern int                         ipv6_ext_hdr(u8 nexthdr);
 
 extern int ipv6_find_tlv(struct sk_buff *skb, int offset, int type);
 
-extern struct ipv6_txoptions * ipv6_invert_rthdr(struct sock *sk,
-                                                 struct ipv6_rt_hdr *hdr);
-
-
 /*
  *     socket options (ipv6_sockglue.c)
  */