[dpdk-test-report] |WARNING| pw64756 [PATCH] net/ice: fix flow fdir/switch memory leak.

checkpatch at dpdk.org checkpatch at dpdk.org
Thu Jan 16 09:02:19 CET 2020


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

_coding style issues_


CHECK:MACRO_ARG_REUSE: Macro argument reuse 'pos' - possible side-effects?
#82: FILE: drivers/net/ice/base/ice_osdep.h:346:
+#define LIST_FOR_EACH_ENTRY_SAFE(pos, tmp, head, type, member)		       \
+	for ((pos) = (head)->lh_first ?					       \
+		     container_of((head)->lh_first, struct type, member) :     \
+		     0,                                                        \
+		     (tmp) = (pos) == 0 ? 0 : ((pos)->member.next.le_next ?    \
+		     container_of((pos)->member.next.le_next, struct type,     \
+				  member) :				       \
+		     0);						       \
+	     (pos);							       \
+	     (pos) = (tmp),						       \
+	     (tmp) = (pos) == 0 ? 0 : ((tmp)->member.next.le_next ?	       \
+		     container_of((pos)->member.next.le_next, struct type,     \
+				  member) :				       \
+		     0))

CHECK:MACRO_ARG_REUSE: Macro argument reuse 'tmp' - possible side-effects?
#82: FILE: drivers/net/ice/base/ice_osdep.h:346:
+#define LIST_FOR_EACH_ENTRY_SAFE(pos, tmp, head, type, member)		       \
+	for ((pos) = (head)->lh_first ?					       \
+		     container_of((head)->lh_first, struct type, member) :     \
+		     0,                                                        \
+		     (tmp) = (pos) == 0 ? 0 : ((pos)->member.next.le_next ?    \
+		     container_of((pos)->member.next.le_next, struct type,     \
+				  member) :				       \
+		     0);						       \
+	     (pos);							       \
+	     (pos) = (tmp),						       \
+	     (tmp) = (pos) == 0 ? 0 : ((tmp)->member.next.le_next ?	       \
+		     container_of((pos)->member.next.le_next, struct type,     \
+				  member) :				       \
+		     0))

CHECK:MACRO_ARG_REUSE: Macro argument reuse 'head' - possible side-effects?
#82: FILE: drivers/net/ice/base/ice_osdep.h:346:
+#define LIST_FOR_EACH_ENTRY_SAFE(pos, tmp, head, type, member)		       \
+	for ((pos) = (head)->lh_first ?					       \
+		     container_of((head)->lh_first, struct type, member) :     \
+		     0,                                                        \
+		     (tmp) = (pos) == 0 ? 0 : ((pos)->member.next.le_next ?    \
+		     container_of((pos)->member.next.le_next, struct type,     \
+				  member) :				       \
+		     0);						       \
+	     (pos);							       \
+	     (pos) = (tmp),						       \
+	     (tmp) = (pos) == 0 ? 0 : ((tmp)->member.next.le_next ?	       \
+		     container_of((pos)->member.next.le_next, struct type,     \
+				  member) :				       \
+		     0))

CHECK:MACRO_ARG_REUSE: Macro argument reuse 'member' - possible side-effects?
#82: FILE: drivers/net/ice/base/ice_osdep.h:346:
+#define LIST_FOR_EACH_ENTRY_SAFE(pos, tmp, head, type, member)		       \
+	for ((pos) = (head)->lh_first ?					       \
+		     container_of((head)->lh_first, struct type, member) :     \
+		     0,                                                        \
+		     (tmp) = (pos) == 0 ? 0 : ((pos)->member.next.le_next ?    \
+		     container_of((pos)->member.next.le_next, struct type,     \
+				  member) :				       \
+		     0);						       \
+	     (pos);							       \
+	     (pos) = (tmp),						       \
+	     (tmp) = (pos) == 0 ? 0 : ((tmp)->member.next.le_next ?	       \
+		     container_of((pos)->member.next.le_next, struct type,     \
+				  member) :				       \
+		     0))

total: 0 errors, 0 warnings, 4 checks, 95 lines checked


More information about the test-report mailing list