hc
2023-12-08 01573e231f18eb2d99162747186f59511f56b64d
kernel/include/linux/ipv6.h
....@@ -3,7 +3,6 @@
33 #define _IPV6_H
44
55 #include <uapi/linux/ipv6.h>
6
-#include <uapi/linux/icmpv6.h>
76 #include <linux/android_kabi.h>
87
98 #define ipv6_optlen(p) (((p)->hdrlen+1) << 3)
....@@ -53,7 +52,7 @@
5352 __s32 use_optimistic;
5453 #endif
5554 #ifdef CONFIG_IPV6_MROUTE
56
- __s32 mc_forwarding;
55
+ atomic_t mc_forwarding;
5756 #endif
5857 __s32 disable_ipv6;
5958 __s32 drop_unicast_in_l2_multicast;
....@@ -77,6 +76,7 @@
7776 __u32 addr_gen_mode;
7877 __s32 disable_policy;
7978 __s32 ndisc_tclass;
79
+ __s32 rpl_seg_enabled;
8080
8181 struct ctl_table_header *sysctl_header;
8282
....@@ -109,6 +109,12 @@
109109 static inline struct ipv6hdr *ipipv6_hdr(const struct sk_buff *skb)
110110 {
111111 return (struct ipv6hdr *)skb_transport_header(skb);
112
+}
113
+
114
+static inline unsigned int ipv6_transport_len(const struct sk_buff *skb)
115
+{
116
+ return ntohs(ipv6_hdr(skb)->payload_len) + sizeof(struct ipv6hdr) -
117
+ skb_network_header_len(skb);
112118 }
113119
114120 /*
....@@ -177,17 +183,6 @@
177183 return 0;
178184 }
179185
180
-/* can not be used in TCP layer after tcp_v6_fill_cb */
181
-static inline bool inet6_exact_dif_match(struct net *net, struct sk_buff *skb)
182
-{
183
-#if defined(CONFIG_NET_L3_MASTER_DEV)
184
- if (!net->ipv4.sysctl_tcp_l3mdev_accept &&
185
- skb && ipv6_l3mdev_skb(IP6CB(skb)->flags))
186
- return true;
187
-#endif
188
- return false;
189
-}
190
-
191186 struct tcp6_request_sock {
192187 struct tcp_request_sock tcp6rsk_tcp;
193188 };
....@@ -223,7 +218,7 @@
223218
224219 /*
225220 * Packed in 16bits.
226
- * Omit one shift by by putting the signed field at MSB.
221
+ * Omit one shift by putting the signed field at MSB.
227222 */
228223 #if defined(__BIG_ENDIAN_BITFIELD)
229224 __s16 hop_limit:9;
....@@ -281,7 +276,10 @@
281276 */
282277 dontfrag:1,
283278 autoflowlabel:1,
284
- autoflowlabel_set:1;
279
+ autoflowlabel_set:1,
280
+ mc_all:1,
281
+ recverr_rfc4884:1,
282
+ rtalert_isolate:1;
285283 __u8 min_hopcount;
286284 __u8 tclass;
287285 __be32 rcv_flowinfo;
....@@ -340,17 +338,6 @@
340338 static inline struct raw6_sock *raw6_sk(const struct sock *sk)
341339 {
342340 return (struct raw6_sock *)sk;
343
-}
344
-
345
-static inline void inet_sk_copy_descendant(struct sock *sk_to,
346
- const struct sock *sk_from)
347
-{
348
- int ancestor_size = sizeof(struct inet_sock);
349
-
350
- if (sk_from->sk_family == PF_INET6)
351
- ancestor_size += sizeof(struct ipv6_pinfo);
352
-
353
- __inet_sk_copy_descendant(sk_to, sk_from, ancestor_size);
354341 }
355342
356343 #define __ipv6_only_sock(sk) (sk->sk_ipv6only)