From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by dpdk.org (Postfix) with ESMTP id 5AD8B5965 for ; Wed, 21 May 2014 17:31:09 +0200 (CEST) Received: from orsmga001.jf.intel.com ([10.7.209.18]) by orsmga102.jf.intel.com with ESMTP; 21 May 2014 08:25:59 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.98,880,1392192000"; d="scan'208";a="515493679" Received: from shilc102.sh.intel.com ([10.239.39.44]) by orsmga001.jf.intel.com with ESMTP; 21 May 2014 08:30:51 -0700 Received: from shecgisg004.sh.intel.com (shecgisg004.sh.intel.com [10.239.29.89]) by shilc102.sh.intel.com (8.13.6/8.13.6/SuSE Linux 0.8) with ESMTP id s4LFUj5j004552; Wed, 21 May 2014 23:30:47 +0800 Received: from shecgisg004.sh.intel.com (localhost [127.0.0.1]) by shecgisg004.sh.intel.com (8.13.6/8.13.6/SuSE Linux 0.8) with ESMTP id s4LFUfmx005068; Wed, 21 May 2014 23:30:43 +0800 Received: (from hzhan75@localhost) by shecgisg004.sh.intel.com (8.13.6/8.13.6/Submit) id s4LFUfmF005064; Wed, 21 May 2014 23:30:41 +0800 From: Helin Zhang To: dev@dpdk.org Date: Wed, 21 May 2014 23:30:06 +0800 Message-Id: <1400686221-4696-8-git-send-email-helin.zhang@intel.com> X-Mailer: git-send-email 1.7.0.7 In-Reply-To: <1400686221-4696-1-git-send-email-helin.zhang@intel.com> References: <1400686221-4696-1-git-send-email-helin.zhang@intel.com> Subject: [dpdk-dev] [PATCH 07/22] app/testpmd: enlarge the hash flags of RSS to 64 bits X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 21 May 2014 15:31:11 -0000 As the hash flags of RSS has been enlarged from 16 bits to 64 bits in 'struct rte_eth_rss_conf' in rte_ethdev.h, the size of it in testpmd should be enlarged as well. In addition, macro of ETH_RSS_IP is used to replace all IP hash flags of RSS. Signed-off-by: Helin Zhang Signed-off-by: Mark Chen --- app/test-pmd/cmdline.c | 4 ++-- app/test-pmd/parameters.c | 5 ++--- app/test-pmd/testpmd.c | 2 +- app/test-pmd/testpmd.h | 2 +- 4 files changed, 6 insertions(+), 7 deletions(-) diff --git a/app/test-pmd/cmdline.c b/app/test-pmd/cmdline.c index b3824f9..7ecfc84 100644 --- a/app/test-pmd/cmdline.c +++ b/app/test-pmd/cmdline.c @@ -1131,9 +1131,9 @@ cmd_config_rss_parsed(void *parsed_result, } if (!strcmp(res->value, "ip")) - rss_hf = ETH_RSS_IPV4 | ETH_RSS_IPV6; + rss_hf = ETH_RSS_IP; else if (!strcmp(res->value, "udp")) - rss_hf = ETH_RSS_IPV4 | ETH_RSS_IPV6 | ETH_RSS_IPV4_UDP; + rss_hf = ETH_RSS_UDP; else if (!strcmp(res->value, "none")) rss_hf = 0; else { diff --git a/app/test-pmd/parameters.c b/app/test-pmd/parameters.c index 7a60048..725ca6f 100644 --- a/app/test-pmd/parameters.c +++ b/app/test-pmd/parameters.c @@ -832,10 +832,9 @@ launch_args_parse(int argc, char** argv) if (!strcmp(lgopts[opt_idx].name, "forward-mode")) set_pkt_forwarding_mode(optarg); if (!strcmp(lgopts[opt_idx].name, "rss-ip")) - rss_hf = ETH_RSS_IPV4 | ETH_RSS_IPV6; + rss_hf = ETH_RSS_IP; if (!strcmp(lgopts[opt_idx].name, "rss-udp")) - rss_hf = ETH_RSS_IPV4 | - ETH_RSS_IPV6 | ETH_RSS_IPV4_UDP; + rss_hf = ETH_RSS_UDP; if (!strcmp(lgopts[opt_idx].name, "rxq")) { n = atoi(optarg); if (n >= 1 && n <= (int) MAX_QUEUE_ID) diff --git a/app/test-pmd/testpmd.c b/app/test-pmd/testpmd.c index bc38305..eea2c6c 100644 --- a/app/test-pmd/testpmd.c +++ b/app/test-pmd/testpmd.c @@ -250,7 +250,7 @@ uint32_t txq_flags = 0; /* No flags set. */ /* * Receive Side Scaling (RSS) configuration. */ -uint16_t rss_hf = ETH_RSS_IPV4 | ETH_RSS_IPV6; /* RSS IP by default. */ +uint64_t rss_hf = ETH_RSS_IP; /* RSS IP by default. */ /* * Port topology configuration diff --git a/app/test-pmd/testpmd.h b/app/test-pmd/testpmd.h index 2bdb1a2..0e891cd 100644 --- a/app/test-pmd/testpmd.h +++ b/app/test-pmd/testpmd.h @@ -326,7 +326,7 @@ extern portid_t fwd_ports_ids[RTE_MAX_ETHPORTS]; extern struct rte_port *ports; extern struct rte_eth_rxmode rx_mode; -extern uint16_t rss_hf; +extern uint64_t rss_hf; extern queueid_t nb_rxq; extern queueid_t nb_txq; -- 1.8.1.4