DPDK patches and discussions
 help / color / mirror / Atom feed
From: "Peng, Yuan" <yuan.peng@intel.com>
To: "Zhao1, Wei" <wei.zhao1@intel.com>, "dev@dpdk.org" <dev@dpdk.org>
Subject: Re: [dpdk-dev] [PATCH v8 0/2] net/i40e: API to configure queue regions	for RSS
Date: Wed, 11 Oct 2017 11:29:53 +0000	[thread overview]
Message-ID: <67D543A150B29E4CAAE53918F64EDAEA3744A0DA@SHSMSX103.ccr.corp.intel.com> (raw)
In-Reply-To: <1507712133-31875-1-git-send-email-wei.zhao1@intel.com>

Tested-by: Peng Yuan <yuan.peng@intel.com>

- Tested Branch: dpdk-master
- Tested Commit: 7a8889324654c9e39f9e18097ccc74d6ff2588cf
- OS: 4.5.5-300.fc24.x86_64
- GCC: gcc (GCC) 5.3.1 20151207 (Red Hat 5.3.1-2)
- CPU: Intel(R) Xeon(R) CPU E5-2699 v4 @ 2.20GHz
- NIC: Intel Corporation Device Fortville [8086:1572]
- Default x86_64-native-linuxapp-gcc configuration
- Prerequisites:
- Total 3 cases, 3 passed, 0 failed

- Prerequisites command / instruction:
1. Hardware:
   Fortville

2. software:
   dpdk: http://dpdk.org/git/dpdk
   scapy: http://www.secdev.org/projects/scapy/

3. bind the port to dpdk driver::

    ./usertools/dpdk-devbind.py -b igb_uio 05:00.0

   the mac address of 05:00.0 is 00:00:00:00:01:00

4. start the testpmd::

    ./x86_64-native-linuxapp-gcc/app/testpmd -c 1ffff -n 4 -- -i --rxq=16 --txq=16
    testpmd> port config all rss all
    testpmd> set fwd rxonly
    testpmd> set verbose 1
    testpmd> start

- Cases:

Test case 1: different pctype packet can enter the expected queue region
========================================================================

1. Set queue region on a port::

    testpmd> set port 0 queue-region region_id 0 queue_start_index 1 queue_num 1
    testpmd> set port 0 queue-region region_id 1 queue_start_index 3 queue_num 2
    testpmd> set port 0 queue-region region_id 2 queue_start_index 6 queue_num 2
    testpmd> set port 0 queue-region region_id 3 queue_start_index 8 queue_num 2
    testpmd> set port 0 queue-region region_id 4 queue_start_index 11 queue_num 4
    testpmd> set port 0 queue-region region_id 5 queue_start_index 15 queue_num 1

2. Set the mapping of flowtype to region index on a port::

    testpmd> set port 0 queue-region region_id 0 flowtype 31
    testpmd> set port 0 queue-region region_id 1 flowtype 32
    testpmd> set port 0 queue-region region_id 2 flowtype 33
    testpmd> set port 0 queue-region region_id 3 flowtype 34
    testpmd> set port 0 queue-region region_id 4 flowtype 35
    testpmd> set port 0 queue-region region_id 5 flowtype 45
    testpmd> set port 0 queue-region region_id 2 flowtype 41
    testpmd> set port 0 queue-region flush on

3. send packet::

    pkt1 = Ether(dst="00:00:00:00:01:00", src="00:02:00:00:00:01")/IP(src="192.168.0.1", dst="192.168.0.2")/UDP(sport=23,dport=24)/Raw('x'*20)
    pkt2 = Ether(dst="00:00:00:00:01:00", src="00:02:00:00:00:01")/IP(src="192.168.0.1", dst="192.168.0.2")/TCP(sport=33,dport=34,flags="S")/Raw('x'*20)
    pkt3 = Ether(dst="00:00:00:00:01:00", src="00:02:00:00:00:01")/IP(src="192.168.0.1", dst="192.168.0.2")/TCP(sport=33,dport=34,flags="PA")/Raw('x' * 20)
    pkt4 = Ether(dst="00:00:00:00:01:00", src="00:02:00:00:00:01")/IP(src="192.168.0.1", dst="192.168.0.2")/SCTP(sport=44,dport=45,tag=1)/SCTPChunkData(data="X" * 20)
    pkt5 = Ether(dst="00:00:00:00:01:00", src="00:02:00:00:00:01")/IP(src="192.168.0.1", dst="192.168.0.2")/Raw('x'*20)
    pkt6 = Ether(dst="00:00:00:00:01:00", src="00:02:00:00:00:01")/IPv6(src="2001::1", dst="2001::2")/Raw('x' * 20)
    pkt7 = Ether(dst="00:00:00:00:01:00", src="00:02:00:00:00:01")/IPv6(src="2001::1", dst="2001::2")/UDP(sport=24,dport=25)/Raw('x'*20)
    pkt8 = Ether(dst="00:00:00:00:01:00", src="00:02:00:00:00:01")/Dot1Q(prio=1)/IP(src="192.168.0.1", dst="192.168.0.2")/Raw('x'*20)

   verify the pkt1 to queue 1, pkt2 to queue 3 or queue 4,
   pkt3 to queue 6 or queue 7, pkt4 to queue 8 or queue 9,
   pkt5 to queue 11 or 12 or 13 or 14,
   pkt6 to queue 15, pkt7 to queue 6 or queue 7,
   pkt8 enter the same queue with pkt5.

4. verified the rules can be listed and flushed::

    testpmd> show port 0 queue-region
    testpmd> set port 0 queue-region flush off

Notes: fortville can't parse the TCP SYN type packet, fortpark can parse it.
So if fortville, pkt2 to queue 6 or queue 7.

Test case 2: different user priority packet can enter the expected queue region
===============================================================================

1. Set queue region on a port::

    testpmd> set port 0 queue-region region_id 0 queue_start_index 0 queue_num 1
    testpmd> set port 0 queue-region region_id 7 queue_start_index 1 queue_num 8
    testpmd> set port 0 queue-region region_id 2 queue_start_index 10 queue_num 4

2. Set the mapping of User Priority to Traffic Classes on a port::

    testpmd> set port 0 queue-region UP 3 region_id 0
    testpmd> set port 0 queue-region UP 1 region_id 7
    testpmd> set port 0 queue-region UP 2 region_id 2
    testpmd> set port 0 queue-region UP 7 region_id 2
    testpmd> set port 0 queue-region flush on

3. send packet::

    pkt1=Ether(dst="00:00:00:00:01:00", src="00:02:00:00:00:01")/Dot1Q(prio=3)/IP(src="192.168.0.1", dst="192.168.0.2")/UDP(sport=22, dport=23)/Raw('x'*20)
    pkt2=Ether(dst="00:00:00:00:01:00", src="00:02:00:00:00:01")/Dot1Q(prio=1)/IP(src="192.168.0.1", dst="192.168.0.2")/UDP(sport=22, dport=23)/Raw('x'*20)
    pkt3=Ether(dst="00:00:00:00:01:00", src="00:02:00:00:00:01")/Dot1Q(prio=2)/IP(src="192.168.0.1", dst="192.168.0.2")/TCP(sport=32, dport=33)/Raw('x'*20)
    pkt4=Ether(dst="00:00:00:00:01:00", src="00:02:00:00:00:01")/Dot1Q(prio=7)/IP(src="192.168.0.1", dst="192.168.0.2")/TCP(sport=32, dport=33)/Raw('x'*20)
    pkt5=Ether(dst="00:00:00:00:01:00", src="00:02:00:00:00:01")/Dot1Q(prio=7)/IP(src="192.168.0.3", dst="192.168.0.4")/UDP(sport=22, dport=23)/Raw('x'*20)
    pkt6=Ether(dst="00:00:00:00:01:00", src="00:02:00:00:00:01")/IP(src="192.168.0.3", dst="192.168.0.4")/UDP(sport=22, dport=23)/Raw('x'*20)

   verify the pkt1 to queue 0,
   pkt2 to queue 1 or 2 or 3 or 4 or 5 or 6 or 7 or 8.
   pkt3 to queue 10 or 11 or 12 or 13.
   pkt4 enter the same queue with pkt3.
   pkt5 to queue 10 or 11 or 12 or 13.
   pkt6 enter different queue from pkt5.

4. verified the rules can be listed and flushed::

    testpmd> show port 0 queue-region
    testpmd> set port 0 queue-region flush off

Test case 3: boundary value testing
===================================

1. boundary value testing of "Set a queue region on a port"

   the following three rules are set successfully::

    testpmd> set port 0 queue-region region_id 0 queue_start_index 0 queue_num 16
    testpmd> set port 0 queue-region flush on
    testpmd> set port 0 queue-region flush off
    testpmd> set port 0 queue-region region_id 0 queue_start_index 15 queue_num 1
    testpmd> set port 0 queue-region flush on
    testpmd> set port 0 queue-region flush off
    testpmd> set port 0 queue-region region_id 7 queue_start_index 2 queue_num 8
    testpmd> set port 0 queue-region flush on

   all the three rules can be listed::

    testpmd> show port 0 queue-region
    testpmd> set port 0 queue-region flush off

   the following four rules can't be set successfully.::

    testpmd> set port 0 queue-region region_id 8 queue_start_index 2 queue_num 2
    testpmd> set port 0 queue-region region_id 1 queue_start_index 16 queue_num 1
    testpmd> set port 0 queue-region region_id 2 queue_start_index 15 queue_num 2
    testpmd> set port 0 queue-region region_id 3 queue_start_index 2 queue_num 3

   no rules can be listed::

    testpmd> show port 0 queue-region
    testpmd> set port 0 queue-region flush off

2. boundary value testing of "Set the mapping of flowtype to region index
   on a port"::

    testpmd> set port 0 queue-region region_id 0 queue_start_index 2 queue_num 2
    testpmd> set port 0 queue-region region_id 7 queue_start_index 4 queue_num 4

   the first two rules can be set successfully::

    testpmd> set port 0 queue-region region_id 0 flowtype 63
    testpmd> set port 0 queue-region region_id 7 flowtype 0

   the first two rules can be listed::

    testpmd> show port 0 queue-region

   the last two rule can't be set successfully::

    testpmd> set port 0 queue-region region_id 0 flowtype 64
    testpmd> set port 0 queue-region region_id 2 flowtype 34
    testpmd> set port 0 queue-region flush on

   the last two rules can't be listed::

    testpmd> show port 0 queue-region
    testpmd> set port 0 queue-region flush off

3. boundary value testing of "Set the mapping of UP to region index
   on a port"::

    testpmd> set port 0 queue-region region_id 0 queue_start_index 2 queue_num 2
    testpmd> set port 0 queue-region region_id 7 queue_start_index 4 queue_num 4

   the first two rules can be set successfully::

    testpmd> set port 0 queue-region UP 7 region_id 0
    testpmd> set port 0 queue-region UP 0 region_id 7

   the first two rules can be listed::

    testpmd> show port 0 queue-region

   the last two rule can't be set successfully::

    testpmd> set port 0 queue-region UP 8 region_id 0
    testpmd> set port 0 queue-region UP 1 region_id 2
    testpmd> set port 0 queue-region flush on

   the last two rules can't be listed::

    testpmd> show port 0 queue-region
    testpmd> set port 0 queue-region flush off


-----Original Message-----
From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Wei Zhao
Sent: Wednesday, October 11, 2017 4:56 PM
To: dev@dpdk.org
Subject: [dpdk-dev] [PATCH v8 0/2] net/i40e: API to configure queue regions for RSS

The patches mainly finish following functions:
1) Command line for input queue region configure parameters.
2) Set or flush queue region configutation.

v2:
-fix bug for packet into queue region code.
-change code style for DPDK C programing.
-change that "flowtype" name to  " hw_flowtype " in struct rte_i40e_rss_region_conf

v3:
-fix patch check warning
-fix a bug in cmdline.c

v4:
-fix bug for flowtype config.
-add a new command for get all queue region configuration.
-change function name to "rss" related.
-add document info about queue region CLI.

v5:
-fix patchcheck warning.
-add port id check.

v6:
-split this patch set into 2 patch.

v7:
-change some PMD_DRV_LOG log.

v8:
-change CLI command format.
-change some functions name.

root (2):
  net/i40e: queue region set and flush
  app/testpmd: add API for configuration of queue region

 app/test-pmd/cmdline.c                      | 424 ++++++++++++++++++++++++
 app/test-pmd/config.c                       |  44 +++
 app/test-pmd/testpmd.h                      |   3 +
 doc/guides/testpmd_app_ug/testpmd_funcs.rst |  41 +++
 drivers/net/i40e/i40e_ethdev.c              |  27 +-
 drivers/net/i40e/i40e_ethdev.h              |  39 +++
 drivers/net/i40e/rte_pmd_i40e.c             | 494 ++++++++++++++++++++++++++++
 drivers/net/i40e/rte_pmd_i40e.h             |  91 +++++
 drivers/net/i40e/rte_pmd_i40e_version.map   |   2 +-
 9 files changed, 1158 insertions(+), 7 deletions(-)

-- 
2.7.4

  parent reply	other threads:[~2017-10-11 11:29 UTC|newest]

Thread overview: 87+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-24  3:26 [dpdk-dev] [PATCH " Wei Zhao
2017-08-24  3:26 ` [dpdk-dev] [PATCH 1/2] net/i40e: queue region set and flush Wei Zhao
2017-08-31 16:18   ` Ferruh Yigit
2017-09-01  2:38     ` Zhao1, Wei
2017-09-06  9:11       ` Ferruh Yigit
2017-09-15 11:00         ` Ferruh Yigit
2017-09-20  3:20           ` Zhao1, Wei
2017-09-20 10:32             ` Ferruh Yigit
2017-09-18  3:38         ` Zhao1, Wei
2017-09-05 23:52   ` Chilikin, Andrey
2017-09-06  7:21     ` Zhao1, Wei
2017-08-24  3:26 ` [dpdk-dev] [PATCH 2/2] app/testpmd: add API for configuration of queue region Wei Zhao
2017-09-13  6:04 ` [dpdk-dev] [PATCH v2 0/2] net/i40e: API to configure queue regions for RSS Wei Zhao
2017-09-13  6:04   ` [dpdk-dev] [PATCH v2 1/2] net/i40e: queue region set and flush Wei Zhao
2017-09-13  6:04   ` [dpdk-dev] [PATCH v2 2/2] app/testpmd: add API for configuration of queue region Wei Zhao
2017-09-15  3:13   ` [dpdk-dev] [PATCH v3 0/2] net/i40e: API to configure queue regions for RSS Wei Zhao
2017-09-15  3:13     ` [dpdk-dev] [PATCH v3 1/2] net/i40e: queue region set and flush Wei Zhao
2017-09-20 10:36       ` Ferruh Yigit
2017-09-21  6:48         ` Zhao1, Wei
2017-09-21  7:10           ` Ferruh Yigit
2017-09-21  7:26             ` Zhao1, Wei
2017-09-21 15:45               ` Ferruh Yigit
2017-09-25  7:40         ` Zhao1, Wei
2017-09-25  9:31           ` Ferruh Yigit
2017-09-26  7:46             ` Zhao1, Wei
2017-09-26  8:54         ` Zhao1, Wei
2017-09-27 19:13           ` Ferruh Yigit
2017-09-28  2:40             ` Zhao1, Wei
2017-09-21 19:53       ` Chilikin, Andrey
2017-09-22  8:49         ` Zhao1, Wei
2017-09-22 20:13           ` Chilikin, Andrey
2017-09-25  2:55             ` Zhao1, Wei
2017-09-24 16:01       ` Wu, Jingjing
2017-09-25  3:26         ` Zhao1, Wei
2017-09-25  5:55         ` Zhao1, Wei
2017-09-15  3:13     ` [dpdk-dev] [PATCH v3 2/2] app/testpmd: add API for configuration of queue region Wei Zhao
2017-09-20 10:45       ` Ferruh Yigit
2017-09-25  9:25         ` Zhao1, Wei
2017-09-25  9:43           ` Ferruh Yigit
2017-09-26  5:30             ` Zhao1, Wei
2017-09-28  9:04     ` [dpdk-dev] [PATCH v4 0/3] net/i40e: API to configure queue regions for RSS Wei Zhao
2017-09-28  9:04       ` [dpdk-dev] [PATCH v4 1/3] net/i40e: queue region set and flush Wei Zhao
2017-09-28  9:04       ` [dpdk-dev] [PATCH v4 2/3] app/testpmd: add API for configuration of queue region Wei Zhao
2017-09-28  9:04       ` [dpdk-dev] [PATCH v4 3/3] doc/testpmd_app_ug: add doc info for " Wei Zhao
2017-09-28  9:10     ` [dpdk-dev] [PATCH v4 0/3] net/i40e: API to configure queue regions for RSS Wei Zhao
2017-09-28  9:10       ` [dpdk-dev] [PATCH v4 1/3] net/i40e: queue region set and flush Wei Zhao
2017-09-28  9:10       ` [dpdk-dev] [PATCH v4 2/3] app/testpmd: add API for configuration of queue region Wei Zhao
2017-09-28  9:10       ` [dpdk-dev] [PATCH v4 3/3] doc/testpmd_app_ug: add doc info for " Wei Zhao
2017-09-29  2:56       ` [dpdk-dev] [PATCH v5 0/3] net/i40e: API to configure queue regions for RSS Wei Zhao
2017-09-29  2:56         ` [dpdk-dev] [PATCH v5 1/3] net/i40e: queue region set and flush Wei Zhao
2017-09-29  4:54           ` Wu, Jingjing
2017-09-29  8:27             ` Zhao1, Wei
2017-09-29  2:56         ` [dpdk-dev] [PATCH v5 2/3] app/testpmd: add API for configuration of queue region Wei Zhao
2017-09-29  5:04           ` Wu, Jingjing
2017-09-29  5:21             ` Zhao1, Wei
2017-09-29  2:56         ` [dpdk-dev] [PATCH v5 3/3] doc/testpmd_app_ug: add doc info for " Wei Zhao
2017-09-29  8:11         ` [dpdk-dev] [PATCH v6] net/i40e: API to configure queue regions for RSS Wei Zhao
2017-09-29  8:11           ` [dpdk-dev] [PATCH v6] app/testpmd: add API for configuration of queue region Wei Zhao
2017-09-29  8:11           ` [dpdk-dev] [PATCH v6] net/i40e: queue region set and flush Wei Zhao
2017-09-29  9:00             ` Wu, Jingjing
2017-09-29  9:16           ` [dpdk-dev] [PATCH v7 0/2] net/i40e: API to configure queue regions for RSS Wei Zhao
2017-09-29  9:16             ` [dpdk-dev] [PATCH v7 1/2] net/i40e: queue region set and flush Wei Zhao
2017-09-29 12:22               ` Wu, Jingjing
2017-10-10  1:45                 ` Zhao1, Wei
2017-10-03 17:54               ` Ferruh Yigit
2017-10-10  6:11                 ` Zhao1, Wei
2017-09-29  9:16             ` [dpdk-dev] [PATCH v7 2/2] app/testpmd: add API for configuration of queue region Wei Zhao
2017-09-29 14:29               ` Wu, Jingjing
2017-10-03 18:04               ` Ferruh Yigit
2017-10-10  1:46                 ` Zhao1, Wei
2017-10-10  2:55                 ` Zhao1, Wei
2017-10-10  3:01                 ` Zhao1, Wei
2017-10-11  2:15                   ` Ferruh Yigit
2017-09-29 10:15             ` [dpdk-dev] [PATCH v7 0/2] net/i40e: API to configure queue regions for RSS Peng, Yuan
2017-10-11  8:49             ` [dpdk-dev] [PATCH v8 " Wei Zhao
2017-10-11  8:49               ` [dpdk-dev] [PATCH v8 1/2] net/i40e: queue region set and flush Wei Zhao
2017-10-11  8:49               ` [dpdk-dev] [PATCH v8 2/2] app/testpmd: add API for configuration of queue region Wei Zhao
2017-10-11  8:55             ` [dpdk-dev] [PATCH v8 0/2] net/i40e: API to configure queue regions for RSS Wei Zhao
2017-10-11  8:55               ` [dpdk-dev] [PATCH v8 1/2] net/i40e: queue region set and flush Wei Zhao
2017-10-13 10:06                 ` Chilikin, Andrey
2017-10-18  3:00                   ` Zhao1, Wei
2017-10-18 13:00                     ` Chilikin, Andrey
2017-10-19  2:18                       ` Zhao1, Wei
2017-10-11  8:55               ` [dpdk-dev] [PATCH v8 2/2] app/testpmd: add API for configuration of queue region Wei Zhao
2017-10-11 11:29               ` Peng, Yuan [this message]
2017-10-11 21:06               ` [dpdk-dev] [PATCH v8 0/2] net/i40e: API to configure queue regions for RSS Ferruh Yigit
2017-10-13  1:52                 ` Zhao1, Wei

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=67D543A150B29E4CAAE53918F64EDAEA3744A0DA@SHSMSX103.ccr.corp.intel.com \
    --to=yuan.peng@intel.com \
    --cc=dev@dpdk.org \
    --cc=wei.zhao1@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).