[dpdk-test-report] |WARNING| [PATCH] lpm: rte_lpm_iterate() - iterate through the routes

checkpatch at dpdk.org checkpatch at dpdk.org
Fri Nov 25 07:31:40 CET 2016


Test-Label: checkpatch
Test-Status: WARNING
http://dpdk.org/patch/17257

_coding style issues_


ERROR:GERRIT_CHANGE_ID: Remove Gerrit Change-Id's before submitting upstream.
#56: 
Change-Id: I28ea3d7d92f318988444553ee2bb30b709bcb3b6

WARNING:UNSPECIFIED_INT: Prefer 'unsigned int' to bare use of 'unsigned'
#138: FILE: lib/librte_lpm/rte_lpm_iterate.c:49:
+rte_lpm_iterate(struct rte_lpm_route* const buf, unsigned buflen,

ERROR:POINTER_LOCATION: "foo* const bar" should be "foo * const bar"
#138: FILE: lib/librte_lpm/rte_lpm_iterate.c:49:
+rte_lpm_iterate(struct rte_lpm_route* const buf, unsigned buflen,

ERROR:POINTER_LOCATION: "foo* bar" should be "foo *bar"
#139: FILE: lib/librte_lpm/rte_lpm_iterate.c:50:
+		const struct rte_lpm* lpm,

ERROR:POINTER_LOCATION: "foo* const bar" should be "foo * const bar"
#140: FILE: lib/librte_lpm/rte_lpm_iterate.c:51:
+		struct rte_lpm_cursor* const cursor)

ERROR:POINTER_LOCATION: "foo* bar" should be "foo *bar"
#142: FILE: lib/librte_lpm/rte_lpm_iterate.c:53:
+	struct rte_lpm_route* p = buf;

ERROR:POINTER_LOCATION: "foo* const bar" should be "foo * const bar"
#143: FILE: lib/librte_lpm/rte_lpm_iterate.c:54:
+	struct rte_lpm_route* const end = p + buflen;

ERROR:POINTER_LOCATION: "foo* const bar" should be "foo * const bar"
#145: FILE: lib/librte_lpm/rte_lpm_iterate.c:56:
+	const struct rte_lpm_rule_info* const rinfo = lpm->rule_info;

ERROR:POINTER_LOCATION: "foo* const bar" should be "foo * const bar"
#146: FILE: lib/librte_lpm/rte_lpm_iterate.c:57:
+	const struct rte_lpm_rule* const rtbl = lpm->rules_tbl;

WARNING:UNSPECIFIED_INT: Prefer 'unsigned int' to bare use of 'unsigned'
#148: FILE: lib/librte_lpm/rte_lpm_iterate.c:59:
+	unsigned d = cursor->d;

WARNING:UNSPECIFIED_INT: Prefer 'unsigned int' to bare use of 'unsigned'
#149: FILE: lib/librte_lpm/rte_lpm_iterate.c:60:
+	unsigned n = cursor->n;

ERROR:SPACING: spaces required around that '!=' (ctx:VxV)
#151: FILE: lib/librte_lpm/rte_lpm_iterate.c:62:
+	while(p!=end) {
 	       ^

ERROR:SPACING: space required before the open parenthesis '('
#151: FILE: lib/librte_lpm/rte_lpm_iterate.c:62:
+	while(p!=end) {

ERROR:SPACING: spaces required around that '==' (ctx:VxV)
#152: FILE: lib/librte_lpm/rte_lpm_iterate.c:63:
+		if(d==32) break;
 		    ^

ERROR:SPACING: space required before the open parenthesis '('
#152: FILE: lib/librte_lpm/rte_lpm_iterate.c:63:
+		if(d==32) break;

ERROR:TRAILING_STATEMENTS: trailing statements should be on next line
#152: FILE: lib/librte_lpm/rte_lpm_iterate.c:63:
+		if(d==32) break;

ERROR:SPACING: spaces required around that '>=' (ctx:VxV)
#153: FILE: lib/librte_lpm/rte_lpm_iterate.c:64:
+		if(n>=rinfo[d].used_rules) {
 		    ^

ERROR:SPACING: space required before the open parenthesis '('
#153: FILE: lib/librte_lpm/rte_lpm_iterate.c:64:
+		if(n>=rinfo[d].used_rules) {

WARNING:UNSPECIFIED_INT: Prefer 'unsigned int' to bare use of 'unsigned'
#218: FILE: lib/librte_lpm/rte_lpm_iterate.h:42:
+	unsigned d;

WARNING:UNSPECIFIED_INT: Prefer 'unsigned int' to bare use of 'unsigned'
#219: FILE: lib/librte_lpm/rte_lpm_iterate.h:43:
+	unsigned n;

WARNING:UNSPECIFIED_INT: Prefer 'unsigned int' to bare use of 'unsigned'
#228: FILE: lib/librte_lpm/rte_lpm_iterate.h:52:
+unsigned rte_lpm_iterate(struct rte_lpm_route* buf, unsigned buflen,

WARNING:UNSPECIFIED_INT: Prefer 'unsigned int' to bare use of 'unsigned'
#228: FILE: lib/librte_lpm/rte_lpm_iterate.h:52:
+unsigned rte_lpm_iterate(struct rte_lpm_route* buf, unsigned buflen,

ERROR:POINTER_LOCATION: "foo* bar" should be "foo *bar"
#228: FILE: lib/librte_lpm/rte_lpm_iterate.h:52:
+unsigned rte_lpm_iterate(struct rte_lpm_route* buf, unsigned buflen,

ERROR:POINTER_LOCATION: "foo* bar" should be "foo *bar"
#229: FILE: lib/librte_lpm/rte_lpm_iterate.h:53:
+			 const struct rte_lpm* lpm,

ERROR:POINTER_LOCATION: "foo* bar" should be "foo *bar"
#230: FILE: lib/librte_lpm/rte_lpm_iterate.h:54:
+			 struct rte_lpm_cursor* cursor);

total: 18 errors, 7 warnings, 149 lines checked


More information about the test-report mailing list