[16/39] eventdev: add eventmode CL options framework

Message ID 1559583160-13944-17-git-send-email-anoobj@marvell.com (mailing list archive)
State Changes Requested, archived
Delegated to: Jerin Jacob
Headers
Series adding eventmode helper library |

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/Intel-compilation fail Compilation issues

Commit Message

Anoob Joseph June 3, 2019, 5:32 p.m. UTC
  Adding usage prints and CL parsing routines for eventmode. Option to
select packet transfer mode is also added.

Signed-off-by: Anoob Joseph <anoobj@marvell.com>
Signed-off-by: Lukasz Bartosik <lbartosik@marvell.com>
---
 lib/librte_eventdev/rte_eventdev_version.map |   2 +
 lib/librte_eventdev/rte_eventmode_helper.c   | 128 +++++++++++++++++++++++++++
 lib/librte_eventdev/rte_eventmode_helper.h   |  51 +++++++++++
 3 files changed, 181 insertions(+)
  

Comments

Jerin Jacob Kollanukkaran June 10, 2019, 10:19 a.m. UTC | #1
> -----Original Message-----
> From: Anoob Joseph <anoobj@marvell.com>
> Sent: Monday, June 3, 2019 11:02 PM
> To: Jerin Jacob Kollanukkaran <jerinj@marvell.com>; Nikhil Rao
> <nikhil.rao@intel.com>; Erik Gabriel Carrillo <erik.g.carrillo@intel.com>;
> Abhinandan Gujjar <abhinandan.gujjar@intel.com>; Bruce Richardson
> <bruce.richardson@intel.com>; Pablo de Lara
> <pablo.de.lara.guarch@intel.com>
> Cc: Anoob Joseph <anoobj@marvell.com>; Narayana Prasad Raju Athreya
> <pathreya@marvell.com>; dev@dpdk.org; Lukas Bartosik
> <lbartosik@marvell.com>; Pavan Nikhilesh Bhagavatula
> <pbhagavatula@marvell.com>; Hemant Agrawal
> <hemant.agrawal@nxp.com>; Nipun Gupta <nipun.gupta@nxp.com>; Harry
> van Haaren <harry.van.haaren@intel.com>; Mattias Rönnblom
> <mattias.ronnblom@ericsson.com>; Liang Ma <liang.j.ma@intel.com>
> Subject: [PATCH 16/39] eventdev: add eventmode CL options framework
> 
> Adding usage prints and CL parsing routines for eventmode. Option to select
> packet transfer mode is also added.
> 
> Signed-off-by: Anoob Joseph <anoobj@marvell.com>
> Signed-off-by: Lukasz Bartosik <lbartosik@marvell.com>
> ---
> +#include <rte_compat.h>
> +
> +/* Packet transfer mode of the application */ enum
> +rte_eventmode_helper_pkt_transfer_mode {
> +	RTE_EVENTMODE_HELPER_PKT_TRANSFER_MODE_POLL = 0,
> +	RTE_EVENTMODE_HELPER_PKT_TRANSFER_MODE_EVENT,
> +};

Need to mark all public structues as EXPERIMENTAL.
Please grep for EXPERIMENTAL in libeventdev or any other library

> +struct rte_eventmode_helper_conf {
> +	enum rte_eventmode_helper_pkt_transfer_mode mode;
> +		/**< Packet transfer mode of the application */
> +	void *mode_params;
> +		/**< Mode specific parameters */
> +};

Please make this event_helper object as 'opaque'  and move to internal so that it does have
ABI policies and future new features can be added.
  
Sunil Kumar Kori June 11, 2019, 8:58 a.m. UTC | #2
Regards
Sunil Kumar Kori

>-----Original Message-----
>From: dev <dev-bounces@dpdk.org> On Behalf Of Anoob Joseph
>Sent: Monday, June 3, 2019 11:02 PM
>To: Jerin Jacob Kollanukkaran <jerinj@marvell.com>; Nikhil Rao
><nikhil.rao@intel.com>; Erik Gabriel Carrillo <erik.g.carrillo@intel.com>;
>Abhinandan Gujjar <abhinandan.gujjar@intel.com>; Bruce Richardson
><bruce.richardson@intel.com>; Pablo de Lara
><pablo.de.lara.guarch@intel.com>
>Cc: Anoob Joseph <anoobj@marvell.com>; Narayana Prasad Raju Athreya
><pathreya@marvell.com>; dev@dpdk.org; Lukas Bartosik
><lbartosik@marvell.com>; Pavan Nikhilesh Bhagavatula
><pbhagavatula@marvell.com>; Hemant Agrawal
><hemant.agrawal@nxp.com>; Nipun Gupta <nipun.gupta@nxp.com>; Harry
>van Haaren <harry.van.haaren@intel.com>; Mattias Rönnblom
><mattias.ronnblom@ericsson.com>; Liang Ma <liang.j.ma@intel.com>
>Subject: [EXT] [dpdk-dev] [PATCH 16/39] eventdev: add eventmode CL options
>framework
>
>External Email
>
>----------------------------------------------------------------------
>Adding usage prints and CL parsing routines for eventmode. Option to select
>packet transfer mode is also added.
>
>Signed-off-by: Anoob Joseph <anoobj@marvell.com>
>Signed-off-by: Lukasz Bartosik <lbartosik@marvell.com>
>---
> lib/librte_eventdev/rte_eventdev_version.map |   2 +
> lib/librte_eventdev/rte_eventmode_helper.c   | 128
>+++++++++++++++++++++++++++
> lib/librte_eventdev/rte_eventmode_helper.h   |  51 +++++++++++
> 3 files changed, 181 insertions(+)
>
>diff --git a/lib/librte_eventdev/rte_eventdev_version.map
>b/lib/librte_eventdev/rte_eventdev_version.map
>index 95fd089..1199064 100644
>--- a/lib/librte_eventdev/rte_eventdev_version.map
>+++ b/lib/librte_eventdev/rte_eventdev_version.map
>@@ -128,4 +128,6 @@ EXPERIMENTAL {
>
> 	rte_event_eth_rx_adapter_cb_register;
> 	rte_event_eth_rx_adapter_stats_get;
>+	rte_eventmode_helper_print_options_list;
>+	rte_eventmode_helper_print_options_description;
> };
>diff --git a/lib/librte_eventdev/rte_eventmode_helper.c
>b/lib/librte_eventdev/rte_eventmode_helper.c
>index f47970e..8119306 100644
>--- a/lib/librte_eventdev/rte_eventmode_helper.c
>+++ b/lib/librte_eventdev/rte_eventmode_helper.c
>@@ -1,7 +1,135 @@
> /* SPDX-License-Identifier: BSD-3-Clause
>  * Copyright (C) 2019 Marvell International Ltd.
>  */
>+#include <getopt.h>
>
> #include <rte_eventmode_helper.h>
>+#include <rte_malloc.h>
>
> #include "rte_eventmode_helper_internal.h"
>+
>+#define CMD_LINE_OPT_TRANSFER_MODE	"transfer-mode"
>+
>+static const char short_options[] =
>+	""
>+	;
>+
>+enum {
>+	/* long options mapped to a short option */
>+
>+	/* first long only option value must be >= 256, so that we won't
>+	 * conflict with short options
>+	 */
>+	CMD_LINE_OPT_MIN_NUM = 256,
>+	CMD_LINE_OPT_TRANSFER_MODE_NUM,
>+};
>+
>+static const struct option lgopts[] = {
>+	{CMD_LINE_OPT_TRANSFER_MODE, 1, 0,
>CMD_LINE_OPT_TRANSFER_MODE_NUM},
>+	{NULL, 0, 0, 0}
>+};
>+
>+/* Internal functions */
>+
>+static int32_t
>+internal_parse_decimal(const char *str) {
>+	char *end = NULL;
>+	unsigned long num;
>+
>+	num = strtoul(str, &end, 10);
>+	if ((str[0] == '\0') || (end == NULL) || (*end != '\0'))
>+		return -1;
>+
>+	return num;
>+}
>+
>+/* Global functions */
>+
>+void __rte_experimental
>+rte_eventmode_helper_print_options_list(void)
>+{
>+	fprintf(stderr, " --"
>+		" [--transfer-mode MODE]"
>+		);
>+}
>+
>+void __rte_experimental
>+rte_eventmode_helper_print_options_description(void)
>+{
>+	fprintf(stderr,
>+		"  --transfer-mode MODE\n"
>+		"               0: Packet transfer via polling (default)\n"
>+		"               1: Packet transfer via eventdev\n"
>+		"\n");
>+}
>+

Instead of exposing rte_eventmode_helper_print_options_* , we can maintain a page where all event_helper options are mentioned. Also application usage function can be updated like

        	fprintf(stderr, "%s [EAL options] --"
              " -p PORTMASK"
              " [-q NQ]",
	" -- [event helper options]"
              prgname);

 Advantages: Both functions will be removed from set of APIs and usage function will not be changed much. Suggesting the same methodology as used for EAL options.

>+static int
>+em_parse_transfer_mode(struct rte_eventmode_helper_conf *conf,
>+		const char *optarg)
>+{
>+	int32_t parsed_dec;
>+
>+	parsed_dec = internal_parse_decimal(optarg);
>+	if (parsed_dec !=
>RTE_EVENTMODE_HELPER_PKT_TRANSFER_MODE_POLL &&
>+	    parsed_dec !=
>RTE_EVENTMODE_HELPER_PKT_TRANSFER_MODE_EVENT) {
>+		RTE_EM_HLPR_LOG_ERR("Unsupported packet transfer
>mode");
>+		return -1;
>+	}
>+	conf->mode = parsed_dec;
>+	return 0;
>+}
>+
>+static void
>+em_initialize_helper_conf(struct rte_eventmode_helper_conf *conf) {
>+	/* Set default conf */
>+
>+	/* Packet transfer mode: poll */
>+	conf->mode =
>RTE_EVENTMODE_HELPER_PKT_TRANSFER_MODE_POLL;
>+}
>+
>+struct rte_eventmode_helper_conf *
>+rte_eventmode_helper_parse_args(int argc, char **argv) {
>+	int32_t opt, ret;
>+	struct rte_eventmode_helper_conf *conf = NULL;
>+
>+	/* Allocate memory for conf */
>+	conf = rte_zmalloc("eventmode-helper-conf",
>+			sizeof(struct rte_eventmode_helper_conf),
>+			RTE_CACHE_LINE_SIZE);
>+	if (conf == NULL) {
>+		RTE_EM_HLPR_LOG_ERR(
>+			"Failed allocating memory for eventmode helper
>conf");
>+			goto err;
>+	}
>+


Memory allocation for conf and conf->mode_params can be done in single alloc operation as given below:

	size = sizeof(struct rte_eventmode_helper_conf) + sizeof(struct eventmode_conf);
	conf = malloc(size);
	conf->mode_params = conf + 1;
	
Advantages: one NULL check will be avoided. To release the memory, need to free one pointer only. line of source code will be reduced.

>+	/* Initialize conf with default values */
>+	em_initialize_helper_conf(conf);
>+
>+	while ((opt = getopt_long(argc, argv, short_options,
>+				lgopts, NULL)) != EOF) {
>+		switch (opt) {
>+
>+		/* Packet transfer mode */
>+		case CMD_LINE_OPT_TRANSFER_MODE_NUM:
>+			ret = em_parse_transfer_mode(conf, optarg);
>+			if (ret < 0) {
>+				RTE_EM_HLPR_LOG_ERR(
>+					"Invalid packet transfer mode");
>+				goto err;
>+			}
>+			break;
>+		default:
>+			goto err;
>+		}
>+	}
>+	return conf;
>+
>+err:
>+	if (conf != NULL)
>+		rte_free(conf);
>+
>+	return NULL;
>+}
>diff --git a/lib/librte_eventdev/rte_eventmode_helper.h
>b/lib/librte_eventdev/rte_eventmode_helper.h
>index d32cd00..2a0cb30 100644
>--- a/lib/librte_eventdev/rte_eventmode_helper.h
>+++ b/lib/librte_eventdev/rte_eventmode_helper.h
>@@ -8,6 +8,57 @@
> extern "C" {
> #endif
>
>+#include <rte_compat.h>
>+
>+/* Packet transfer mode of the application */ enum
>+rte_eventmode_helper_pkt_transfer_mode {
>+	RTE_EVENTMODE_HELPER_PKT_TRANSFER_MODE_POLL = 0,
>+	RTE_EVENTMODE_HELPER_PKT_TRANSFER_MODE_EVENT,
>+};
>+
>+struct rte_eventmode_helper_conf {
>+	enum rte_eventmode_helper_pkt_transfer_mode mode;
>+		/**< Packet transfer mode of the application */
>+	void *mode_params;
>+		/**< Mode specific parameters */
>+};
>+
>+/* Common helper functions for command line parsing */
>+
>+/**
>+ * Print event mode options list
>+ *
>+ */
>+void __rte_experimental
>+rte_eventmode_helper_print_options_list(void);
>+
>+/**
>+ * Print event mode options description
>+ *
>+ */
>+void __rte_experimental
>+rte_eventmode_helper_print_options_description(void);
>+
>+/**
>+ * Parse event mode arguments
>+ *
>+ * The application can call this function in it's argument parsing
>+routine to
>+ * parse the event mode specific args and create the conf accordingly.
>+This
>+ * function is to be executed on the MASTER lcore only.
>+ *
>+ * @param argc
>+ *   A non-negative value. If it is greater than 0, the array members
>+ *   for argv[0] through argv[argc] (non-inclusive) shall contain pointers
>+ *   to strings.
>+ * @param argv
>+ *   An array of strings. The contents of the array, as well as the strings
>+ *   which are pointed to by the array, may be modified by this function.
>+ * @return
>+ *   Configuration generated by parsing the event mode args.
>+ */
>+struct rte_eventmode_helper_conf *
>+rte_eventmode_helper_parse_args(int argc, char **argv);
>+
> #ifdef __cplusplus
> }
> #endif
>--
>2.7.4
  
Anoob Joseph June 17, 2019, 10:14 a.m. UTC | #3
Hi Jerin,

Please see inline.

Thanks,
Anoob

> -----Original Message-----
> From: Jerin Jacob Kollanukkaran
> Sent: Monday, June 10, 2019 3:49 PM
> To: Anoob Joseph <anoobj@marvell.com>; Nikhil Rao
> <nikhil.rao@intel.com>; Erik Gabriel Carrillo <erik.g.carrillo@intel.com>;
> Abhinandan Gujjar <abhinandan.gujjar@intel.com>; Bruce Richardson
> <bruce.richardson@intel.com>; Pablo de Lara
> <pablo.de.lara.guarch@intel.com>
> Cc: Anoob Joseph <anoobj@marvell.com>; Narayana Prasad Raju Athreya
> <pathreya@marvell.com>; dev@dpdk.org; Lukas Bartosik
> <lbartosik@marvell.com>; Pavan Nikhilesh Bhagavatula
> <pbhagavatula@marvell.com>; Hemant Agrawal
> <hemant.agrawal@nxp.com>; Nipun Gupta <nipun.gupta@nxp.com>; Harry
> van Haaren <harry.van.haaren@intel.com>; Mattias Rönnblom
> <mattias.ronnblom@ericsson.com>; Liang Ma <liang.j.ma@intel.com>
> Subject: RE: [PATCH 16/39] eventdev: add eventmode CL options framework
> 
> > -----Original Message-----
> > From: Anoob Joseph <anoobj@marvell.com>
> > Sent: Monday, June 3, 2019 11:02 PM
> > To: Jerin Jacob Kollanukkaran <jerinj@marvell.com>; Nikhil Rao
> > <nikhil.rao@intel.com>; Erik Gabriel Carrillo
> > <erik.g.carrillo@intel.com>; Abhinandan Gujjar
> > <abhinandan.gujjar@intel.com>; Bruce Richardson
> > <bruce.richardson@intel.com>; Pablo de Lara
> > <pablo.de.lara.guarch@intel.com>
> > Cc: Anoob Joseph <anoobj@marvell.com>; Narayana Prasad Raju Athreya
> > <pathreya@marvell.com>; dev@dpdk.org; Lukas Bartosik
> > <lbartosik@marvell.com>; Pavan Nikhilesh Bhagavatula
> > <pbhagavatula@marvell.com>; Hemant Agrawal
> <hemant.agrawal@nxp.com>;
> > Nipun Gupta <nipun.gupta@nxp.com>; Harry van Haaren
> > <harry.van.haaren@intel.com>; Mattias Rönnblom
> > <mattias.ronnblom@ericsson.com>; Liang Ma <liang.j.ma@intel.com>
> > Subject: [PATCH 16/39] eventdev: add eventmode CL options framework
> >
> > Adding usage prints and CL parsing routines for eventmode. Option to
> > select packet transfer mode is also added.
> >
> > Signed-off-by: Anoob Joseph <anoobj@marvell.com>
> > Signed-off-by: Lukasz Bartosik <lbartosik@marvell.com>
> > ---
> > +#include <rte_compat.h>
> > +
> > +/* Packet transfer mode of the application */ enum
> > +rte_eventmode_helper_pkt_transfer_mode {
> > +	RTE_EVENTMODE_HELPER_PKT_TRANSFER_MODE_POLL = 0,
> > +	RTE_EVENTMODE_HELPER_PKT_TRANSFER_MODE_EVENT,
> > +};
> 
> Need to mark all public structues as EXPERIMENTAL.
> Please grep for EXPERIMENTAL in libeventdev or any other library

[Anoob] Will fix in v2.

> 
> > +struct rte_eventmode_helper_conf {
> > +	enum rte_eventmode_helper_pkt_transfer_mode mode;
> > +		/**< Packet transfer mode of the application */
> > +	void *mode_params;
> > +		/**< Mode specific parameters */
> > +};
> 
> Please make this event_helper object as 'opaque'  and move to internal so
> that it does have ABI policies and future new features can be added.
> 

[Anoob] The member, "mode_params" is the opaque pointer which is used internally. There are two fields which need to be communicated between application and helper library.

1. mode: whether the application is running in event-mode or poll-mode. Both application and helper library would need this. This field is set by the helper while parsing the eventmode args.
2. eth_portmask: helper library needs this info from application to know which all ethernet ports it can use. This is determined by the application and has to be communicated to the helper library. This can be made as params passed to the application, but eth_portmask will be the only member in it, as of now.

With the above use case, do you recommend any different structure layout?
  

Patch

diff --git a/lib/librte_eventdev/rte_eventdev_version.map b/lib/librte_eventdev/rte_eventdev_version.map
index 95fd089..1199064 100644
--- a/lib/librte_eventdev/rte_eventdev_version.map
+++ b/lib/librte_eventdev/rte_eventdev_version.map
@@ -128,4 +128,6 @@  EXPERIMENTAL {
 
 	rte_event_eth_rx_adapter_cb_register;
 	rte_event_eth_rx_adapter_stats_get;
+	rte_eventmode_helper_print_options_list;
+	rte_eventmode_helper_print_options_description;
 };
diff --git a/lib/librte_eventdev/rte_eventmode_helper.c b/lib/librte_eventdev/rte_eventmode_helper.c
index f47970e..8119306 100644
--- a/lib/librte_eventdev/rte_eventmode_helper.c
+++ b/lib/librte_eventdev/rte_eventmode_helper.c
@@ -1,7 +1,135 @@ 
 /* SPDX-License-Identifier: BSD-3-Clause
  * Copyright (C) 2019 Marvell International Ltd.
  */
+#include <getopt.h>
 
 #include <rte_eventmode_helper.h>
+#include <rte_malloc.h>
 
 #include "rte_eventmode_helper_internal.h"
+
+#define CMD_LINE_OPT_TRANSFER_MODE	"transfer-mode"
+
+static const char short_options[] =
+	""
+	;
+
+enum {
+	/* long options mapped to a short option */
+
+	/* first long only option value must be >= 256, so that we won't
+	 * conflict with short options
+	 */
+	CMD_LINE_OPT_MIN_NUM = 256,
+	CMD_LINE_OPT_TRANSFER_MODE_NUM,
+};
+
+static const struct option lgopts[] = {
+	{CMD_LINE_OPT_TRANSFER_MODE, 1, 0, CMD_LINE_OPT_TRANSFER_MODE_NUM},
+	{NULL, 0, 0, 0}
+};
+
+/* Internal functions */
+
+static int32_t
+internal_parse_decimal(const char *str)
+{
+	char *end = NULL;
+	unsigned long num;
+
+	num = strtoul(str, &end, 10);
+	if ((str[0] == '\0') || (end == NULL) || (*end != '\0'))
+		return -1;
+
+	return num;
+}
+
+/* Global functions */
+
+void __rte_experimental
+rte_eventmode_helper_print_options_list(void)
+{
+	fprintf(stderr, " --"
+		" [--transfer-mode MODE]"
+		);
+}
+
+void __rte_experimental
+rte_eventmode_helper_print_options_description(void)
+{
+	fprintf(stderr,
+		"  --transfer-mode MODE\n"
+		"               0: Packet transfer via polling (default)\n"
+		"               1: Packet transfer via eventdev\n"
+		"\n");
+}
+
+static int
+em_parse_transfer_mode(struct rte_eventmode_helper_conf *conf,
+		const char *optarg)
+{
+	int32_t parsed_dec;
+
+	parsed_dec = internal_parse_decimal(optarg);
+	if (parsed_dec != RTE_EVENTMODE_HELPER_PKT_TRANSFER_MODE_POLL &&
+	    parsed_dec != RTE_EVENTMODE_HELPER_PKT_TRANSFER_MODE_EVENT) {
+		RTE_EM_HLPR_LOG_ERR("Unsupported packet transfer mode");
+		return -1;
+	}
+	conf->mode = parsed_dec;
+	return 0;
+}
+
+static void
+em_initialize_helper_conf(struct rte_eventmode_helper_conf *conf)
+{
+	/* Set default conf */
+
+	/* Packet transfer mode: poll */
+	conf->mode = RTE_EVENTMODE_HELPER_PKT_TRANSFER_MODE_POLL;
+}
+
+struct rte_eventmode_helper_conf *
+rte_eventmode_helper_parse_args(int argc, char **argv)
+{
+	int32_t opt, ret;
+	struct rte_eventmode_helper_conf *conf = NULL;
+
+	/* Allocate memory for conf */
+	conf = rte_zmalloc("eventmode-helper-conf",
+			sizeof(struct rte_eventmode_helper_conf),
+			RTE_CACHE_LINE_SIZE);
+	if (conf == NULL) {
+		RTE_EM_HLPR_LOG_ERR(
+			"Failed allocating memory for eventmode helper conf");
+			goto err;
+	}
+
+	/* Initialize conf with default values */
+	em_initialize_helper_conf(conf);
+
+	while ((opt = getopt_long(argc, argv, short_options,
+				lgopts, NULL)) != EOF) {
+		switch (opt) {
+
+		/* Packet transfer mode */
+		case CMD_LINE_OPT_TRANSFER_MODE_NUM:
+			ret = em_parse_transfer_mode(conf, optarg);
+			if (ret < 0) {
+				RTE_EM_HLPR_LOG_ERR(
+					"Invalid packet transfer mode");
+				goto err;
+			}
+			break;
+		default:
+			goto err;
+		}
+	}
+	return conf;
+
+err:
+	if (conf != NULL)
+		rte_free(conf);
+
+	return NULL;
+}
diff --git a/lib/librte_eventdev/rte_eventmode_helper.h b/lib/librte_eventdev/rte_eventmode_helper.h
index d32cd00..2a0cb30 100644
--- a/lib/librte_eventdev/rte_eventmode_helper.h
+++ b/lib/librte_eventdev/rte_eventmode_helper.h
@@ -8,6 +8,57 @@ 
 extern "C" {
 #endif
 
+#include <rte_compat.h>
+
+/* Packet transfer mode of the application */
+enum rte_eventmode_helper_pkt_transfer_mode {
+	RTE_EVENTMODE_HELPER_PKT_TRANSFER_MODE_POLL = 0,
+	RTE_EVENTMODE_HELPER_PKT_TRANSFER_MODE_EVENT,
+};
+
+struct rte_eventmode_helper_conf {
+	enum rte_eventmode_helper_pkt_transfer_mode mode;
+		/**< Packet transfer mode of the application */
+	void *mode_params;
+		/**< Mode specific parameters */
+};
+
+/* Common helper functions for command line parsing */
+
+/**
+ * Print event mode options list
+ *
+ */
+void __rte_experimental
+rte_eventmode_helper_print_options_list(void);
+
+/**
+ * Print event mode options description
+ *
+ */
+void __rte_experimental
+rte_eventmode_helper_print_options_description(void);
+
+/**
+ * Parse event mode arguments
+ *
+ * The application can call this function in it's argument parsing routine to
+ * parse the event mode specific args and create the conf accordingly. This
+ * function is to be executed on the MASTER lcore only.
+ *
+ * @param argc
+ *   A non-negative value. If it is greater than 0, the array members
+ *   for argv[0] through argv[argc] (non-inclusive) shall contain pointers
+ *   to strings.
+ * @param argv
+ *   An array of strings. The contents of the array, as well as the strings
+ *   which are pointed to by the array, may be modified by this function.
+ * @return
+ *   Configuration generated by parsing the event mode args.
+ */
+struct rte_eventmode_helper_conf *
+rte_eventmode_helper_parse_args(int argc, char **argv);
+
 #ifdef __cplusplus
 }
 #endif