diff options
Diffstat (limited to 'include/linux/igmp.h')
-rw-r--r-- | include/linux/igmp.h | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/include/linux/igmp.h b/include/linux/igmp.h index 9dbb525c5178..f510e7e382a8 100644 --- a/include/linux/igmp.h +++ b/include/linux/igmp.h | |||
@@ -80,6 +80,27 @@ struct igmpv3_query { | |||
80 | __be32 srcs[0]; | 80 | __be32 srcs[0]; |
81 | }; | 81 | }; |
82 | 82 | ||
83 | #ifdef __KERNEL__ | ||
84 | #include <linux/skbuff.h> | ||
85 | |||
86 | static inline struct igmphdr *igmp_hdr(const struct sk_buff *skb) | ||
87 | { | ||
88 | return (struct igmphdr *)skb_transport_header(skb); | ||
89 | } | ||
90 | |||
91 | static inline struct igmpv3_report * | ||
92 | igmpv3_report_hdr(const struct sk_buff *skb) | ||
93 | { | ||
94 | return (struct igmpv3_report *)skb_transport_header(skb); | ||
95 | } | ||
96 | |||
97 | static inline struct igmpv3_query * | ||
98 | igmpv3_query_hdr(const struct sk_buff *skb) | ||
99 | { | ||
100 | return (struct igmpv3_query *)skb_transport_header(skb); | ||
101 | } | ||
102 | #endif | ||
103 | |||
83 | #define IGMP_HOST_MEMBERSHIP_QUERY 0x11 /* From RFC1112 */ | 104 | #define IGMP_HOST_MEMBERSHIP_QUERY 0x11 /* From RFC1112 */ |
84 | #define IGMP_HOST_MEMBERSHIP_REPORT 0x12 /* Ditto */ | 105 | #define IGMP_HOST_MEMBERSHIP_REPORT 0x12 /* Ditto */ |
85 | #define IGMP_DVMRP 0x13 /* DVMRP routing */ | 106 | #define IGMP_DVMRP 0x13 /* DVMRP routing */ |
@@ -218,5 +239,7 @@ extern void ip_mc_up(struct in_device *); | |||
218 | extern void ip_mc_down(struct in_device *); | 239 | extern void ip_mc_down(struct in_device *); |
219 | extern void ip_mc_dec_group(struct in_device *in_dev, __be32 addr); | 240 | extern void ip_mc_dec_group(struct in_device *in_dev, __be32 addr); |
220 | extern void ip_mc_inc_group(struct in_device *in_dev, __be32 addr); | 241 | extern void ip_mc_inc_group(struct in_device *in_dev, __be32 addr); |
242 | extern void ip_mc_rejoin_group(struct ip_mc_list *im); | ||
243 | |||
221 | #endif | 244 | #endif |
222 | #endif | 245 | #endif |