DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH] testpmd: remove duplicated parameter parsing
@ 2015-02-06 14:15 Pablo de Lara
  2015-02-11 10:41 ` Gonzalez Monroy, Sergio
  0 siblings, 1 reply; 3+ messages in thread
From: Pablo de Lara @ 2015-02-06 14:15 UTC (permalink / raw)
  To: dev

Several parameters were being parsed twice in testpmd,
so this patch gets rid of the second parsing.

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
---
 app/test-pmd/parameters.c |   56 ---------------------------------------------
 1 files changed, 0 insertions(+), 56 deletions(-)

diff --git a/app/test-pmd/parameters.c b/app/test-pmd/parameters.c
index adf3203..c7105ca 100644
--- a/app/test-pmd/parameters.c
+++ b/app/test-pmd/parameters.c
@@ -819,20 +819,6 @@ launch_args_parse(int argc, char** argv)
 						  " >= 1 && <= %d\n", n,
 						  (int) MAX_QUEUE_ID);
 			}
-			if (!strcmp(lgopts[opt_idx].name, "rxd")) {
-				n = atoi(optarg);
-				if (n > 0)
-					nb_rxd = (uint16_t) n;
-				else
-					rte_exit(EXIT_FAILURE, "rxd must be > 0\n");
-			}
-			if (!strcmp(lgopts[opt_idx].name, "txd")) {
-				n = atoi(optarg);
-				if (n > 0)
-					nb_txd = (uint16_t) n;
-				else
-					rte_exit(EXIT_FAILURE, "txd must be in > 0\n");
-			}
 			if (!strcmp(lgopts[opt_idx].name, "burst")) {
 				n = atoi(optarg);
 				if ((n >= 1) && (n <= MAX_PKT_BURST))
@@ -852,27 +838,6 @@ launch_args_parse(int argc, char** argv)
 						 "mbcache must be >= 0 and <= %d\n",
 						 RTE_MEMPOOL_CACHE_MAX_SIZE);
 			}
-			if (!strcmp(lgopts[opt_idx].name, "txpt")) {
-				n = atoi(optarg);
-				if (n >= 0)
-					tx_thresh.pthresh = (uint8_t)n;
-				else
-					rte_exit(EXIT_FAILURE, "txpt must be >= 0\n");
-			}
-			if (!strcmp(lgopts[opt_idx].name, "txht")) {
-				n = atoi(optarg);
-				if (n >= 0)
-					tx_thresh.hthresh = (uint8_t)n;
-				else
-					rte_exit(EXIT_FAILURE, "txht must be >= 0\n");
-			}
-			if (!strcmp(lgopts[opt_idx].name, "txwt")) {
-				n = atoi(optarg);
-				if (n >= 0)
-					tx_thresh.wthresh = (uint8_t)n;
-				else
-					rte_exit(EXIT_FAILURE, "txwt must be >= 0\n");
-			}
 			if (!strcmp(lgopts[opt_idx].name, "txfreet")) {
 				n = atoi(optarg);
 				if (n >= 0)
@@ -896,27 +861,6 @@ launch_args_parse(int argc, char** argv)
 					rte_exit(EXIT_FAILURE,
 						 "txqflags must be >= 0\n");
 			}
-			if (!strcmp(lgopts[opt_idx].name, "rxpt")) {
-				n = atoi(optarg);
-				if (n >= 0)
-					rx_thresh.pthresh = (uint8_t)n;
-				else
-					rte_exit(EXIT_FAILURE, "rxpt must be >= 0\n");
-			}
-			if (!strcmp(lgopts[opt_idx].name, "rxht")) {
-				n = atoi(optarg);
-				if (n >= 0)
-					rx_thresh.hthresh = (uint8_t)n;
-				else
-					rte_exit(EXIT_FAILURE, "rxht must be >= 0\n");
-			}
-			if (!strcmp(lgopts[opt_idx].name, "rxwt")) {
-				n = atoi(optarg);
-				if (n >= 0)
-					rx_thresh.wthresh = (uint8_t)n;
-				else
-					rte_exit(EXIT_FAILURE, "rxwt must be >= 0\n");
-			}
 			if (!strcmp(lgopts[opt_idx].name, "rxd")) {
 				n = atoi(optarg);
 				if (n > 0) {
-- 
1.7.4.1

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [dpdk-dev] [PATCH] testpmd: remove duplicated parameter parsing
  2015-02-06 14:15 [dpdk-dev] [PATCH] testpmd: remove duplicated parameter parsing Pablo de Lara
@ 2015-02-11 10:41 ` Gonzalez Monroy, Sergio
  2015-02-15 15:55   ` Thomas Monjalon
  0 siblings, 1 reply; 3+ messages in thread
From: Gonzalez Monroy, Sergio @ 2015-02-11 10:41 UTC (permalink / raw)
  To: De Lara Guarch, Pablo, dev

> From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Pablo de Lara
> Sent: Friday, February 6, 2015 2:15 PM
> To: dev@dpdk.org
> Subject: [dpdk-dev] [PATCH] testpmd: remove duplicated parameter parsing
> 
> Several parameters were being parsed twice in testpmd, so this patch gets
> rid of the second parsing.
> 
> Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
> ---
>  app/test-pmd/parameters.c |   56 ---------------------------------------------
>  1 files changed, 0 insertions(+), 56 deletions(-)
> 
Acked-by: Sergio Gonzalez Monroy <sergio.gonzalez.monroy@intel.com>

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [dpdk-dev] [PATCH] testpmd: remove duplicated parameter parsing
  2015-02-11 10:41 ` Gonzalez Monroy, Sergio
@ 2015-02-15 15:55   ` Thomas Monjalon
  0 siblings, 0 replies; 3+ messages in thread
From: Thomas Monjalon @ 2015-02-15 15:55 UTC (permalink / raw)
  To: De Lara Guarch, Pablo; +Cc: dev

> > Several parameters were being parsed twice in testpmd, so this patch gets
> > rid of the second parsing.
> > 
> > Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
> > 
> Acked-by: Sergio Gonzalez Monroy <sergio.gonzalez.monroy@intel.com>

Applied, thanks

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2015-02-15 15:56 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-02-06 14:15 [dpdk-dev] [PATCH] testpmd: remove duplicated parameter parsing Pablo de Lara
2015-02-11 10:41 ` Gonzalez Monroy, Sergio
2015-02-15 15:55   ` Thomas Monjalon

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).