summaryrefslogtreecommitdiff
path: root/include/linux/ipv6.h
diff options
context:
space:
mode:
authorEric Dumazet <edumazet@google.com>2023-09-12 16:01:59 +0000
committerDavid S. Miller <davem@davemloft.net>2023-09-15 10:33:46 +0100
commitb0adfba7ee770fef20b1b6d86706c28f7fccfb07 (patch)
tree4a7a9fe910c850fcc4492d034cf57d0db89c4ae2 /include/linux/ipv6.h
parentf2fa1c812c91e99d0317d1fc7d845e1e05f39716 (diff)
ipv6: lockless IPV6_UNICAST_HOPS implementation
Some np->hop_limit accesses are racy, when socket lock is not held. Add missing annotations and switch to full lockless implementation. Signed-off-by: Eric Dumazet <edumazet@google.com> Reviewed-by: David Ahern <dsahern@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/linux/ipv6.h')
-rw-r--r--include/linux/ipv6.h12
1 files changed, 1 insertions, 11 deletions
diff --git a/include/linux/ipv6.h b/include/linux/ipv6.h
index af8a771a053c..c2e087071384 100644
--- a/include/linux/ipv6.h
+++ b/include/linux/ipv6.h
@@ -213,17 +213,7 @@ struct ipv6_pinfo {
__be32 flow_label;
__u32 frag_size;
- /*
- * Packed in 16bits.
- * Omit one shift by putting the signed field at MSB.
- */
-#if defined(__BIG_ENDIAN_BITFIELD)
- __s16 hop_limit:9;
- __u16 __unused_1:7;
-#else
- __u16 __unused_1:7;
- __s16 hop_limit:9;
-#endif
+ s16 hop_limit;
#if defined(__BIG_ENDIAN_BITFIELD)
/* Packed in 16bits. */