netfilter_ipv4.h 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. /* IPv4-specific defines for netfilter.
  2. * (C)1998 Rusty Russell -- This code is GPL.
  3. */
  4. #ifndef __LINUX_IP_NETFILTER_H
  5. #define __LINUX_IP_NETFILTER_H
  6. #include <uapi/linux/netfilter_ipv4.h>
  7. /* Extra routing may needed on local out, as the QUEUE target never returns
  8. * control to the table.
  9. */
  10. struct ip_rt_info {
  11. __be32 daddr;
  12. __be32 saddr;
  13. u_int8_t tos;
  14. u_int32_t mark;
  15. };
  16. int ip_route_me_harder(struct net *net, struct sock *sk, struct sk_buff *skb, unsigned addr_type);
  17. struct nf_queue_entry;
  18. #ifdef CONFIG_INET
  19. __sum16 nf_ip_checksum(struct sk_buff *skb, unsigned int hook,
  20. unsigned int dataoff, u_int8_t protocol);
  21. int nf_ip_route(struct net *net, struct dst_entry **dst, struct flowi *fl,
  22. bool strict);
  23. #else
  24. static inline __sum16 nf_ip_checksum(struct sk_buff *skb, unsigned int hook,
  25. unsigned int dataoff, u_int8_t protocol)
  26. {
  27. return 0;
  28. }
  29. static inline int nf_ip_route(struct net *net, struct dst_entry **dst,
  30. struct flowi *fl, bool strict)
  31. {
  32. return -EOPNOTSUPP;
  33. }
  34. #endif /* CONFIG_INET */
  35. #endif /*__LINUX_IP_NETFILTER_H*/