From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 7F72D4292F; Thu, 13 Apr 2023 09:27:48 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 792AB40A84; Thu, 13 Apr 2023 09:27:48 +0200 (CEST) Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by mails.dpdk.org (Postfix) with ESMTP id 85BBB4021F for ; Thu, 13 Apr 2023 09:27:46 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1681370866; x=1712906866; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=pDAUJSnnW+PWi3URs87FeeFZqJtFtl+4NmUShz6ycXE=; b=W/+Xf01PbIL7m21spjNwLeai9Hsu2Uf0LSoGyrDDa+xqHuOLxkzvZhNU FIqYp5YcslF3ECVo53SfxUPH2lULq2TA+/L37AccyhFk6jXPBk/O15SHD vRTXoR6EcRfZLMWZ1VB1RH8JN4JfVtAAICh/LEPn8kx4j/BKJvCV+gkxM xewY6EJ+GQmGgOUIyOe7GIW8XNhgE79gOidEDXBwYqQw48Bf/0L6/HGWK 14m67/fYvwrASH9qo703rZFTwZpHEB9sK6yhBwjgKBFQse8bpJt13ogm+ KtQAOpzTb3DjygeshWwpFjSLPdsWCUTmg9Ln9+tx83/6Gn9bQUj62HtYA w==; X-IronPort-AV: E=McAfee;i="6600,9927,10678"; a="345902960" X-IronPort-AV: E=Sophos;i="5.98,339,1673942400"; d="scan'208";a="345902960" Received: from orsmga007.jf.intel.com ([10.7.209.58]) by orsmga102.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Apr 2023 00:27:45 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10678"; a="682846626" X-IronPort-AV: E=Sophos;i="5.98,339,1673942400"; d="scan'208";a="682846626" Received: from unknown (HELO localhost.localdomain) ([10.239.252.99]) by orsmga007-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Apr 2023 00:27:43 -0700 From: Lingli Chen To: dts@dpdk.org Cc: yuan.peng@intel.com, Lingli Chen Subject: [dts][PATCH V1 1/2] test_plans/vf_queue_start_stop: add new vf test_plan Date: Thu, 13 Apr 2023 02:17:29 -0400 Message-Id: <20230413061730.69065-1-linglix.chen@intel.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 Content-Type: text/plain; charset=y Content-Transfer-Encoding: 8bit X-BeenThere: dts@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: test suite reviews and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dts-bounces@dpdk.org add vf_queue_start_stop_test_plan Signed-off-by: Lingli Chen --- test_plans/index.rst | 1 + test_plans/vf_queue_start_stop_test_plan.rst | 94 ++++++++++++++++++++ 2 files changed, 95 insertions(+) create mode 100644 test_plans/vf_queue_start_stop_test_plan.rst diff --git a/test_plans/index.rst b/test_plans/index.rst index 2008f50b..7c72d6eb 100644 --- a/test_plans/index.rst +++ b/test_plans/index.rst @@ -192,6 +192,7 @@ The following are the test plans for the DPDK DTS automated test system. vf_packet_rxtx_test_plan vf_pf_reset_test_plan vf_port_start_stop_test_plan + vf_queue_start_stop_test_plan vf_rss_test_plan vf_single_core_perf_test_plan vf_smoke_test_plan diff --git a/test_plans/vf_queue_start_stop_test_plan.rst b/test_plans/vf_queue_start_stop_test_plan.rst new file mode 100644 index 00000000..a1a83450 --- /dev/null +++ b/test_plans/vf_queue_start_stop_test_plan.rst @@ -0,0 +1,94 @@ +.. SPDX-License-Identifier: BSD-3-Clause + Copyright(c) 2023 Intel Corporation + +=========================== +VF Shutdown API Queue Tests +=========================== + +This tests for Shutdown API feature can be run on linux userspace. It +will check if NIC vf port can be stopped and restarted without exiting the +application process. Furthermore, it will check if it can reconfigure +new configurations for a port after the port is stopped, and if it is +able to restart with those new configurations. It is based on testpmd +application. + +The test is performed by running the testpmd application and using a +traffic generator. Port/queue configurations can be set interactively, +and still be set at the command line when launching the application in +order to be compatible with previous test framework. + +Prerequisites +------------- + +Assume port A and B are connected to the remote ports, e.g. packet generator. +Get the pci device id of DUT, for example:: + + ./usertools/dpdk-devbind.py -s + + 0000:af:00.0 'Ethernet Controller XXV710 for 25GbE SFP28 158b' if=enp175s0f0 drv=i40e unused=vfio-pci + +Generate 1 VF on PF:: + + echo 1 > /sys/bus/pci/devices/0000:af:00.0/sriov_numvfs + +Bind VFs to dpdk driver:: + + modprobe vfio-pci + ./usertools/dpdk-devbind.py -b vfio-pci 0000:af:01.0 + +Test Case: vf queue start/stop +------------------------------ + +This case support VF (IntelĀ® Ethernet 700 Series/IntelĀ® Ethernet 800 Series) + +#. Launch testpmd:: + x86_64-native-linuxapp-gcc/app/dpdk-testpmd -l 1-2 -n 4 -a 0000:af:01.0 -- -i --portmask=0x1 --port-topology=loop + +#. Run "set verbose 1" to set verbose +#. Run "set fwd mac" to set fwd type +#. Run "start" to start fwd package + +#. Start a packet capture on the tester in the background:: + tcpdump -i ens7 'ether[12:2] != 0x88cc' -Q in -w /tmp/tester/sniff_ens7.pcap + +#. Start packet generator to transmit packets:: + sendp([Ether(dst='3c:fd:fe:c1:0f:4c', src='00:00:20:00:00:00')/IP()/UDP()/Raw(load=b'XXXXXXXXXXXXXXXXXX')],iface="ens7",count=4,inter=0,verbose=False) + +#. Stop testpmd:: + + --------------------- Forward statistics for port 0 ---------------------- + RX-packets: 4 RX-dropped: 0 RX-total: 4 + TX-packets: 4 TX-dropped: 0 TX-total: 4 + ---------------------------------------------------------------------------- + +#. Quit tcpdump and check tester port receive 4 packets + +#. Run "port 0 rxq 0 stop" to stop rxq 0 in port 0 +#. Start packet generator to transmit and check tester port not receive packets +#. Stop testpmd:: + + ---------------------- Forward statistics for port 0 ---------------------- + RX-packets: 0 RX-dropped: 4 RX-total: 4 + TX-packets: 0 TX-dropped: 0 TX-total: 0 + ---------------------------------------------------------------------------- + +#. Run "port 0 rxq 0 start" to start rxq 0 in port 0 +#. Run "port 0 txq 0 stop" to stop txq 0 in port 0 +#. Start packet generator to transmit and check tester port not receive packets + and in testpmd it not has "port 0/queue 0: received 1 packets" print +#. Stop testpmd:: + + ---------------------- Forward statistics for port 0 ---------------------- + RX-packets: 4 RX-dropped: 0 RX-total: 4 + TX-packets: 0 TX-dropped: 0 TX-total: 0 + ---------------------------------------------------------------------------- + +#. Run "port 0 txq 0 start" to start txq 0 in port 0 +#. Start packet generator to transmit and check tester port receive 4 packets + and in testpmd it has "port 0/queue 0: received 1 packets" print +#. Stop testpmd:: + + ---------------------- Forward statistics for port 0 ---------------------- + RX-packets: 4 RX-dropped: 0 RX-total: 4 + TX-packets: 4 TX-dropped: 0 TX-total: 4 + ---------------------------------------------------------------------------- -- 2.17.1