diff options
author | David Howells <dhowells@redhat.com> | 2012-10-13 05:46:48 -0400 |
---|---|---|
committer | David Howells <dhowells@redhat.com> | 2012-10-13 05:46:48 -0400 |
commit | 607ca46e97a1b6594b29647d98a32d545c24bdff (patch) | |
tree | 30f4c0784bfddb57332cdc0678bd06d1e77fa185 /include/linux/ipv6.h | |
parent | 08cce05c5a91f5017f4edc9866cf026908c73f9f (diff) |
UAPI: (Scripted) Disintegrate include/linux
Signed-off-by: David Howells <dhowells@redhat.com>
Acked-by: Arnd Bergmann <arnd@arndb.de>
Acked-by: Thomas Gleixner <tglx@linutronix.de>
Acked-by: Michael Kerrisk <mtk.manpages@gmail.com>
Acked-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Acked-by: Dave Jones <davej@redhat.com>
Diffstat (limited to 'include/linux/ipv6.h')
-rw-r--r-- | include/linux/ipv6.h | 166 |
1 files changed, 1 insertions, 165 deletions
diff --git a/include/linux/ipv6.h b/include/linux/ipv6.h index 0b94e91ed68..bcba48a9786 100644 --- a/include/linux/ipv6.h +++ b/include/linux/ipv6.h | |||
@@ -1,134 +1,9 @@ | |||
1 | #ifndef _IPV6_H | 1 | #ifndef _IPV6_H |
2 | #define _IPV6_H | 2 | #define _IPV6_H |
3 | 3 | ||
4 | #include <linux/types.h> | 4 | #include <uapi/linux/ipv6.h> |
5 | #include <linux/in6.h> | ||
6 | #include <asm/byteorder.h> | ||
7 | 5 | ||
8 | /* The latest drafts declared increase in minimal mtu up to 1280. */ | ||
9 | |||
10 | #define IPV6_MIN_MTU 1280 | ||
11 | |||
12 | /* | ||
13 | * Advanced API | ||
14 | * source interface/address selection, source routing, etc... | ||
15 | * *under construction* | ||
16 | */ | ||
17 | |||
18 | |||
19 | struct in6_pktinfo { | ||
20 | struct in6_addr ipi6_addr; | ||
21 | int ipi6_ifindex; | ||
22 | }; | ||
23 | |||
24 | struct ip6_mtuinfo { | ||
25 | struct sockaddr_in6 ip6m_addr; | ||
26 | __u32 ip6m_mtu; | ||
27 | }; | ||
28 | |||
29 | struct in6_ifreq { | ||
30 | struct in6_addr ifr6_addr; | ||
31 | __u32 ifr6_prefixlen; | ||
32 | int ifr6_ifindex; | ||
33 | }; | ||
34 | |||
35 | #define IPV6_SRCRT_STRICT 0x01 /* Deprecated; will be removed */ | ||
36 | #define IPV6_SRCRT_TYPE_0 0 /* Deprecated; will be removed */ | ||
37 | #define IPV6_SRCRT_TYPE_2 2 /* IPv6 type 2 Routing Header */ | ||
38 | |||
39 | /* | ||
40 | * routing header | ||
41 | */ | ||
42 | struct ipv6_rt_hdr { | ||
43 | __u8 nexthdr; | ||
44 | __u8 hdrlen; | ||
45 | __u8 type; | ||
46 | __u8 segments_left; | ||
47 | |||
48 | /* | ||
49 | * type specific data | ||
50 | * variable length field | ||
51 | */ | ||
52 | }; | ||
53 | |||
54 | |||
55 | struct ipv6_opt_hdr { | ||
56 | __u8 nexthdr; | ||
57 | __u8 hdrlen; | ||
58 | /* | ||
59 | * TLV encoded option data follows. | ||
60 | */ | ||
61 | } __attribute__((packed)); /* required for some archs */ | ||
62 | |||
63 | #define ipv6_destopt_hdr ipv6_opt_hdr | ||
64 | #define ipv6_hopopt_hdr ipv6_opt_hdr | ||
65 | |||
66 | #ifdef __KERNEL__ | ||
67 | #define ipv6_optlen(p) (((p)->hdrlen+1) << 3) | 6 | #define ipv6_optlen(p) (((p)->hdrlen+1) << 3) |
68 | #endif | ||
69 | |||
70 | /* | ||
71 | * routing header type 0 (used in cmsghdr struct) | ||
72 | */ | ||
73 | |||
74 | struct rt0_hdr { | ||
75 | struct ipv6_rt_hdr rt_hdr; | ||
76 | __u32 reserved; | ||
77 | struct in6_addr addr[0]; | ||
78 | |||
79 | #define rt0_type rt_hdr.type | ||
80 | }; | ||
81 | |||
82 | /* | ||
83 | * routing header type 2 | ||
84 | */ | ||
85 | |||
86 | struct rt2_hdr { | ||
87 | struct ipv6_rt_hdr rt_hdr; | ||
88 | __u32 reserved; | ||
89 | struct in6_addr addr; | ||
90 | |||
91 | #define rt2_type rt_hdr.type | ||
92 | }; | ||
93 | |||
94 | /* | ||
95 | * home address option in destination options header | ||
96 | */ | ||
97 | |||
98 | struct ipv6_destopt_hao { | ||
99 | __u8 type; | ||
100 | __u8 length; | ||
101 | struct in6_addr addr; | ||
102 | } __attribute__((packed)); | ||
103 | |||
104 | /* | ||
105 | * IPv6 fixed header | ||
106 | * | ||
107 | * BEWARE, it is incorrect. The first 4 bits of flow_lbl | ||
108 | * are glued to priority now, forming "class". | ||
109 | */ | ||
110 | |||
111 | struct ipv6hdr { | ||
112 | #if defined(__LITTLE_ENDIAN_BITFIELD) | ||
113 | __u8 priority:4, | ||
114 | version:4; | ||
115 | #elif defined(__BIG_ENDIAN_BITFIELD) | ||
116 | __u8 version:4, | ||
117 | priority:4; | ||
118 | #else | ||
119 | #error "Please fix <asm/byteorder.h>" | ||
120 | #endif | ||
121 | __u8 flow_lbl[3]; | ||
122 | |||
123 | __be16 payload_len; | ||
124 | __u8 nexthdr; | ||
125 | __u8 hop_limit; | ||
126 | |||
127 | struct in6_addr saddr; | ||
128 | struct in6_addr daddr; | ||
129 | }; | ||
130 | |||
131 | #ifdef __KERNEL__ | ||
132 | /* | 7 | /* |
133 | * This structure contains configuration options per IPv6 link. | 8 | * This structure contains configuration options per IPv6 link. |
134 | */ | 9 | */ |
@@ -180,43 +55,6 @@ struct ipv6_params { | |||
180 | __s32 autoconf; | 55 | __s32 autoconf; |
181 | }; | 56 | }; |
182 | extern struct ipv6_params ipv6_defaults; | 57 | extern struct ipv6_params ipv6_defaults; |
183 | #endif | ||
184 | |||
185 | /* index values for the variables in ipv6_devconf */ | ||
186 | enum { | ||
187 | DEVCONF_FORWARDING = 0, | ||
188 | DEVCONF_HOPLIMIT, | ||
189 | DEVCONF_MTU6, | ||
190 | DEVCONF_ACCEPT_RA, | ||
191 | DEVCONF_ACCEPT_REDIRECTS, | ||
192 | DEVCONF_AUTOCONF, | ||
193 | DEVCONF_DAD_TRANSMITS, | ||
194 | DEVCONF_RTR_SOLICITS, | ||
195 | DEVCONF_RTR_SOLICIT_INTERVAL, | ||
196 | DEVCONF_RTR_SOLICIT_DELAY, | ||
197 | DEVCONF_USE_TEMPADDR, | ||
198 | DEVCONF_TEMP_VALID_LFT, | ||
199 | DEVCONF_TEMP_PREFERED_LFT, | ||
200 | DEVCONF_REGEN_MAX_RETRY, | ||
201 | DEVCONF_MAX_DESYNC_FACTOR, | ||
202 | DEVCONF_MAX_ADDRESSES, | ||
203 | DEVCONF_FORCE_MLD_VERSION, | ||
204 | DEVCONF_ACCEPT_RA_DEFRTR, | ||
205 | DEVCONF_ACCEPT_RA_PINFO, | ||
206 | DEVCONF_ACCEPT_RA_RTR_PREF, | ||
207 | DEVCONF_RTR_PROBE_INTERVAL, | ||
208 | DEVCONF_ACCEPT_RA_RT_INFO_MAX_PLEN, | ||
209 | DEVCONF_PROXY_NDP, | ||
210 | DEVCONF_OPTIMISTIC_DAD, | ||
211 | DEVCONF_ACCEPT_SOURCE_ROUTE, | ||
212 | DEVCONF_MC_FORWARDING, | ||
213 | DEVCONF_DISABLE_IPV6, | ||
214 | DEVCONF_ACCEPT_DAD, | ||
215 | DEVCONF_FORCE_TLLAO, | ||
216 | DEVCONF_MAX | ||
217 | }; | ||
218 | |||
219 | #ifdef __KERNEL__ | ||
220 | #include <linux/icmpv6.h> | 58 | #include <linux/icmpv6.h> |
221 | #include <linux/tcp.h> | 59 | #include <linux/tcp.h> |
222 | #include <linux/udp.h> | 60 | #include <linux/udp.h> |
@@ -541,6 +379,4 @@ static inline struct raw6_sock *raw6_sk(const struct sock *sk) | |||
541 | (ipv6_addr_equal(&inet6_twsk(__sk)->tw_v6_rcv_saddr, (__daddr))) && \ | 379 | (ipv6_addr_equal(&inet6_twsk(__sk)->tw_v6_rcv_saddr, (__daddr))) && \ |
542 | (!((__sk)->sk_bound_dev_if) || ((__sk)->sk_bound_dev_if == (__dif)))) | 380 | (!((__sk)->sk_bound_dev_if) || ((__sk)->sk_bound_dev_if == (__dif)))) |
543 | 381 | ||
544 | #endif /* __KERNEL__ */ | ||
545 | |||
546 | #endif /* _IPV6_H */ | 382 | #endif /* _IPV6_H */ |