/include/linux/netfilter/xt_statistic.h

https://bitbucket.org/cyanogenmod/android_kernel_asus_tf300t · C Header · 36 lines · 30 code · 6 blank · 0 comment · 0 complexity · 8322099b59ec3ec8ee09b241dadc8abf MD5 · raw file

  1. #ifndef _XT_STATISTIC_H
  2. #define _XT_STATISTIC_H
  3. #include <linux/types.h>
  4. enum xt_statistic_mode {
  5. XT_STATISTIC_MODE_RANDOM,
  6. XT_STATISTIC_MODE_NTH,
  7. __XT_STATISTIC_MODE_MAX
  8. };
  9. #define XT_STATISTIC_MODE_MAX (__XT_STATISTIC_MODE_MAX - 1)
  10. enum xt_statistic_flags {
  11. XT_STATISTIC_INVERT = 0x1,
  12. };
  13. #define XT_STATISTIC_MASK 0x1
  14. struct xt_statistic_priv;
  15. struct xt_statistic_info {
  16. __u16 mode;
  17. __u16 flags;
  18. union {
  19. struct {
  20. __u32 probability;
  21. } random;
  22. struct {
  23. __u32 every;
  24. __u32 packet;
  25. __u32 count; /* unused */
  26. } nth;
  27. } u;
  28. struct xt_statistic_priv *master __attribute__((aligned(8)));
  29. };
  30. #endif /* _XT_STATISTIC_H */