[dpdk-dev] [PATCH v3 01/29] graph: define the public API for graph support

Wang, Xiao W xiao.w.wang at intel.com
Fri Apr 3 11:26:44 CEST 2020


Hi Jerin,

Found small typos on this patch. Please check comments inline.

Best Regards,
Xiao

> -----Original Message-----
> From: dev <dev-bounces at dpdk.org> On Behalf Of jerinj at marvell.com
> Sent: Wednesday, April 1, 2020 3:29 AM
> To: Thomas Monjalon <thomas at monjalon.net>; Richardson, Bruce
> <bruce.richardson at intel.com>; Mcnamara, John <john.mcnamara at intel.com>;
> Kovacevic, Marko <marko.kovacevic at intel.com>; Jerin Jacob
> <jerinj at marvell.com>; Kiran Kumar K <kirankumark at marvell.com>
> Cc: dev at dpdk.org; david.marchand at redhat.com; mdr at ashroe.eu;
> mattias.ronnblom at ericsson.com; pbhagavatula at marvell.com;
> ndabilpuram at marvell.com
> Subject: [dpdk-dev] [PATCH v3 01/29] graph: define the public API for graph
> support
> 
> From: Jerin Jacob <jerinj at marvell.com>
> 
> Graph architecture abstracts the data processing functions as
> "node" and "link" them together to create a complex "graph" to enable
> reusable/modular data processing functions.
> 
> These APIs enables graph framework operations such as create, lookup,
> dump and destroy on graph and node operations such as clone,
> edge update, and edge shrink, etc. The API also allows creating the
> stats cluster to monitor per graph and per node stats.
> 
> This patch defines the public API for graph support.
> This patch also adds support for the build infrastructure and
> update the MAINTAINERS file for the graph subsystem.
> 
> Signed-off-by: Jerin Jacob <jerinj at marvell.com>
> Signed-off-by: Kiran Kumar K <kirankumark at marvell.com>
> Signed-off-by: Pavan Nikhilesh <pbhagavatula at marvell.com>
> Signed-off-by: Nithin Dabilpuram <ndabilpuram at marvell.com>
> ---
>  MAINTAINERS                            |   5 +
>  config/common_base                     |   7 +
>  config/rte_config.h                    |   4 +
>  doc/api/doxy-api-index.md              |   1 +
>  doc/api/doxy-api.conf.in               |   1 +
>  lib/Makefile                           |   3 +
>  lib/librte_graph/Makefile              |  22 +
>  lib/librte_graph/graph.c               |   5 +
>  lib/librte_graph/meson.build           |  11 +
>  lib/librte_graph/rte_graph.h           | 786 +++++++++++++++++++++++++
>  lib/librte_graph/rte_graph_version.map |   3 +
>  lib/meson.build                        |   2 +-
>  mk/rte.app.mk                          |   1 +
>  13 files changed, 850 insertions(+), 1 deletion(-)
>  create mode 100644 lib/librte_graph/Makefile
>  create mode 100644 lib/librte_graph/graph.c
>  create mode 100644 lib/librte_graph/meson.build
>  create mode 100644 lib/librte_graph/rte_graph.h
>  create mode 100644 lib/librte_graph/rte_graph_version.map
> 
> diff --git a/MAINTAINERS b/MAINTAINERS
> index db235c2cc..bc7085983 100644
> --- a/MAINTAINERS
> +++ b/MAINTAINERS
> @@ -1469,6 +1469,11 @@ F: examples/bpf/
>  F: app/test/test_bpf.c
>  F: doc/guides/prog_guide/bpf_lib.rst
> 
> +Graph - EXPERIMENTAL
> +M: Jerin Jacob <jerinj at marvell.com>
> +M: Kiran Kumar K <kirankumark at marvell.com>
> +F: lib/librte_graph/
> +
[...]

> +
> +/**
> + * @warning
> + * @b EXPERIMENTAL: this API may change without prior notice
> + *
> + * Create graph stats cluster to aggregate runtime node stats.
> + *
> + * @param prm
> + *   Parameters including file pointer to dump stats,
> + *   Graph pattern to create cluster and callback function.
> + *
> + * @return
> + *   Valid pointer on success, NULL otherwise.
> + */
> +__rte_experimental
> +struct rte_graph_cluster_stats *rte_graph_cluster_stats_create(
> +			const struct rte_graph_cluster_stats_param *prm);
> +
> +/**
> + * @warning
> + * @b EXPERIMENTAL: this API may change without prior notice
> + *
> + * Destroy cluster stats.
> + *
> + * @param stat
> + *    Valid cluster pointer to destroy.
> + *
This empty line can be removed.

> + */
> +__rte_experimental
> +void rte_graph_cluster_stats_destroy(struct rte_graph_cluster_stats *stat);
> +
> +/**
> + * @warning
> + * @b EXPERIMENTAL: this API may change without prior notice
[...]

> +#define RTE_NODE_REGISTER(node)                                                \
> +	RTE_INIT(rte_node_register_##node)                                     \
> +	{                                                                      \
> +		node.parent_id = RTE_NODE_ID_INVALID;                          \
> +		node.id = __rte_node_register(&node);                          \
> +	}
> +
> +/**
> + * @warning
> + * @b EXPERIMENTAL: this API may change without prior notice
> + *
> + * Clone a node from static node(node created from RTE_NODE_REGISTER).
> + *
> + * @param id
> + *   Static node id to clone from.
> + * @param name
> + *   Name of the new node. The library prepends the parent node name to the
> + * user-specified the name. The final node name will be,
Change it to "the user-specified name".



More information about the dev mailing list