[IPV6]: annotate struct frag_hdr
[linux-block.git] / include / net / ipv6.h
index a8fdf7970b370a8aca9f216a72fec4b7b378d60e..4953fac1d070267c4f98c40cf6124936e03730e2 100644 (file)
@@ -40,6 +40,7 @@
 #define NEXTHDR_ICMP           58      /* ICMP for IPv6. */
 #define NEXTHDR_NONE           59      /* No next header */
 #define NEXTHDR_DEST           60      /* Destination options header. */
+#define NEXTHDR_MOBILITY       135     /* Mobility header. */
 
 #define NEXTHDR_MAX            255
 
  */
 
 struct frag_hdr {
-       unsigned char   nexthdr;
-       unsigned char   reserved;       
-       unsigned short  frag_off;
-       __u32           identification;
+       __u8    nexthdr;
+       __u8    reserved;
+       __be16  frag_off;
+       __be32  identification;
 };
 
 #define        IP6_MF  0x0001
@@ -229,7 +230,7 @@ extern int                  ip6_ra_control(struct sock *sk, int sel,
                                               void (*destructor)(struct sock *));
 
 
-extern int                     ipv6_parse_hopopts(struct sk_buff *skb);
+extern int                     ipv6_parse_hopopts(struct sk_buff **skbp);
 
 extern struct ipv6_txoptions *  ipv6_dup_options(struct sock *sk, struct ipv6_txoptions *opt);
 extern struct ipv6_txoptions * ipv6_renew_options(struct sock *sk, struct ipv6_txoptions *opt,
@@ -317,8 +318,8 @@ static inline void ipv6_addr_prefix(struct in6_addr *pfx,
 
 #ifndef __HAVE_ARCH_ADDR_SET
 static inline void ipv6_addr_set(struct in6_addr *addr, 
-                                    __u32 w1, __u32 w2,
-                                    __u32 w3, __u32 w4)
+                                    __be32 w1, __be32 w2,
+                                    __be32 w3, __be32 w4)
 {
        addr->s6_addr32[0] = w1;
        addr->s6_addr32[1] = w2;
@@ -336,7 +337,7 @@ static inline int ipv6_addr_equal(const struct in6_addr *a1,
                a1->s6_addr32[3] == a2->s6_addr32[3]);
 }
 
-static inline int __ipv6_prefix_equal(const u32 *a1, const u32 *a2,
+static inline int __ipv6_prefix_equal(const __be32 *a1, const __be32 *a2,
                                      unsigned int prefixlen)
 {
        unsigned pdw, pbi;
@@ -468,6 +469,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_sk_dst_lookup(struct sock *sk,
+                                                 struct dst_entry **dst,
+                                                 struct flowi *fl);
 
 /*
  *     skb processing functions
@@ -503,6 +507,8 @@ extern int                  ipv6_skip_exthdr(const struct sk_buff *, int start,
 
 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);