[v5,1/5] net/hinic/base: fix code style check issue

Message ID bdec1ffacb6caa5565338262716c4abe3f518fb2.1572613507.git.cloud.wangxiaoyun@huawei.com (mailing list archive)
State Accepted, archived
Delegated to: Ferruh Yigit
Headers
Series Some fixes for hinic PMD driver |

Checks

Context Check Description
ci/iol-intel-Performance fail Performance Testing issues
ci/iol-compilation success Compile Testing PASS
ci/Intel-compilation success Compilation OK
ci/iol-mellanox-Performance success Performance Testing PASS
ci/checkpatch success coding style OK

Commit Message

Wangxiaoyun (Cloud) Nov. 1, 2019, 1:36 p.m. UTC
  This patch fixs the code style check issue for MACRO_ARG_REUSE.

Fixes: b8582d051af1 ("net/hinic/base: add HW interfaces for SR-IOV")
Signed-off-by: Xiaoyun wang <cloud.wangxiaoyun@huawei.com>
---
 drivers/net/hinic/base/hinic_pmd_mbox.c | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)
  

Patch

diff --git a/drivers/net/hinic/base/hinic_pmd_mbox.c b/drivers/net/hinic/base/hinic_pmd_mbox.c
index bdb94e9..3d3c1bc 100644
--- a/drivers/net/hinic/base/hinic_pmd_mbox.c
+++ b/drivers/net/hinic/base/hinic_pmd_mbox.c
@@ -131,11 +131,9 @@  enum hinic_mbox_tx_status {
 #define MBOX_RESPONSE_ERROR		0x1
 #define MBOX_MSG_ID_MASK		0xFF
 #define MBOX_MSG_ID(func_to_func)	((func_to_func)->send_msg_id)
-#define MBOX_MSG_ID_INC(func_to_func)	(MBOX_MSG_ID(func_to_func) =	\
-			(MBOX_MSG_ID(func_to_func) + 1) & MBOX_MSG_ID_MASK)
 
 enum hinic_hwif_direction_type {
-	/* driver send msg to up or up send msg to drier*/
+	/* driver send msg to up or up send msg to driver*/
 	HINIC_HWIF_DIRECT_SEND = 0,
 	/* after driver/up send msg to each other, then up/driver ack the msg */
 	HINIC_HWIF_RESPONSE,
@@ -690,7 +688,8 @@  static int hinic_mbox_to_func(struct hinic_mbox_func_to_func *func_to_func,
 	if (err)
 		return err;
 
-	msg_info.msg_id = MBOX_MSG_ID_INC(func_to_func);
+	msg_info.msg_id = (MBOX_MSG_ID(func_to_func) + 1) & MBOX_MSG_ID_MASK;
+	MBOX_MSG_ID(func_to_func) = msg_info.msg_id;
 
 	set_mbox_to_func_event(func_to_func, EVENT_START);