* [dpdk-test-report] |WARNING| pw53792 [PATCH v2 07/11] net/hinic/base: add various headers
[not found] <beb73fa26d411d96692a01334d1b66a2cde19899.1559100649.git.xuanziyang2@huawei.com>
@ 2019-05-29 3:40 ` checkpatch
0 siblings, 0 replies; only message in thread
From: checkpatch @ 2019-05-29 3:40 UTC (permalink / raw)
To: test-report; +Cc: Ziyang Xuan
Test-Label: checkpatch
Test-Status: WARNING
http://dpdk.org/patch/53792
_coding style issues_
CHECK:MACRO_ARG_REUSE: Macro argument reuse 'Y' - possible side-effects?
#121: FILE: drivers/net/hinic/base/hinic_compat.h:78:
+#define DIV_ROUND_UP(X, Y) (((X) + ((Y) - 1)) / (Y))
CHECK:MACRO_ARG_REUSE: Macro argument reuse 'Y' - possible side-effects?
#124: FILE: drivers/net/hinic/base/hinic_compat.h:81:
+#define ROUND_UP(X, Y) (DIV_ROUND_UP(X, Y) * (Y))
CHECK:CONCATENATED_STRING: Concatenated strings should use spaces between elements
#138: FILE: drivers/net/hinic/base/hinic_compat.h:95:
+ HINIC_DRIVER_NAME": " fmt "
", ##args)
CHECK:MACRO_ARG_REUSE: Macro argument reuse 'wq' - possible side-effects?
#1088: FILE: drivers/net/hinic/base/hinic_qe_def.h:287:
+#define WQ_SIZE(wq) (u32)((u64)(wq)->q_depth * (wq)->wqebb_size)
CHECK:MACRO_ARG_REUSE: Macro argument reuse 'wq' - possible side-effects?
#1090: FILE: drivers/net/hinic/base/hinic_qe_def.h:289:
+#define WQE_PAGE_NUM(wq, idx) (((idx) >> ((wq)->wqebbs_per_page_shift)) & \
+ ((wq)->num_q_pages - 1))
CHECK:MACRO_ARG_REUSE: Macro argument reuse 'wq' - possible side-effects?
#1093: FILE: drivers/net/hinic/base/hinic_qe_def.h:292:
+#define WQE_PAGE_OFF(wq, idx) ((u64)((wq)->wqebb_size) * \
+ ((idx) & ((wq)->num_wqebbs_per_page - 1)))
CHECK:MACRO_ARG_REUSE: Macro argument reuse 'wq' - possible side-effects?
#1098: FILE: drivers/net/hinic/base/hinic_qe_def.h:297:
+#define WQ_PAGE_ADDR(wq, idx) \
+ (u8 *)(*(u64 *)((u64)((wq)->shadow_block_vaddr) + \
+ (WQE_PAGE_NUM(wq, idx) << WQ_PAGE_ADDR_SIZE_SHIFT)))
CHECK:MACRO_ARG_REUSE: Macro argument reuse 'wq' - possible side-effects?
#1114: FILE: drivers/net/hinic/base/hinic_qe_def.h:313:
+#define WQ_BASE_VADDR(wqs, wq) \
+ (u64 *)(((u64)((wqs)->page_vaddr[(wq)->page_idx])) \
+ + (wq)->block_idx * WQ_BLOCK_SIZE)
CHECK:MACRO_ARG_REUSE: Macro argument reuse 'wq' - possible side-effects?
#1118: FILE: drivers/net/hinic/base/hinic_qe_def.h:317:
+#define WQ_BASE_PADDR(wqs, wq) (((wqs)->page_paddr[(wq)->page_idx]) \
+ + (u64)(wq)->block_idx * WQ_BLOCK_SIZE)
CHECK:MACRO_ARG_REUSE: Macro argument reuse 'wq' - possible side-effects?
#1121: FILE: drivers/net/hinic/base/hinic_qe_def.h:320:
+#define WQ_BASE_ADDR(wqs, wq) \
+ (u64 *)(((u64)((wqs)->shadow_page_vaddr[(wq)->page_idx])) \
+ + (wq)->block_idx * WQ_BLOCK_SIZE)
CHECK:MACRO_ARG_REUSE: Macro argument reuse 'wq' - possible side-effects?
#1139: FILE: drivers/net/hinic/base/hinic_qe_def.h:338:
+#define WQE_SHADOW_PAGE(wq, wqe) \
+ (u16)(((unsigned long)(wqe) - (unsigned long)(wq)->shadow_wqe) \
+ / (wq)->max_wqe_size)
CHECK:MACRO_ARG_REUSE: Macro argument reuse 'wqe' - possible side-effects?
#1143: FILE: drivers/net/hinic/base/hinic_qe_def.h:342:
+#define WQE_IN_RANGE(wqe, start, end) \
+ (((unsigned long)(wqe) >= (unsigned long)(start)) && \
+ ((unsigned long)(wqe) < (unsigned long)(end)))
CHECK:MACRO_ARG_REUSE: Macro argument reuse 'rxq' - possible side-effects?
#1392: FILE: drivers/net/hinic/hinic_pmd_rx.h:12:
+#define HINIC_GET_RQ_LOCAL_CI(rxq) \
+ (((rxq)->wq->cons_idx) & HINIC_GET_RQ_WQE_MASK(rxq))
CHECK:MACRO_ARG_REUSE: Macro argument reuse 'rxq' - possible side-effects?
#1395: FILE: drivers/net/hinic/hinic_pmd_rx.h:15:
+#define HINIC_GET_RQ_LOCAL_PI(rxq) \
+ (((rxq)->wq->prod_idx) & HINIC_GET_RQ_WQE_MASK(rxq))
CHECK:MACRO_ARG_REUSE: Macro argument reuse 'rxq' - possible side-effects?
#1398: FILE: drivers/net/hinic/hinic_pmd_rx.h:18:
+#define HINIC_UPDATE_RQ_LOCAL_CI(rxq, wqebb_cnt) \
+ do { \
+ (rxq)->wq->cons_idx += (wqebb_cnt); \
+ (rxq)->wq->delta += (wqebb_cnt); \
+ } while (0)
CHECK:MACRO_ARG_REUSE: Macro argument reuse 'wqebb_cnt' - possible side-effects?
#1398: FILE: drivers/net/hinic/hinic_pmd_rx.h:18:
+#define HINIC_UPDATE_RQ_LOCAL_CI(rxq, wqebb_cnt) \
+ do { \
+ (rxq)->wq->cons_idx += (wqebb_cnt); \
+ (rxq)->wq->delta += (wqebb_cnt); \
+ } while (0)
CHECK:MACRO_ARG_REUSE: Macro argument reuse 'rxq' - possible side-effects?
#1407: FILE: drivers/net/hinic/hinic_pmd_rx.h:27:
+#define HINIC_UPDATE_RQ_HW_PI(rxq, pi) \
+ (*((rxq)->pi_virt_addr) = \
+ cpu_to_be16((pi) & HINIC_GET_RQ_WQE_MASK(rxq)))
CHECK:MACRO_ARG_REUSE: Macro argument reuse 'txq' - possible side-effects?
#1536: FILE: drivers/net/hinic/hinic_pmd_tx.h:15:
+#define HINIC_GET_SQ_HW_CI(txq) \
+ ((be16_to_cpu(*(txq)->cons_idx_addr)) & HINIC_GET_SQ_WQE_MASK(txq))
CHECK:MACRO_ARG_REUSE: Macro argument reuse 'txq' - possible side-effects?
#1539: FILE: drivers/net/hinic/hinic_pmd_tx.h:18:
+#define HINIC_GET_SQ_LOCAL_CI(txq) \
+ (((txq)->wq->cons_idx) & HINIC_GET_SQ_WQE_MASK(txq))
CHECK:MACRO_ARG_REUSE: Macro argument reuse 'txq' - possible side-effects?
#1542: FILE: drivers/net/hinic/hinic_pmd_tx.h:21:
+#define HINIC_UPDATE_SQ_LOCAL_CI(txq, wqebb_cnt) \
+ do { \
+ (txq)->wq->cons_idx += wqebb_cnt; \
+ (txq)->wq->delta += wqebb_cnt; \
+ } while (0)
CHECK:MACRO_ARG_REUSE: Macro argument reuse 'wqebb_cnt' - possible side-effects?
#1542: FILE: drivers/net/hinic/hinic_pmd_tx.h:21:
+#define HINIC_UPDATE_SQ_LOCAL_CI(txq, wqebb_cnt) \
+ do { \
+ (txq)->wq->cons_idx += wqebb_cnt; \
+ (txq)->wq->delta += wqebb_cnt; \
+ } while (0)
CHECK:MACRO_ARG_REUSE: Macro argument reuse 'txq' - possible side-effects?
#1551: FILE: drivers/net/hinic/hinic_pmd_tx.h:30:
+#define HINIC_IS_SQ_EMPTY(txq) \
+ (((txq)->wq->delta) == ((txq)->q_depth))
CHECK:MACRO_ARG_REUSE: Macro argument reuse 'txq' - possible side-effects?
#1554: FILE: drivers/net/hinic/hinic_pmd_tx.h:33:
+#define HINIC_GET_WQ_TAIL(txq) ((txq)->wq->queue_buf_vaddr + \
+ (txq)->wq->wq_buf_size)
total: 0 errors, 0 warnings, 23 checks, 1545 lines checked
^ permalink raw reply [flat|nested] only message in thread