tree: https://git.kernel.org/pub/scm/linux/kernel/git/tnguy/next-queue.git dev-queue head: d051d5283b530af3f9627c8e600aa581bc6c1958 commit: 23eb6f4d18624231cd3f57f322814591f38b3837 [12/92] ice: enable FDIR filters from raw binary patterns for VFs config: x86_64-randconfig-161-20240706 (https://download.01.org/0day-ci/archive/20240707/[email protected]/config) compiler: gcc-13 (Ubuntu 13.2.0-4ubuntu3) 13.2.0
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 <[email protected]> | Reported-by: Dan Carpenter <[email protected]> | Closes: https://lore.kernel.org/r/[email protected]/ smatch warnings: drivers/net/ethernet/intel/ice/ice_virtchnl_fdir.c:875 ice_vc_fdir_parse_raw() warn: missing error code 'status' vim +/status +875 drivers/net/ethernet/intel/ice/ice_virtchnl_fdir.c 23eb6f4d186242 Junfeng Guo 2024-05-27 831 static int 23eb6f4d186242 Junfeng Guo 2024-05-27 832 ice_vc_fdir_parse_raw(struct ice_vf *vf, 23eb6f4d186242 Junfeng Guo 2024-05-27 833 struct virtchnl_proto_hdrs *proto, 23eb6f4d186242 Junfeng Guo 2024-05-27 834 struct virtchnl_fdir_fltr_conf *conf) 23eb6f4d186242 Junfeng Guo 2024-05-27 835 { 23eb6f4d186242 Junfeng Guo 2024-05-27 836 u8 *pkt_buf, *msk_buf __free(kfree); 23eb6f4d186242 Junfeng Guo 2024-05-27 837 struct ice_parser_result rslt; 23eb6f4d186242 Junfeng Guo 2024-05-27 838 struct ice_pf *pf = vf->pf; 23eb6f4d186242 Junfeng Guo 2024-05-27 839 struct ice_parser *psr; 23eb6f4d186242 Junfeng Guo 2024-05-27 840 int status = -ENOMEM; 23eb6f4d186242 Junfeng Guo 2024-05-27 841 struct ice_hw *hw; 23eb6f4d186242 Junfeng Guo 2024-05-27 842 u16 udp_port = 0; 23eb6f4d186242 Junfeng Guo 2024-05-27 843 23eb6f4d186242 Junfeng Guo 2024-05-27 844 pkt_buf = kzalloc(proto->raw.pkt_len, GFP_KERNEL); 23eb6f4d186242 Junfeng Guo 2024-05-27 845 msk_buf = kzalloc(proto->raw.pkt_len, GFP_KERNEL); 23eb6f4d186242 Junfeng Guo 2024-05-27 846 if (!pkt_buf || !msk_buf) 23eb6f4d186242 Junfeng Guo 2024-05-27 847 goto err_mem_alloc; 23eb6f4d186242 Junfeng Guo 2024-05-27 848 23eb6f4d186242 Junfeng Guo 2024-05-27 849 memcpy(pkt_buf, proto->raw.spec, proto->raw.pkt_len); 23eb6f4d186242 Junfeng Guo 2024-05-27 850 memcpy(msk_buf, proto->raw.mask, proto->raw.pkt_len); 23eb6f4d186242 Junfeng Guo 2024-05-27 851 23eb6f4d186242 Junfeng Guo 2024-05-27 852 hw = &pf->hw; 23eb6f4d186242 Junfeng Guo 2024-05-27 853 23eb6f4d186242 Junfeng Guo 2024-05-27 854 /* Get raw profile info via Parser Lib */ 23eb6f4d186242 Junfeng Guo 2024-05-27 855 psr = ice_parser_create(hw); 23eb6f4d186242 Junfeng Guo 2024-05-27 856 if (IS_ERR(psr)) { 23eb6f4d186242 Junfeng Guo 2024-05-27 857 status = PTR_ERR(psr); 23eb6f4d186242 Junfeng Guo 2024-05-27 858 goto err_mem_alloc; 23eb6f4d186242 Junfeng Guo 2024-05-27 859 } 23eb6f4d186242 Junfeng Guo 2024-05-27 860 23eb6f4d186242 Junfeng Guo 2024-05-27 861 ice_parser_dvm_set(psr, ice_is_dvm_ena(hw)); 23eb6f4d186242 Junfeng Guo 2024-05-27 862 23eb6f4d186242 Junfeng Guo 2024-05-27 863 if (ice_get_open_tunnel_port(hw, &udp_port, TNL_VXLAN)) 23eb6f4d186242 Junfeng Guo 2024-05-27 864 ice_parser_vxlan_tunnel_set(psr, udp_port, true); 23eb6f4d186242 Junfeng Guo 2024-05-27 865 23eb6f4d186242 Junfeng Guo 2024-05-27 866 status = ice_parser_run(psr, pkt_buf, proto->raw.pkt_len, &rslt); 23eb6f4d186242 Junfeng Guo 2024-05-27 867 if (status) 23eb6f4d186242 Junfeng Guo 2024-05-27 868 goto err_parser_destroy; 23eb6f4d186242 Junfeng Guo 2024-05-27 869 23eb6f4d186242 Junfeng Guo 2024-05-27 870 if (hw->debug_mask & ICE_DBG_PARSER) 23eb6f4d186242 Junfeng Guo 2024-05-27 871 ice_parser_result_dump(hw, &rslt); 23eb6f4d186242 Junfeng Guo 2024-05-27 872 23eb6f4d186242 Junfeng Guo 2024-05-27 873 conf->prof = kzalloc(sizeof(*conf->prof), GFP_KERNEL); 23eb6f4d186242 Junfeng Guo 2024-05-27 874 if (!conf->prof) 23eb6f4d186242 Junfeng Guo 2024-05-27 @875 goto err_parser_destroy; status = -ENOMEM; 23eb6f4d186242 Junfeng Guo 2024-05-27 876 23eb6f4d186242 Junfeng Guo 2024-05-27 877 status = ice_parser_profile_init(&rslt, pkt_buf, msk_buf, 23eb6f4d186242 Junfeng Guo 2024-05-27 878 proto->raw.pkt_len, ICE_BLK_FD, 23eb6f4d186242 Junfeng Guo 2024-05-27 879 conf->prof); 23eb6f4d186242 Junfeng Guo 2024-05-27 880 if (status) 23eb6f4d186242 Junfeng Guo 2024-05-27 881 goto err_parser_profile_init; 23eb6f4d186242 Junfeng Guo 2024-05-27 882 23eb6f4d186242 Junfeng Guo 2024-05-27 883 if (hw->debug_mask & ICE_DBG_PARSER) 23eb6f4d186242 Junfeng Guo 2024-05-27 884 ice_parser_profile_dump(hw, conf->prof); 23eb6f4d186242 Junfeng Guo 2024-05-27 885 23eb6f4d186242 Junfeng Guo 2024-05-27 886 /* Store raw flow info into @conf */ 23eb6f4d186242 Junfeng Guo 2024-05-27 887 conf->pkt_len = proto->raw.pkt_len; 23eb6f4d186242 Junfeng Guo 2024-05-27 888 conf->pkt_buf = pkt_buf; 23eb6f4d186242 Junfeng Guo 2024-05-27 889 conf->parser_ena = true; 23eb6f4d186242 Junfeng Guo 2024-05-27 890 23eb6f4d186242 Junfeng Guo 2024-05-27 891 ice_parser_destroy(psr); 23eb6f4d186242 Junfeng Guo 2024-05-27 892 return 0; 23eb6f4d186242 Junfeng Guo 2024-05-27 893 23eb6f4d186242 Junfeng Guo 2024-05-27 894 err_parser_profile_init: 23eb6f4d186242 Junfeng Guo 2024-05-27 895 kfree(conf->prof); 23eb6f4d186242 Junfeng Guo 2024-05-27 896 err_parser_destroy: 23eb6f4d186242 Junfeng Guo 2024-05-27 897 ice_parser_destroy(psr); 23eb6f4d186242 Junfeng Guo 2024-05-27 898 err_mem_alloc: 23eb6f4d186242 Junfeng Guo 2024-05-27 899 kfree(pkt_buf); 23eb6f4d186242 Junfeng Guo 2024-05-27 900 return status; 23eb6f4d186242 Junfeng Guo 2024-05-27 901 } -- 0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki
