diff options
author | Eugene Syromyatnikov <evgsyr@gmail.com> | 2023-05-10 19:58:37 +0200 |
---|---|---|
committer | Eugene Syromyatnikov <evgsyr@gmail.com> | 2023-05-10 20:08:00 +0200 |
commit | 83b7f0c841d64ad3d8f28fd73df4d0cc9268daad (patch) | |
tree | 3dce04e2109f84c52b7c4750b1d6f0964414eee5 /src/xlat/rtnl_tca_root_flags.in | |
parent | b30e9d446019b31c2a74b2addaa5b591e8947d61 (diff) | |
download | strace-esyr/tcamsg-fixes.tar.gz |
rtnl_tc_action: fix tcamsg attribute decoderesyr/tcamsg-fixes
It used the wrong attribute table initially.
An example of an actual usage:
tc actions add action simple sdata "foobar" index 1
* src/xlat/rtnl_tca_root_attrs.in: New file.
* src/xlat/rtnl_tca_root_flags.in: Likewise.
* src/rtnl_tc_action.c: Include "xlat/rtnl_tca_root_flags.h"
and "xlat/rtnl_tca_root_attrs.h".
(tcamsg_nla_decoders): Rename to...
(tca_act_nla_decoders): ...this.
(decode_tca_action, decode_tca_root_act_tab, decode_tca_root_act_flags,
decode_tca_msecs): New functions.
(tcamsg_nla_decoders): New decoder table.
(decode_tcamsg): Use rtnl_tca_root_attrs and "TCA_ROOT_???" as xlat
and dflt arguments in the decode_nlattr call. respectively.
* tests/.gitignore: Add nlattr_tcamsg-Xabbrev, nlattr_tcamsg-Xraw,
and nlattr_tcamsg-Xverbose.
* tests/pure_executables.list: Likewise.
* tests/gen_tests.in (nlattr_tcamsg-Xabbrev, nlattr_tcamsg-Xraw,
nlattr_tcamsg-Xverbose): New tests.
* tests/nlattr_tcamsg-Xabbrev.c: New file.
* tests/nlattr_tcamsg-Xraw.c: Likewise.
* tests/nlattr_tcamsg-Xverbose.c: Likewise.
* tests/nlattr_tcamsg.c: Update the expected output.
Diffstat (limited to 'src/xlat/rtnl_tca_root_flags.in')
-rw-r--r-- | src/xlat/rtnl_tca_root_flags.in | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/xlat/rtnl_tca_root_flags.in b/src/xlat/rtnl_tca_root_flags.in new file mode 100644 index 000000000..f45a0b3d8 --- /dev/null +++ b/src/xlat/rtnl_tca_root_flags.in @@ -0,0 +1,2 @@ +TCA_ACT_FLAG_LARGE_DUMP_ON (1 << 0) +TCA_ACT_FLAG_TERSE_DUMP (1 << 1) |