提交 4960cabf 编写于 作者: Y Yufeng Mo 提交者: David S. Miller

net: hns3: rename macro HCLGE_MAX_NCL_CONFIG_LENGTH

The name of macro HCLGE_MAX_NCL_CONFIG_LENGTH is inaccurate,
this patch renames it to HCLGE_NCL_CONFIG_LENGTH_IN_EACH_CMD.
Signed-off-by: NYufeng Mo <moyufeng@huawei.com>
Signed-off-by: NHuazhong Tan <tanhuazhong@huawei.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 72fa4904
...@@ -1137,7 +1137,7 @@ static void hclge_dbg_dump_ncl_config(struct hclge_dev *hdev, ...@@ -1137,7 +1137,7 @@ static void hclge_dbg_dump_ncl_config(struct hclge_dev *hdev,
const char *cmd_buf) const char *cmd_buf)
{ {
#define HCLGE_MAX_NCL_CONFIG_OFFSET 4096 #define HCLGE_MAX_NCL_CONFIG_OFFSET 4096
#define HCLGE_MAX_NCL_CONFIG_LENGTH (20 + 24 * 4) #define HCLGE_NCL_CONFIG_LENGTH_IN_EACH_CMD (20 + 24 * 4)
struct hclge_desc desc[HCLGE_CMD_NCL_CONFIG_BD_NUM]; struct hclge_desc desc[HCLGE_CMD_NCL_CONFIG_BD_NUM];
int bd_num = HCLGE_CMD_NCL_CONFIG_BD_NUM; int bd_num = HCLGE_CMD_NCL_CONFIG_BD_NUM;
...@@ -1161,8 +1161,8 @@ static void hclge_dbg_dump_ncl_config(struct hclge_dev *hdev, ...@@ -1161,8 +1161,8 @@ static void hclge_dbg_dump_ncl_config(struct hclge_dev *hdev,
while (length > 0) { while (length > 0) {
data0 = offset; data0 = offset;
if (length >= HCLGE_MAX_NCL_CONFIG_LENGTH) if (length >= HCLGE_NCL_CONFIG_LENGTH_IN_EACH_CMD)
data0 |= HCLGE_MAX_NCL_CONFIG_LENGTH << 16; data0 |= HCLGE_NCL_CONFIG_LENGTH_IN_EACH_CMD << 16;
else else
data0 |= length << 16; data0 |= length << 16;
ret = hclge_dbg_cmd_send(hdev, desc, data0, bd_num, ret = hclge_dbg_cmd_send(hdev, desc, data0, bd_num,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册