Hi Tian,
FYI, the error/warning still remains.
tree: https://gitee.com/openeuler/kernel.git OLK-5.10 head: 412556141b3c12f2f160acc3a09a40c937837ee3 commit: 26f6cbad1a22ab7b8d77b0f84aae9c3aa8e473bc [14233/30000] net: hns3: add supports pfc storm detection and suppression config: arm64-defconfig (https://download.01.org/0day-ci/archive/20241027/202410271124.8ms7Ma15-lkp@i...) compiler: aarch64-linux-gcc (GCC) 14.1.0 reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20241027/202410271124.8ms7Ma15-lkp@i...)
If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags | Reported-by: kernel test robot lkp@intel.com | Closes: https://lore.kernel.org/oe-kbuild-all/202410271124.8ms7Ma15-lkp@intel.com/
All warnings (new ones prefixed by >>):
In file included from drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.h:13, from drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_ext.c:4: drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_ext.c: In function 'hclge_set_pfc_storm_para':
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_ext.c:29:43: warning: implicit conversion from 'enum hclge_ext_opcode_type' to 'enum hclge_opcode_type' [-Wenum-conversion]
29 | hclge_cmd_setup_basic_desc(&desc, HCLGE_OPC_CFG_PAUSE_STORM_PARA, | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h:24:47: note: in definition of macro 'hclge_cmd_setup_basic_desc' 24 | hclge_comm_cmd_setup_basic_desc(desc, opcode, is_read) | ^~~~~~ drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_ext.c: In function 'hclge_get_pfc_storm_para': drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_ext.c:57:43: warning: implicit conversion from 'enum hclge_ext_opcode_type' to 'enum hclge_opcode_type' [-Wenum-conversion] 57 | hclge_cmd_setup_basic_desc(&desc, HCLGE_OPC_CFG_PAUSE_STORM_PARA, true); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h:24:47: note: in definition of macro 'hclge_cmd_setup_basic_desc' 24 | hclge_comm_cmd_setup_basic_desc(desc, opcode, is_read) | ^~~~~~
vim +29 drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_ext.c
17 18 static int hclge_set_pfc_storm_para(struct hclge_dev *hdev, void *data, 19 size_t length) 20 { 21 struct hclge_pfc_storm_para_cmd *para_cmd; 22 struct hnae3_pfc_storm_para *para; 23 struct hclge_desc desc; 24 int ret; 25 26 if (length != sizeof(struct hnae3_pfc_storm_para)) 27 return -EINVAL; 28
29 hclge_cmd_setup_basic_desc(&desc, HCLGE_OPC_CFG_PAUSE_STORM_PARA,
30 false); 31 para = (struct hnae3_pfc_storm_para *)data; 32 para_cmd = (struct hclge_pfc_storm_para_cmd *)desc.data; 33 para_cmd->dir = cpu_to_le32(para->dir); 34 para_cmd->enable = cpu_to_le32(para->enable); 35 para_cmd->period_ms = cpu_to_le32(para->period_ms); 36 para_cmd->times = cpu_to_le32(para->times); 37 para_cmd->recovery_period_ms = cpu_to_le32(para->recovery_period_ms); 38 39 ret = hclge_cmd_send(&hdev->hw, &desc, 1); 40 if (ret) 41 dev_err(&hdev->pdev->dev, 42 "failed to set pfc storm para, ret = %d\n", ret); 43 return ret; 44 } 45