* meter_mark action not working with NVIDIA Cx6-Dx
@ 2023-02-27 6:50 Taha Sami
2023-02-28 2:18 ` Alexander Kozyrev
0 siblings, 1 reply; 2+ messages in thread
From: Taha Sami @ 2023-02-27 6:50 UTC (permalink / raw)
To: users, akozyrev, suanmingm; +Cc: asafp
[-- Attachment #1: Type: text/plain, Size: 5007 bytes --]
Hello,
We are trying to test the meter mark feature with the testpmd but we are observing some unusual results. We are trying to send different color packets to different queues but we are not seeing the desired results
Supporting INFO
MT2892 Family [ConnectX-6 Dx]
Driver: mlx5_core
Version: 5.8-1.1.2
Firmware-version: 22.35.2000 (MT_0000000436)
dpdk- 22.11
Here are our test steps
Step 1: Configuring meter_mark in testpmd:
sudo ./build/app/dpdk-testpmd -l 0-3 -n 4 -a 0000:4:00.0,dv_flow_en=2 --file-prefix ts -- -i --disable-rss --txq=9 –rxq=9
port stop 0
port configure
flow configure 0 queues_number 9 queues_size 256 meters_number 1
Pattern template configure
flow pattern_template 0 create pattern_template_id 2 relaxed true ingress template eth dst is 00:16:3e:31:15:c3 / end
flow pattern_template 0 create pattern_template_id 4 relaxed true ingress template meter color is green / end
flow pattern_template 0 create pattern_template_id 5 relaxed true ingress template meter color is yellow / end
flow pattern_template 0 create pattern_template_id 6 relaxed true ingress template meter color is red / end
Action Template configure
flow actions_template 0 create actions_template_id 1 template jump group 1 / end mask jump group 1 / end
flow actions_template 0 create actions_template_id 2 template meter_mark mtr_profile 0 mtr_color_mode 1
mtr_init_color green mtr_state 1 / jump group 2 / end mask meter_mark mtr_profile 0 mtr_color_mode 1 mtr_init_color green mtr_state 1 / jump group 2 / end
flow actions_template 0 create actions_template_id 4 template queue index 2 / end mask queue index 2 / end
flow actions_template 0 create actions_template_id 5 template queue index 6 / end mask queue index 6 / end
flow actions_template 0 create actions_template_id 6 template drop / end mask drop / end
Template Table creation
flow template_table 0 create table_id 1 group 0 ingress rules_number 10 pattern_template 2 actions_template 1
flow template_table 0 create table_id 2 group 1 ingress rules_number 10 pattern_template 2 actions_template 2
flow template_table 0 create table_id 4 group 2 ingress rules_number 10 pattern_template 4 actions_template 4
flow template_table 0 create table_id 5 group 2 ingress rules_number 10 pattern_template 5 actions_template 5
flow template_table 0 create table_id 6 group 2 ingress rules_number 10 pattern_template 6 actions_template 6
port start 0
profile creation for meter mark
add port meter profile trtcm_rfc2698 0 0 120 250 20 3000 0
Flow queue creation
flow queue 0 create 0 template_table 1 pattern_template 0 actions_template 0 postpone 0 pattern eth dst is 00:16:3e:31:15:c3 / end actions drop / end
flow queue 0 create 0 template_table 2 pattern_template 0 actions_template 0 postpone 0 pattern eth dst is 00:16:3e:31:15:c3 / end actions drop / end
flow queue 0 create 0 template_table 4 pattern_template 0 actions_template 0 postpone 0 pattern meter color is green / end actions drop / end
flow queue 0 create 0 template_table 5 pattern_template 0 actions_template 0 postpone 0 pattern meter color is yellow / end actions drop / end
flow queue 0 create 0 template_table 6 pattern_template 0 actions_template 0 postpone 0 pattern meter color is red / end actions drop / end
Push/Pull operation
flow push 0 queue 0
Queue #0 operations pushed
flow pull 0 queue 0
Queue #0 pulled 2 operations (0 failed, 2 succeeded)
After pulling the flow rules it was observed that only 2 rules were successfully pulled
initially, after sending 2000 packets of 64 bytes from pktgen we saw only 1 packet received on queue 2 even though only 2 rules were successfully pushed and pulled from the nic
------- Forward Stats for RX Port= 0/Queue= 2 -> TX Port= 0/Queue= 2 -------
RX-packets: 1 TX-packets: 1 TX-dropped: 0
---------------------- Forward statistics for port 0 ----------------------
RX-packets: 1 RX-dropped: 0 RX-total: 1
TX-packets: 1 TX-dropped: 0 TX-total: 1
----------------------------------------------------------------------------
+++++++++++++++ Accumulated forward statistics for all ports+++++++++++++++
RX-packets: 1 RX-dropped: 0 RX-total: 1
TX-packets: 1 TX-dropped: 0 TX-total: 1
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
after again sending 2000 packets of 64 bytes
---------------------- Forward statistics for port 0 ----------------------
RX-packets: 0 RX-dropped: 0 RX-total: 0
TX-packets: 0 TX-dropped: 0 TX-total: 0
----------------------------------------------------------------------------
+++++++++++++++ Accumulated forward statistics for all ports+++++++++++++++
RX-packets: 0 RX-dropped: 0 RX-total: 0
TX-packets: 0 TX-dropped: 0 TX-total: 0
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Regards,
Taha
[-- Attachment #2: Type: text/html, Size: 9052 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
* RE: meter_mark action not working with NVIDIA Cx6-Dx
2023-02-27 6:50 meter_mark action not working with NVIDIA Cx6-Dx Taha Sami
@ 2023-02-28 2:18 ` Alexander Kozyrev
0 siblings, 0 replies; 2+ messages in thread
From: Alexander Kozyrev @ 2023-02-28 2:18 UTC (permalink / raw)
To: Taha Sami, users; +Cc: Asaf Penso, Suanming Mou
[-- Attachment #1: Type: text/plain, Size: 8033 bytes --]
Hi Taha, I don't think your usage of the new template flow API is correct.
First, action list in flow rules must match the action list in the template.
Second, you need specify different priorities for the rules in the same group.
Please see the corrected flows below to get an idea how it should be organized.
P.S. pull returns only completed operations, try again later if you expect more.
port stop 0
flow configure 0 queues_number 9 queues_size 256 meters_number 1
add port meter profile trtcm_rfc2698 0 0 120 250 20 3000 0
flow pattern_template 0 create pattern_template_id 2 relaxed true ingress template eth / end
flow pattern_template 0 create pattern_template_id 4 relaxed true ingress template meter color mask all / end
flow actions_template 0 create actions_template_id 1 template jump group 1 / end mask jump group 1 / end
flow actions_template 0 create actions_template_id 2 template meter_mark / jump group 2 / end mask meter_mark / jump group 2 / end
flow actions_template 0 create actions_template_id 4 template queue index 2 / end mask queue index 2 / end
flow actions_template 0 create actions_template_id 5 template queue index 6 / end mask queue index 6 / end
flow actions_template 0 create actions_template_id 6 template drop / end mask drop / end
flow template_table 0 create table_id 1 group 0 ingress rules_number 10 pattern_template 2 actions_template 1
flow template_table 0 create table_id 2 group 1 ingress rules_number 10 pattern_template 2 actions_template 2
flow template_table 0 create table_id 4 group 2 priority 0 ingress rules_number 10 pattern_template 4 actions_template 4
flow template_table 0 create table_id 5 group 2 priority 1 ingress rules_number 10 pattern_template 4 actions_template 5
flow template_table 0 create table_id 6 group 2 priority 2 ingress rules_number 10 pattern_template 4 actions_template 6
port start 0
flow queue 0 create 0 template_table 1 pattern_template 0 actions_template 0 postpone 0 pattern eth / end actions jump group 1 / end
flow queue 0 create 0 template_table 2 pattern_template 0 actions_template 0 postpone 0 pattern eth / end actions meter_mark mtr_profile 0 mtr_init_color green mtr_color_mode 1 mtr_state 1 / jump group 2 / end
flow queue 0 create 0 template_table 4 pattern_template 0 actions_template 0 postpone 0 pattern meter color is green color mask all / end actions queue index 2 / end
flow queue 0 create 0 template_table 5 pattern_template 0 actions_template 0 postpone 0 pattern meter color is yellow color mask all / end actions queue index 6 / end
flow queue 0 create 0 template_table 6 pattern_template 0 actions_template 0 postpone 0 pattern meter color is red color mask all / end actions drop / end
Regards,
Alex
From: Taha Sami <taha.sami@dreambigsemi.com>
Sent: February 27, 2023 01:50
To: users@dpdk.org; Alexander Kozyrev <akozyrev@nvidia.com>; Suanming Mou <suanmingm@nvidia.com>
Cc: Asaf Penso <asafp@nvidia.com>
Subject: meter_mark action not working with NVIDIA Cx6-Dx
Hello,
We are trying to test the meter mark feature with the testpmd but we are observing some unusual results. We are trying to send different color packets to different queues but we are not seeing the desired results
Supporting INFO
MT2892 Family [ConnectX-6 Dx]
Driver: mlx5_core
Version: 5.8-1.1.2
Firmware-version: 22.35.2000 (MT_0000000436)
dpdk- 22.11
Here are our test steps
Step 1: Configuring meter_mark in testpmd:
sudo ./build/app/dpdk-testpmd -l 0-3 -n 4 -a 0000:4:00.0,dv_flow_en=2 --file-prefix ts -- -i --disable-rss --txq=9 -rxq=9
port stop 0
port configure
flow configure 0 queues_number 9 queues_size 256 meters_number 1
Pattern template configure
flow pattern_template 0 create pattern_template_id 2 relaxed true ingress template eth dst is 00:16:3e:31:15:c3 / end
flow pattern_template 0 create pattern_template_id 4 relaxed true ingress template meter color is green / end
flow pattern_template 0 create pattern_template_id 5 relaxed true ingress template meter color is yellow / end
flow pattern_template 0 create pattern_template_id 6 relaxed true ingress template meter color is red / end
Action Template configure
flow actions_template 0 create actions_template_id 1 template jump group 1 / end mask jump group 1 / end
flow actions_template 0 create actions_template_id 2 template meter_mark mtr_profile 0 mtr_color_mode 1
mtr_init_color green mtr_state 1 / jump group 2 / end mask meter_mark mtr_profile 0 mtr_color_mode 1 mtr_init_color green mtr_state 1 / jump group 2 / end
flow actions_template 0 create actions_template_id 4 template queue index 2 / end mask queue index 2 / end
flow actions_template 0 create actions_template_id 5 template queue index 6 / end mask queue index 6 / end
flow actions_template 0 create actions_template_id 6 template drop / end mask drop / end
Template Table creation
flow template_table 0 create table_id 1 group 0 ingress rules_number 10 pattern_template 2 actions_template 1
flow template_table 0 create table_id 2 group 1 ingress rules_number 10 pattern_template 2 actions_template 2
flow template_table 0 create table_id 4 group 2 ingress rules_number 10 pattern_template 4 actions_template 4
flow template_table 0 create table_id 5 group 2 ingress rules_number 10 pattern_template 5 actions_template 5
flow template_table 0 create table_id 6 group 2 ingress rules_number 10 pattern_template 6 actions_template 6
port start 0
profile creation for meter mark
add port meter profile trtcm_rfc2698 0 0 120 250 20 3000 0
Flow queue creation
flow queue 0 create 0 template_table 1 pattern_template 0 actions_template 0 postpone 0 pattern eth dst is 00:16:3e:31:15:c3 / end actions drop / end
flow queue 0 create 0 template_table 2 pattern_template 0 actions_template 0 postpone 0 pattern eth dst is 00:16:3e:31:15:c3 / end actions drop / end
flow queue 0 create 0 template_table 4 pattern_template 0 actions_template 0 postpone 0 pattern meter color is green / end actions drop / end
flow queue 0 create 0 template_table 5 pattern_template 0 actions_template 0 postpone 0 pattern meter color is yellow / end actions drop / end
flow queue 0 create 0 template_table 6 pattern_template 0 actions_template 0 postpone 0 pattern meter color is red / end actions drop / end
Push/Pull operation
flow push 0 queue 0
Queue #0 operations pushed
flow pull 0 queue 0
Queue #0 pulled 2 operations (0 failed, 2 succeeded)
After pulling the flow rules it was observed that only 2 rules were successfully pulled
initially, after sending 2000 packets of 64 bytes from pktgen we saw only 1 packet received on queue 2 even though only 2 rules were successfully pushed and pulled from the nic
------- Forward Stats for RX Port= 0/Queue= 2 -> TX Port= 0/Queue= 2 -------
RX-packets: 1 TX-packets: 1 TX-dropped: 0
---------------------- Forward statistics for port 0 ----------------------
RX-packets: 1 RX-dropped: 0 RX-total: 1
TX-packets: 1 TX-dropped: 0 TX-total: 1
----------------------------------------------------------------------------
+++++++++++++++ Accumulated forward statistics for all ports+++++++++++++++
RX-packets: 1 RX-dropped: 0 RX-total: 1
TX-packets: 1 TX-dropped: 0 TX-total: 1
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
after again sending 2000 packets of 64 bytes
---------------------- Forward statistics for port 0 ----------------------
RX-packets: 0 RX-dropped: 0 RX-total: 0
TX-packets: 0 TX-dropped: 0 TX-total: 0
----------------------------------------------------------------------------
+++++++++++++++ Accumulated forward statistics for all ports+++++++++++++++
RX-packets: 0 RX-dropped: 0 RX-total: 0
TX-packets: 0 TX-dropped: 0 TX-total: 0
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Regards,
Taha
[-- Attachment #2: Type: text/html, Size: 22038 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-02-28 9:00 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-02-27 6:50 meter_mark action not working with NVIDIA Cx6-Dx Taha Sami
2023-02-28 2:18 ` Alexander Kozyrev
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).