diff options
-rw-r--r-- | include/net/ip.h | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/include/net/ip.h b/include/net/ip.h index d603cd329c4e..9fa9416d14d7 100644 --- a/include/net/ip.h +++ b/include/net/ip.h | |||
@@ -236,6 +236,11 @@ extern void ipfrag_init(void); | |||
236 | 236 | ||
237 | extern void ip_static_sysctl_init(void); | 237 | extern void ip_static_sysctl_init(void); |
238 | 238 | ||
239 | static inline bool ip_is_fragment(const struct iphdr *iph) | ||
240 | { | ||
241 | return (iph->frag_off & htons(IP_MF | IP_OFFSET)) != 0; | ||
242 | } | ||
243 | |||
239 | #ifdef CONFIG_INET | 244 | #ifdef CONFIG_INET |
240 | #include <net/dst.h> | 245 | #include <net/dst.h> |
241 | 246 | ||
@@ -250,11 +255,6 @@ int ip_decrease_ttl(struct iphdr *iph) | |||
250 | return --iph->ttl; | 255 | return --iph->ttl; |
251 | } | 256 | } |
252 | 257 | ||
253 | static inline bool ip_is_fragment(const struct iphdr *iph) | ||
254 | { | ||
255 | return (iph->frag_off & htons(IP_MF | IP_OFFSET)) != 0; | ||
256 | } | ||
257 | |||
258 | static inline | 258 | static inline |
259 | int ip_dont_fragment(struct sock *sk, struct dst_entry *dst) | 259 | int ip_dont_fragment(struct sock *sk, struct dst_entry *dst) |
260 | { | 260 | { |