diff options
Diffstat (limited to 'include/linux/igmp.h')
| -rw-r--r-- | include/linux/igmp.h | 38 |
1 files changed, 17 insertions, 21 deletions
diff --git a/include/linux/igmp.h b/include/linux/igmp.h index f510e7e382a8..f5a1a0db2e8e 100644 --- a/include/linux/igmp.h +++ b/include/linux/igmp.h | |||
| @@ -80,27 +80,6 @@ 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 | |||
| 104 | #define IGMP_HOST_MEMBERSHIP_QUERY 0x11 /* From RFC1112 */ | 83 | #define IGMP_HOST_MEMBERSHIP_QUERY 0x11 /* From RFC1112 */ |
| 105 | #define IGMP_HOST_MEMBERSHIP_REPORT 0x12 /* Ditto */ | 84 | #define IGMP_HOST_MEMBERSHIP_REPORT 0x12 /* Ditto */ |
| 106 | #define IGMP_DVMRP 0x13 /* DVMRP routing */ | 85 | #define IGMP_DVMRP 0x13 /* DVMRP routing */ |
| @@ -151,6 +130,23 @@ static inline struct igmpv3_query * | |||
| 151 | #include <linux/timer.h> | 130 | #include <linux/timer.h> |
| 152 | #include <linux/in.h> | 131 | #include <linux/in.h> |
| 153 | 132 | ||
| 133 | static inline struct igmphdr *igmp_hdr(const struct sk_buff *skb) | ||
| 134 | { | ||
| 135 | return (struct igmphdr *)skb_transport_header(skb); | ||
| 136 | } | ||
| 137 | |||
| 138 | static inline struct igmpv3_report * | ||
| 139 | igmpv3_report_hdr(const struct sk_buff *skb) | ||
| 140 | { | ||
| 141 | return (struct igmpv3_report *)skb_transport_header(skb); | ||
| 142 | } | ||
| 143 | |||
| 144 | static inline struct igmpv3_query * | ||
| 145 | igmpv3_query_hdr(const struct sk_buff *skb) | ||
| 146 | { | ||
| 147 | return (struct igmpv3_query *)skb_transport_header(skb); | ||
| 148 | } | ||
| 149 | |||
| 154 | extern int sysctl_igmp_max_memberships; | 150 | extern int sysctl_igmp_max_memberships; |
| 155 | extern int sysctl_igmp_max_msf; | 151 | extern int sysctl_igmp_max_msf; |
| 156 | 152 | ||
