automatic DPDK test reports
 help / color / mirror / Atom feed
* [dpdk-test-report] |WARNING| pw57843 [PATCH 02/22] net/hns3: add some definitions for data structure and macro
       [not found] <1566568031-45991-3-git-send-email-xavier.huwei@huawei.com>
@ 2019-08-23 13:50 ` checkpatch
  0 siblings, 0 replies; only message in thread
From: checkpatch @ 2019-08-23 13:50 UTC (permalink / raw)
  To: test-report; +Cc: Wei Hu (Xavier)

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

_coding style issues_


CHECK:MACRO_ARG_REUSE: Macro argument reuse 'hw' - possible side-effects?
#532: FILE: drivers/net/hns3/hns3_ethdev.h:496:
+#define HNS3_DEV_HW_TO_ADAPTER(hw) \
+	container_of(hw, struct hns3_adapter, hw)

CHECK:MACRO_ARG_REUSE: Macro argument reuse 'origin' - possible side-effects?
#535: FILE: drivers/net/hns3/hns3_ethdev.h:499:
+#define hns3_set_field(origin, mask, shift, val) \
+	do { \
+		(origin) &= (~(mask)); \
+		(origin) |= ((val) << (shift)) & (mask); \
+	} while (0)

CHECK:MACRO_ARG_REUSE: Macro argument reuse 'mask' - possible side-effects?
#535: FILE: drivers/net/hns3/hns3_ethdev.h:499:
+#define hns3_set_field(origin, mask, shift, val) \
+	do { \
+		(origin) &= (~(mask)); \
+		(origin) |= ((val) << (shift)) & (mask); \
+	} while (0)

CHECK:MACRO_ARG_REUSE: Macro argument reuse 'shift' - possible side-effects?
#542: FILE: drivers/net/hns3/hns3_ethdev.h:506:
+#define hns3_set_bit(origin, shift, val) \
+	hns3_set_field((origin), (0x1UL << (shift)), (shift), (val))

CHECK:MACRO_ARG_REUSE: Macro argument reuse 'shift' - possible side-effects?
#544: FILE: drivers/net/hns3/hns3_ethdev.h:508:
+#define hns3_get_bit(origin, shift) \
+	hns3_get_field((origin), (0x1UL << (shift)), (shift))

CHECK:MACRO_ARG_REUSE: Macro argument reuse 'y' - possible side-effects?
#564: FILE: drivers/net/hns3/hns3_ethdev.h:528:
+#define roundup(x, y) ((((x) + ((y) - 1)) / (y)) * (y))

CHECK:MACRO_ARG_REUSE: Macro argument reuse 'x' - possible side-effects?
#565: FILE: drivers/net/hns3/hns3_ethdev.h:529:
+#define rounddown(x, y) ((x) - ((x) % (y)))

CHECK:MACRO_ARG_REUSE: Macro argument reuse 'd' - possible side-effects?
#567: FILE: drivers/net/hns3/hns3_ethdev.h:531:
+#define DIV_ROUND_UP(n, d) (((n) + (d) - 1) / (d))

CHECK:MACRO_ARG_REUSE: Macro argument reuse 'x' - possible side-effects?
#590: FILE: drivers/net/hns3/hns3_ethdev.h:554:
+#define ARRAY_SIZE(x) (sizeof(x) / sizeof((x)[0]))

CHECK:MACRO_ARG_REUSE: Macro argument reuse 'act' - possible side-effects?
#592: FILE: drivers/net/hns3/hns3_ethdev.h:556:
+#define NEXT_ITEM_OF_ACTION(act, actions, index)                        \
+	do {								\
+		act = (actions) + (index);				\
+		while (act->type == RTE_FLOW_ACTION_TYPE_VOID) {	\
+			(index)++;					\
+			act = actions + index;				\
+		}							\
+	} while (0)

CHECK:MACRO_ARG_REUSE: Macro argument reuse 'actions' - possible side-effects?
#592: FILE: drivers/net/hns3/hns3_ethdev.h:556:
+#define NEXT_ITEM_OF_ACTION(act, actions, index)                        \
+	do {								\
+		act = (actions) + (index);				\
+		while (act->type == RTE_FLOW_ACTION_TYPE_VOID) {	\
+			(index)++;					\
+			act = actions + index;				\
+		}							\
+	} while (0)

CHECK:MACRO_ARG_REUSE: Macro argument reuse 'index' - possible side-effects?
#592: FILE: drivers/net/hns3/hns3_ethdev.h:556:
+#define NEXT_ITEM_OF_ACTION(act, actions, index)                        \
+	do {								\
+		act = (actions) + (index);				\
+		while (act->type == RTE_FLOW_ACTION_TYPE_VOID) {	\
+			(index)++;					\
+			act = actions + index;				\
+		}							\
+	} while (0)

total: 0 errors, 0 warnings, 12 checks, 609 lines checked

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2019-08-23 13:51 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <1566568031-45991-3-git-send-email-xavier.huwei@huawei.com>
2019-08-23 13:50 ` [dpdk-test-report] |WARNING| pw57843 [PATCH 02/22] net/hns3: add some definitions for data structure and macro checkpatch

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).