X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=doc%2Fguides%2Ftestpmd_app_ug%2Ftestpmd_funcs.rst;h=c68a742ebdeff723840ba685f61788819e3d84c3;hb=739e045bf2567142cb398888437e459db45fc7b4;hp=1da60faffe9bf068e8fcb6a8d5ee2446fa237336;hpb=0322272c9fd39e1a5942c73232d43d3ebeeff7b1;p=dpdk.git diff --git a/doc/guides/testpmd_app_ug/testpmd_funcs.rst b/doc/guides/testpmd_app_ug/testpmd_funcs.rst index 1da60faffe..c68a742ebd 100644 --- a/doc/guides/testpmd_app_ug/testpmd_funcs.rst +++ b/doc/guides/testpmd_app_ug/testpmd_funcs.rst @@ -545,6 +545,25 @@ Dumps the log level for all the dpdk modules:: testpmd> dump_log_types +show (raw_encap|raw_decap) +~~~~~~~~~~~~~~~~~~~~~~~~~~ + +Display content of raw_encap/raw_decap buffers in hex:: + + testpmd> show + testpmd> show all + +For example:: + + testpmd> show raw_encap 6 + + index: 6 at [0x1c565b0], len=50 + 00000000: 00 00 00 00 00 00 16 26 36 46 56 66 08 00 45 00 | .......&6FVf..E. + 00000010: 00 00 00 00 00 00 00 11 00 00 C0 A8 01 06 C0 A8 | ................ + 00000020: 03 06 00 00 00 FA 00 00 00 00 08 00 00 00 00 00 | ................ + 00000030: 06 00 | .. + + Configuration Functions ----------------------- @@ -1834,12 +1853,22 @@ Config Raw Encapsulation Configure the raw data to be used when encapsulating a packet by rte_flow_action_raw_encap:: + set raw_encap {index} {item} [/ {item} [...]] / end_set + +There are multiple global buffers for ``raw_encap``, this command will set one +internal buffer index by ``{index}``. +If there is no ``{index}`` specified:: + set raw_encap {item} [/ {item} [...]] / end_set -This command will set an internal buffer inside testpmd, any following flow rule -using the action raw_encap will use the last configuration set. -To have a different encapsulation header, this command must be called before the -flow rule creation. +the default index ``0`` is used. +In order to use different encapsulating header, ``index`` must be specified +during the flow rule creation:: + + testpmd> flow create 0 egress pattern eth / ipv4 / end actions + raw_encap index 2 / end + +Otherwise the default index ``0`` is used. Config Raw Decapsulation ~~~~~~~~~~~~~~~~~~~~~~~~ @@ -1847,10 +1876,22 @@ Config Raw Decapsulation Configure the raw data to be used when decapsulating a packet by rte_flow_action_raw_decap:: + set raw_decap {index} {item} [/ {item} [...]] / end_set + +There are multiple global buffers for ``raw_decap``, this command will set +one internal buffer index by ``{index}``. +If there is no ``{index}`` specified:: + set raw_decap {item} [/ {item} [...]] / end_set -This command will set an internal buffer inside testpmd, any following flow rule -using the action raw_decap will use the last configuration set. +the default index ``0`` is used. +In order to use different decapsulating header, ``index`` must be specified +during the flow rule creation:: + + testpmd> flow create 0 egress pattern eth / ipv4 / end actions + raw_encap index 3 / end + +Otherwise the default index ``0`` is used. Port Functions -------------- @@ -4670,11 +4711,11 @@ Raw encapsulation configuration can be set by the following commands Eecapsulating VxLAN:: - testpmd> set raw_encap eth src is 10:11:22:33:44:55 / vlan tci is 1 + testpmd> set raw_encap 4 eth src is 10:11:22:33:44:55 / vlan tci is 1 inner_type is 0x0800 / ipv4 / udp dst is 4789 / vxlan vni is 2 / end_set testpmd> flow create 0 egress pattern eth / ipv4 / end actions - raw_encap / end + raw_encap index 4 / end Sample Raw decapsulation rule ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~