[PATCH v5 4/5] test/graph_feature_arc: add functional tests

Stephen Hemminger stephen at networkplumber.org
Mon Oct 14 21:54:17 CEST 2024


On Mon, 14 Oct 2024 20:03:57 +0530
Nitin Saxena <nsaxena at marvell.com> wrote:

> Added functional unit test case for verifying feature arc control plane
> and fast path APIs
> 
> How to run:
> $ echo "graph_feature_arc_autotest" | ./bin/dpdk-test
> 
> Signed-off-by: Nitin Saxena <nsaxena at marvell.com>

With current upstream kernel checkpatch additional warnings:


WARNING:MACRO_ARG_UNUSED: Argument 'idx' is not used in function-like macro
#217: FILE: app/test/test_graph_feature_arc.c:186:
+#define R(idx, node, node_cookie) {				\
+		if (!strcmp(child, node)) {			\
+			user_data += node_cookie;		\
+		}						\
+	}

WARNING:MACRO_ARG_UNUSED: Argument 'user_data' is not used in function-like macro
#272: FILE: app/test/test_graph_feature_arc.c:241:
+#define R(idx, _name, user_data) {			\
+		if (!strcmp(node->name, _name)) {	\
+			priv->node_index = idx;		\
+		}					\
+	}


Personally, using macros to generate tests like this can get confusing.


More information about the dev mailing list