tc_pedit.h 782 B

12345678910111213141516171819202122232425262728293031323334
  1. #ifndef __LINUX_TC_PED_H
  2. #define __LINUX_TC_PED_H
  3. #include <linux/types.h>
  4. #include <linux/pkt_cls.h>
  5. #define TCA_ACT_PEDIT 7
  6. enum {
  7. TCA_PEDIT_UNSPEC,
  8. TCA_PEDIT_TM,
  9. TCA_PEDIT_PARMS,
  10. __TCA_PEDIT_MAX
  11. };
  12. #define TCA_PEDIT_MAX (__TCA_PEDIT_MAX - 1)
  13. struct tc_pedit_key {
  14. __u32 mask; /* AND */
  15. __u32 val; /*XOR */
  16. __u32 off; /*offset */
  17. __u32 at;
  18. __u32 offmask;
  19. __u32 shift;
  20. };
  21. struct tc_pedit_sel {
  22. tc_gen;
  23. unsigned char nkeys;
  24. unsigned char flags;
  25. struct tc_pedit_key keys[0];
  26. };
  27. #define tc_pedit tc_pedit_sel
  28. #endif