Kernel
  Threads by month 
                
            - ----- 2025 -----
 - November
 - October
 - September
 - August
 - July
 - June
 - May
 - April
 - March
 - February
 - January
 - ----- 2024 -----
 - December
 - November
 - October
 - September
 - August
 - July
 - June
 - May
 - April
 - March
 - February
 - January
 - ----- 2023 -----
 - December
 - November
 - October
 - September
 - August
 - July
 - June
 - May
 - April
 - March
 - February
 - January
 - ----- 2022 -----
 - December
 - November
 - October
 - September
 - August
 - July
 - June
 - May
 - April
 - March
 - February
 - January
 - ----- 2021 -----
 - December
 - November
 - October
 - September
 - August
 - July
 - June
 - May
 - April
 - March
 - February
 - January
 - ----- 2020 -----
 - December
 - November
 - October
 - September
 - August
 - July
 - June
 - May
 - April
 - March
 - February
 - January
 - ----- 2019 -----
 - December
 
- 25 participants
 - 21049 discussions
 
                        
                            
                                
                            
                            [openeuler:OLK-6.6 1834/1834] drivers/net/ethernet/yunsilicon/xsc/net/main.c:2610:5: warning: no previous prototype for 'xsc_set_vf_link_state'
                        
                        
by kernel test robot 22 Jan '25
                    by kernel test robot 22 Jan '25
22 Jan '25
                    
                        tree:   https://gitee.com/openeuler/kernel.git OLK-6.6
head:   75c81bcddd82381fbd4cef477a5b56eb2fe56697
commit: bcfb3e65a5707ca4caf593a33276f26b993ad71e [1834/1834] drivers: update Yunsilicon driver to version 2406_rc16
config: x86_64-randconfig-121-20250122 (https://download.01.org/0day-ci/archive/20250122/202501222120.JRNKhp0f-lkp@…)
compiler: gcc-12 (Debian 12.2.0-14) 12.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250122/202501222120.JRNKhp0f-lkp@…)
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(a)intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202501222120.JRNKhp0f-lkp@intel.com/
All warnings (new ones prefixed by >>):
         |      ^~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:201:6: warning: no previous prototype for 'xsc_eth_cq_error_event' [-Wmissing-prototypes]
     201 | void xsc_eth_cq_error_event(struct xsc_core_cq *xcq, enum xsc_event event)
         |      ^~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:215:6: warning: no previous prototype for 'xsc_eth_completion_event' [-Wmissing-prototypes]
     215 | void xsc_eth_completion_event(struct xsc_core_cq *xcq)
         |      ^~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:262:5: warning: no previous prototype for 'xsc_eth_create_cq' [-Wmissing-prototypes]
     262 | int xsc_eth_create_cq(struct xsc_core_device *xdev, struct xsc_core_cq *xcq,
         |     ^~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:297:5: warning: no previous prototype for 'xsc_eth_destroy_cq' [-Wmissing-prototypes]
     297 | int xsc_eth_destroy_cq(struct xsc_core_device *xdev, struct xsc_cq *cq)
         |     ^~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:335:6: warning: no previous prototype for 'xsc_eth_free_cq' [-Wmissing-prototypes]
     335 | void xsc_eth_free_cq(struct xsc_cq *cq)
         |      ^~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:340:5: warning: no previous prototype for 'xsc_eth_create_rss_qp_rqs' [-Wmissing-prototypes]
     340 | int xsc_eth_create_rss_qp_rqs(struct xsc_core_device *xdev,
         |     ^~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:361:6: warning: no previous prototype for 'xsc_eth_qp_event' [-Wmissing-prototypes]
     361 | void xsc_eth_qp_event(struct xsc_core_qp *qp, int type)
         |      ^~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:391:5: warning: no previous prototype for 'xsc_eth_create_qp_rq' [-Wmissing-prototypes]
     391 | int xsc_eth_create_qp_rq(struct xsc_core_device *xdev, struct xsc_rq *prq,
         |     ^~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:418:5: warning: no previous prototype for 'xsc_eth_destroy_qp_rq' [-Wmissing-prototypes]
     418 | int xsc_eth_destroy_qp_rq(struct xsc_core_device *xdev, struct xsc_rq *prq)
         |     ^~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:470:5: warning: no previous prototype for 'xsc_eth_create_qp_sq' [-Wmissing-prototypes]
     470 | int xsc_eth_create_qp_sq(struct xsc_core_device *xdev, struct xsc_sq *psq,
         |     ^~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:489:5: warning: no previous prototype for 'xsc_eth_modify_qp_sq' [-Wmissing-prototypes]
     489 | int xsc_eth_modify_qp_sq(struct xsc_core_device *xdev, struct xsc_modify_raw_qp_mbox_in *in)
         |     ^~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:507:5: warning: no previous prototype for 'xsc_eth_destroy_qp_sq' [-Wmissing-prototypes]
     507 | int xsc_eth_destroy_qp_sq(struct xsc_core_device *xdev, struct xsc_sq *psq)
         |     ^~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:735:5: warning: no previous prototype for 'xsc_eth_set_hw_mtu' [-Wmissing-prototypes]
     735 | int xsc_eth_set_hw_mtu(struct xsc_core_device *dev, u16 mtu, u16 rx_buf_sz)
         |     ^~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:760:5: warning: no previous prototype for 'xsc_eth_get_mac' [-Wmissing-prototypes]
     760 | int xsc_eth_get_mac(struct xsc_core_device *dev, char *mac)
         |     ^~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:790:5: warning: no previous prototype for 'xsc_eth_modify_qps_channel' [-Wmissing-prototypes]
     790 | int xsc_eth_modify_qps_channel(struct xsc_adapter *adapter, struct xsc_channel *c)
         |     ^~~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:812:5: warning: no previous prototype for 'xsc_eth_modify_qps' [-Wmissing-prototypes]
     812 | int xsc_eth_modify_qps(struct xsc_adapter *adapter,
         |     ^~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:829:5: warning: no previous prototype for 'xsc_rx_get_linear_frag_sz' [-Wmissing-prototypes]
     829 | u32 xsc_rx_get_linear_frag_sz(u32 mtu)
         |     ^~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:836:6: warning: no previous prototype for 'xsc_rx_is_linear_skb' [-Wmissing-prototypes]
     836 | bool xsc_rx_is_linear_skb(u32 mtu)
         |      ^~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:1313:5: warning: no previous prototype for 'xsc_eth_open_channel' [-Wmissing-prototypes]
    1313 | int xsc_eth_open_channel(struct xsc_adapter *adapter,
         |     ^~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:1526:5: warning: no previous prototype for 'xsc_eth_open_channels' [-Wmissing-prototypes]
    1526 | int xsc_eth_open_channels(struct xsc_adapter *adapter)
         |     ^~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:1638:6: warning: no previous prototype for 'xsc_eth_activate_channel' [-Wmissing-prototypes]
    1638 | void xsc_eth_activate_channel(struct xsc_channel *c)
         |      ^~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:1644:6: warning: no previous prototype for 'xsc_eth_deactivate_channel' [-Wmissing-prototypes]
    1644 | void xsc_eth_deactivate_channel(struct xsc_channel *c)
         |      ^~~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:1690:6: warning: no previous prototype for 'xsc_eth_activate_priv_channels' [-Wmissing-prototypes]
    1690 | void xsc_eth_activate_priv_channels(struct xsc_adapter *adapter)
         |      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:1705:6: warning: no previous prototype for 'xsc_eth_deactivate_priv_channels' [-Wmissing-prototypes]
    1705 | void xsc_eth_deactivate_priv_channels(struct xsc_adapter *adapter)
         |      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:1864:5: warning: no previous prototype for 'xsc_eth_change_link_status' [-Wmissing-prototypes]
    1864 | int xsc_eth_change_link_status(struct xsc_adapter *adapter)
         |     ^~~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:1927:6: warning: no previous prototype for 'xsc_eth_event_handler' [-Wmissing-prototypes]
    1927 | void xsc_eth_event_handler(void *arg)
         |      ^~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:1935:5: warning: no previous prototype for 'xsc_eth_enable_nic_hca' [-Wmissing-prototypes]
    1935 | int xsc_eth_enable_nic_hca(struct xsc_adapter *adapter)
         |     ^~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:1999:5: warning: no previous prototype for 'xsc_eth_disable_nic_hca' [-Wmissing-prototypes]
    1999 | int xsc_eth_disable_nic_hca(struct xsc_adapter *adapter)
         |     ^~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:2029:6: warning: no previous prototype for 'xsc_eth_rss_params_change' [-Wmissing-prototypes]
    2029 | void xsc_eth_rss_params_change(struct xsc_adapter *adapter, u32 change, void *modify)
         |      ^~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:2357:6: warning: no previous prototype for 'xsc_build_default_indir_rqt' [-Wmissing-prototypes]
    2357 | void xsc_build_default_indir_rqt(u32 *indirection_rqt, int len,
         |      ^~~~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:2455:5: warning: no previous prototype for 'xsc_eth_nic_mtu_changed' [-Wmissing-prototypes]
    2455 | int xsc_eth_nic_mtu_changed(struct xsc_adapter *priv)
         |     ^~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:2525:5: warning: no previous prototype for 'xsc_set_vf_mac' [-Wmissing-prototypes]
    2525 | int xsc_set_vf_mac(struct net_device *netdev, int vf, u8 *mac)
         |     ^~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:2593:5: warning: no previous prototype for 'xsc_get_vf_config' [-Wmissing-prototypes]
    2593 | int xsc_get_vf_config(struct net_device *dev,
         |     ^~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/main.c:2610:5: warning: no previous prototype for 'xsc_set_vf_link_state' [-Wmissing-prototypes]
    2610 | int xsc_set_vf_link_state(struct net_device *dev, int vf,
         |     ^~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:2620:5: warning: no previous prototype for 'set_feature_rxcsum' [-Wmissing-prototypes]
    2620 | int set_feature_rxcsum(struct net_device *netdev, bool enable)
         |     ^~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/main.c:2642:5: warning: no previous prototype for 'set_feature_vlan_offload' [-Wmissing-prototypes]
    2642 | int set_feature_vlan_offload(struct net_device *netdev, bool enable)
         |     ^~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:2694:5: warning: no previous prototype for 'xsc_eth_set_features' [-Wmissing-prototypes]
    2694 | int xsc_eth_set_features(struct net_device *netdev, netdev_features_t features)
         |     ^~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:2757:5: warning: no previous prototype for 'xsc_select_queue' [-Wmissing-prototypes]
    2757 | u16 xsc_select_queue(struct net_device *dev, struct sk_buff *skb,
         |     ^~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c: In function 'xsc_get_phys_port_name':
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:2805:28: error: 'struct pci_dev' has no member named 'physfn'; did you mean 'is_physfn'?
    2805 |                 if (!pdev->physfn)
         |                            ^~~~~~
         |                            is_physfn
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:2807:49: error: 'struct pci_dev' has no member named 'physfn'; did you mean 'is_physfn'?
    2807 |                 pf_xdev = pci_get_drvdata(pdev->physfn);
         |                                                 ^~~~~~
         |                                                 is_physfn
   drivers/net/ethernet/yunsilicon/xsc/net/main.c: At top level:
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:2966:24: warning: no previous prototype for 'xsc_tirc_get_default_config' [-Wmissing-prototypes]
    2966 | struct xsc_tirc_config xsc_tirc_get_default_config(enum xsc_traffic_types tt)
         |                        ^~~~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:2971:6: warning: no previous prototype for 'xsc_build_rss_params' [-Wmissing-prototypes]
    2971 | void xsc_build_rss_params(struct xsc_rss_params *rss_params, u16 num_channels)
         |      ^~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:2989:6: warning: no previous prototype for 'xsc_eth_build_nic_params' [-Wmissing-prototypes]
    2989 | void xsc_eth_build_nic_params(struct xsc_adapter *adapter, u32 ch_num, u32 tc_num)
         |      ^~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:3017:6: warning: no previous prototype for 'xsc_eth_build_nic_netdev' [-Wmissing-prototypes]
    3017 | void xsc_eth_build_nic_netdev(struct xsc_adapter *adapter)
         |      ^~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:3085:5: warning: no previous prototype for 'xsc_eth_create_xdev_resources' [-Wmissing-prototypes]
    3085 | int xsc_eth_create_xdev_resources(struct xsc_core_device *xdev)
         |     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:3106:5: warning: no previous prototype for 'xsc_eth_init_nic_rx' [-Wmissing-prototypes]
    3106 | int xsc_eth_init_nic_rx(struct xsc_adapter *adapter)
         |     ^~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/main.c:3343:5: warning: no previous prototype for 'xsc_net_reboot_event_handler' [-Wmissing-prototypes]
    3343 | int xsc_net_reboot_event_handler(struct notifier_block *nb, unsigned long action, void *data)
         |     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
--
   drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ethtool.c:182:5: warning: no previous prototype for 'xsc_priv_flags_num' [-Wmissing-prototypes]
     182 | int xsc_priv_flags_num(void)
         |     ^~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ethtool.c:187:13: warning: no previous prototype for 'xsc_priv_flags_name' [-Wmissing-prototypes]
     187 | const char *xsc_priv_flags_name(int flag)
         |             ^~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ethtool.c:213:5: warning: no previous prototype for 'xsc_set_priv_flags' [-Wmissing-prototypes]
     213 | int xsc_set_priv_flags(struct net_device *dev, u32 pflags)
         |     ^~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ethtool.c:369:5: warning: no previous prototype for 'xsc_get_priv_flags' [-Wmissing-prototypes]
     369 | u32 xsc_get_priv_flags(struct net_device *dev)
         |     ^~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ethtool.c:849:5: warning: no previous prototype for 'xsc_get_rxnfc' [-Wmissing-prototypes]
     849 | int xsc_get_rxnfc(struct net_device *dev, struct ethtool_rxnfc *info, u32 *rule_locs)
         |     ^~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ethtool.c:872:5: warning: no previous prototype for 'xsc_set_rxnfc' [-Wmissing-prototypes]
     872 | int xsc_set_rxnfc(struct net_device *dev, struct ethtool_rxnfc *cmd)
         |     ^~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ethtool.c:901:5: warning: no previous prototype for 'xsc_get_rxfh' [-Wmissing-prototypes]
     901 | int xsc_get_rxfh(struct net_device *netdev, u32 *indir, u8 *key, u8 *hfunc)
         |     ^~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ethtool.c:920:5: warning: no previous prototype for 'xsc_set_rxfh' [-Wmissing-prototypes]
     920 | int xsc_set_rxfh(struct net_device *dev, const u32 *indir, const u8 *key, const u8 hfunc)
         |     ^~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ethtool.c:31:27: warning: 'pct_exp_name' defined but not used [-Wunused-const-variable=]
      31 | static const char * const pct_exp_name[] = {"N", "E" };
         |                           ^~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ethtool.c:30:27: warning: 'pp_tbl_dma_name' defined but not used [-Wunused-const-variable=]
      30 | static const char * const pp_tbl_dma_name[] = {"N", "D" };
         |                           ^~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ethtool.c:29:27: warning: 'anlt_fec_name' defined but not used [-Wunused-const-variable=]
      29 | static const char * const anlt_fec_name[] = {"N", "A" };
         |                           ^~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ethtool.c:28:27: warning: 'ma_xbar_name' defined but not used [-Wunused-const-variable=]
      28 | static const char * const ma_xbar_name[] = {"N", "X" };
         |                           ^~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ethtool.c:27:27: warning: 'rdma_icrc_name' defined but not used [-Wunused-const-variable=]
      27 | static const char * const rdma_icrc_name[] = {"N", "C" };
         |                           ^~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ethtool.c:26:27: warning: 'onchip_ft_name' defined but not used [-Wunused-const-variable=]
      26 | static const char * const onchip_ft_name[] = {"N", "O" };
         |                           ^~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ethtool.c:25:27: warning: 'hps_ddr_name' defined but not used [-Wunused-const-variable=]
      25 | static const char * const hps_ddr_name[] = {"1", "2", "4", "unknown"};
         |                           ^~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ethtool.c:24:27: warning: 'fpga_type_name' defined but not used [-Wunused-const-variable=]
      24 | static const char * const fpga_type_name[] = {"S", "L"};
         |                           ^~~~~~~~~~~~~~
--
   drivers/net/ethernet/yunsilicon/xsc/net/xsc_hw_comm.c: In function 'xsc_dcbx_hw_qos_cmdq':
   drivers/net/ethernet/yunsilicon/xsc/net/xsc_hw_comm.c:47:13: warning: variable 'err' set but not used [-Wunused-but-set-variable]
      47 |         int err;
         |             ^~~
   drivers/net/ethernet/yunsilicon/xsc/net/xsc_hw_comm.c: At top level:
>> drivers/net/ethernet/yunsilicon/xsc/net/xsc_hw_comm.c:104:5: warning: no previous prototype for 'xsc_hw_kernel_call' [-Wmissing-prototypes]
     104 | int xsc_hw_kernel_call(struct xsc_core_device *xdev, u16 opcode, void *req, void *rsp)
         |     ^~~~~~~~~~~~~~~~~~
--
   drivers/net/ethernet/yunsilicon/xsc/pci/main.c:174:5: warning: no previous prototype for 'xsc_priv_init' [-Wmissing-prototypes]
     174 | int xsc_priv_init(struct xsc_core_device *dev)
         |     ^~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/main.c:188:5: warning: no previous prototype for 'xsc_dev_res_init' [-Wmissing-prototypes]
     188 | int xsc_dev_res_init(struct xsc_core_device *dev)
         |     ^~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/main.c:207:6: warning: no previous prototype for 'xsc_dev_res_cleanup' [-Wmissing-prototypes]
     207 | void xsc_dev_res_cleanup(struct xsc_core_device *dev)
         |      ^~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/main.c:213:6: warning: no previous prototype for 'xsc_init_reg_addr' [-Wmissing-prototypes]
     213 | void xsc_init_reg_addr(struct xsc_core_device *dev)
         |      ^~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/main.c:400:5: warning: no previous prototype for 'xsc_reset_function_resource' [-Wmissing-prototypes]
     400 | int xsc_reset_function_resource(struct xsc_core_device *dev)
         |     ^~~~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/main.c:635:5: warning: no previous prototype for 'xsc_load_one' [-Wmissing-prototypes]
     635 | int xsc_load_one(struct xsc_core_device *dev, bool boot)
         |     ^~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/main.c: In function 'xsc_load_one':
   drivers/net/ethernet/yunsilicon/xsc/pci/main.c:665:74: error: 'struct pci_dev' has no member named 'physfn'; did you mean 'is_physfn'?
     665 |         if (!dev->reg_mr_via_cmdq && (xsc_core_is_pf(dev) || !dev->pdev->physfn)) {
         |                                                                          ^~~~~~
         |                                                                          is_physfn
   drivers/net/ethernet/yunsilicon/xsc/pci/main.c:711:74: error: 'struct pci_dev' has no member named 'physfn'; did you mean 'is_physfn'?
     711 |         if (!dev->reg_mr_via_cmdq && (xsc_core_is_pf(dev) || !dev->pdev->physfn))
         |                                                                          ^~~~~~
         |                                                                          is_physfn
   drivers/net/ethernet/yunsilicon/xsc/pci/main.c: At top level:
   drivers/net/ethernet/yunsilicon/xsc/pci/main.c:726:5: warning: no previous prototype for 'xsc_unload_one' [-Wmissing-prototypes]
     726 | int xsc_unload_one(struct xsc_core_device *dev, bool cleanup)
         |     ^~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/main.c: In function 'xsc_unload_one':
   drivers/net/ethernet/yunsilicon/xsc/pci/main.c:748:74: error: 'struct pci_dev' has no member named 'physfn'; did you mean 'is_physfn'?
     748 |         if (!dev->reg_mr_via_cmdq && (xsc_core_is_pf(dev) || !dev->pdev->physfn))
         |                                                                          ^~~~~~
         |                                                                          is_physfn
   drivers/net/ethernet/yunsilicon/xsc/pci/main.c: At top level:
>> drivers/net/ethernet/yunsilicon/xsc/pci/main.c:856:5: warning: no previous prototype for 'xsc_pci_reboot_event_handler' [-Wmissing-prototypes]
     856 | int xsc_pci_reboot_event_handler(struct notifier_block *nb, unsigned long action, void *data)
         |     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
--
>> drivers/net/ethernet/yunsilicon/xsc/pci/mr.c:71:5: warning: no previous prototype for 'xsc_set_mpt_via_cmdq' [-Wmissing-prototypes]
      71 | int xsc_set_mpt_via_cmdq(struct xsc_core_device *dev, struct xsc_register_mr_mbox_in *in_cmd,
         |     ^~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/pci/mr.c:106:5: warning: no previous prototype for 'xsc_set_mtt_via_cmdq' [-Wmissing-prototypes]
     106 | int xsc_set_mtt_via_cmdq(struct xsc_core_device *dev, struct xsc_register_mr_mbox_in *in_cmd,
         |     ^~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/pci/mr.c:153:5: warning: no previous prototype for 'xsc_dereg_mr_via_cmdq' [-Wmissing-prototypes]
     153 | int xsc_dereg_mr_via_cmdq(struct xsc_core_device *dev,  struct xsc_register_mr_mbox_in *in_cmd)
         |     ^~~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/pci/mr.c:170:5: warning: no previous prototype for 'xsc_reg_mr_via_cmdq' [-Wmissing-prototypes]
     170 | int xsc_reg_mr_via_cmdq(struct xsc_core_device *dev, struct xsc_register_mr_mbox_in *in)
         |     ^~~~~~~~~~~~~~~~~~~
--
>> drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:29:6: warning: no previous prototype for 'xsc_board_lag_set' [-Wmissing-prototypes]
      29 | void xsc_board_lag_set(struct xsc_core_device *xdev,
         |      ^~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:38:6: warning: no previous prototype for 'xsc_board_lag_reset' [-Wmissing-prototypes]
      38 | void xsc_board_lag_reset(u32 board_id)
         |      ^~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:75:22: warning: no previous prototype for 'bond_lag_hash_type' [-Wmissing-prototypes]
      75 | enum netdev_lag_hash bond_lag_hash_type(struct bonding *bond)
         |                      ^~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:123:5: warning: no previous prototype for 'xsc_cmd_create_lag' [-Wmissing-prototypes]
     123 | int xsc_cmd_create_lag(struct xsc_lag_event *entry)
         |     ^~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:155:5: warning: no previous prototype for 'xsc_cmd_add_lag_member' [-Wmissing-prototypes]
     155 | int xsc_cmd_add_lag_member(struct xsc_lag_event *entry)
         |     ^~~~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:188:5: warning: no previous prototype for 'xsc_cmd_remove_lag_member' [-Wmissing-prototypes]
     188 | int xsc_cmd_remove_lag_member(struct xsc_lag_event *entry)
         |     ^~~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:220:5: warning: no previous prototype for 'xsc_cmd_update_lag_member_status' [-Wmissing-prototypes]
     220 | int xsc_cmd_update_lag_member_status(struct xsc_lag_event *entry)
         |     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:249:5: warning: no previous prototype for 'xsc_cmd_update_lag_hash_type' [-Wmissing-prototypes]
     249 | int xsc_cmd_update_lag_hash_type(struct xsc_lag_event *entry)
         |     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:274:5: warning: no previous prototype for 'xsc_cmd_destroy_lag' [-Wmissing-prototypes]
     274 | int xsc_cmd_destroy_lag(struct xsc_lag_event *entry)
         |     ^~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:320:6: warning: no previous prototype for 'xsc_create_lag' [-Wmissing-prototypes]
     320 | void xsc_create_lag(struct xsc_lag_event *entry)
         |      ^~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:351:6: warning: no previous prototype for 'xsc_add_lag_member' [-Wmissing-prototypes]
     351 | void xsc_add_lag_member(struct xsc_lag_event *entry)
         |      ^~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:379:6: warning: no previous prototype for 'xsc_remove_lag_member' [-Wmissing-prototypes]
     379 | void xsc_remove_lag_member(struct xsc_lag_event *entry)
         |      ^~~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:414:6: warning: no previous prototype for 'xsc_update_lag_member_status' [-Wmissing-prototypes]
     414 | void xsc_update_lag_member_status(struct xsc_lag_event *entry)
         |      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:434:6: warning: no previous prototype for 'xsc_update_lag_hash_type' [-Wmissing-prototypes]
     434 | void xsc_update_lag_hash_type(struct xsc_lag_event *entry)
         |      ^~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:444:6: warning: no previous prototype for 'xsc_destroy_lag' [-Wmissing-prototypes]
     444 | void xsc_destroy_lag(struct xsc_lag_event *entry)
         |      ^~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:605:6: warning: no previous prototype for 'pack_lag_create' [-Wmissing-prototypes]
     605 | void pack_lag_create(struct xsc_lag *lag,
         |      ^~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:638:6: warning: no previous prototype for 'pack_lag_add_member' [-Wmissing-prototypes]
     638 | void pack_lag_add_member(struct xsc_lag *lag,
         |      ^~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:683:6: warning: no previous prototype for 'pack_lag_remove_member' [-Wmissing-prototypes]
     683 | void pack_lag_remove_member(struct xsc_lag *lag,
         |      ^~~~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:738:6: warning: no previous prototype for 'pack_lag_update_member_status' [-Wmissing-prototypes]
     738 | void pack_lag_update_member_status(struct xsc_lag *lag,
         |      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:766:6: warning: no previous prototype for 'pack_lag_update_hash_type' [-Wmissing-prototypes]
     766 | void pack_lag_update_hash_type(struct xsc_lag *lag,
         |      ^~~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:796:6: warning: no previous prototype for 'pack_lag_destroy' [-Wmissing-prototypes]
     796 | void pack_lag_destroy(struct xsc_lag *lag, struct xsc_core_device *xdev, bool no_wq)
         |      ^~~~~~~~~~~~~~~~
vim +/xsc_set_vf_link_state +2610 drivers/net/ethernet/yunsilicon/xsc/net/main.c
  2609	
> 2610	int xsc_set_vf_link_state(struct net_device *dev, int vf,
  2611				  int link_state)
  2612	{
  2613		struct xsc_adapter *adapter = netdev_priv(dev);
  2614		struct xsc_core_device *xdev = adapter->xdev;
  2615		struct xsc_eswitch *esw = xdev->priv.eswitch;
  2616	
  2617		return xsc_eswitch_set_vport_state(esw, vf + 1, link_state);
  2618	}
  2619	
  2620	int set_feature_rxcsum(struct net_device *netdev, bool enable)
  2621	{
  2622		struct xsc_adapter *adapter = netdev_priv(netdev);
  2623		struct xsc_core_device *xdev = adapter->xdev;
  2624		struct xsc_cmd_modify_nic_hca_mbox_in in = {};
  2625		struct xsc_cmd_modify_nic_hca_mbox_out out = {};
  2626		int err;
  2627	
  2628		in.hdr.opcode = cpu_to_be16(XSC_CMD_OP_MODIFY_NIC_HCA);
  2629		in.nic.caps_mask = cpu_to_be16(BIT(XSC_TBM_CAP_HASH_PPH));
  2630		in.nic.caps = cpu_to_be16(enable << XSC_TBM_CAP_HASH_PPH);
  2631	
  2632		err = xsc_cmd_exec(xdev, &in, sizeof(in), &out, sizeof(out));
  2633		if (err || out.hdr.status) {
  2634			netdev_err(netdev, "failed to change rxcsum=%d, err=%d, status=%d\n",
  2635				   enable, err, out.hdr.status);
  2636			return -ENOEXEC;
  2637		}
  2638	
  2639		return 0;
  2640	}
  2641	
> 2642	int set_feature_vlan_offload(struct net_device *netdev, bool enable)
  2643	{
  2644		int err = 0, i;
  2645		struct xsc_adapter *adapter = netdev_priv(netdev);
  2646		struct xsc_vport *evport = NULL;
  2647	
  2648		if (!enable) {
  2649			for (i = 0; i < adapter->xdev->priv.eswitch->num_vfs; i++) {
  2650				evport = xsc_eswitch_get_vport(adapter->xdev->priv.eswitch,
  2651							       i + 1);
  2652				if (evport && (evport->vlan_id || evport->vlan_qos)) {
  2653					evport->vlan_id = 0;
  2654					evport->vlan_qos = 0;
  2655					err = xsc_eswitch_set_vport_vlan(adapter->xdev->priv.eswitch,
  2656									 i + 1, evport->vlan_id,
  2657									 evport->vlan_qos,
  2658									 evport->vlan_proto);
  2659					if (err)
  2660						xsc_core_err(adapter->xdev, "fail to clear vf vlan offload vf=%d err=%d\n",
  2661							     i, err);
  2662				}
  2663			}
  2664		}
  2665	
  2666		return 0;
  2667	}
  2668	
-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
                    
                  
                  
                          
                            
                            1
                            
                          
                          
                            
                            0
                            
                          
                          
                            
    
                          
                        
                    
                        
                            
                                
                            
                            [openeuler:OLK-6.6 1834/1834] drivers/net/ethernet/yunsilicon/xsc/net/main.c:197:6: warning: no previous prototype for 'xsc_eth_cq_error_event'
                        
                        
by kernel test robot 22 Jan '25
                    by kernel test robot 22 Jan '25
22 Jan '25
                    
                        tree:   https://gitee.com/openeuler/kernel.git OLK-6.6
head:   75c81bcddd82381fbd4cef477a5b56eb2fe56697
commit: 601fb01dc16f747534b866610743d95830b6655e [1834/1834] drivers: support for xsc drivers from Yunsilicon Technology
config: x86_64-randconfig-121-20250122 (https://download.01.org/0day-ci/archive/20250122/202501221955.lCr3eThq-lkp@…)
compiler: gcc-12 (Debian 12.2.0-14) 12.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250122/202501221955.lCr3eThq-lkp@…)
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(a)intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202501221955.lCr3eThq-lkp@intel.com/
All warnings (new ones prefixed by >>):
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:166:5: warning: no previous prototype for 'xsc_rx_alloc_page_cache' [-Wmissing-prototypes]
     166 | int xsc_rx_alloc_page_cache(struct xsc_rq *rq, int node, u8 log_init_sz)
         |     ^~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:179:6: warning: no previous prototype for 'xsc_rx_free_page_cache' [-Wmissing-prototypes]
     179 | void xsc_rx_free_page_cache(struct xsc_rq *rq)
         |      ^~~~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/main.c:197:6: warning: no previous prototype for 'xsc_eth_cq_error_event' [-Wmissing-prototypes]
     197 | void xsc_eth_cq_error_event(struct xsc_core_cq *xcq, enum xsc_event event)
         |      ^~~~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/main.c:211:6: warning: no previous prototype for 'xsc_eth_completion_event' [-Wmissing-prototypes]
     211 | void xsc_eth_completion_event(struct xsc_core_cq *xcq)
         |      ^~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:260:5: warning: no previous prototype for 'xsc_eth_create_cq' [-Wmissing-prototypes]
     260 | int xsc_eth_create_cq(struct xsc_core_device *xdev, struct xsc_core_cq *xcq,
         |     ^~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:295:5: warning: no previous prototype for 'xsc_eth_destroy_cq' [-Wmissing-prototypes]
     295 | int xsc_eth_destroy_cq(struct xsc_core_device *xdev, struct xsc_cq *cq)
         |     ^~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:333:6: warning: no previous prototype for 'xsc_eth_free_cq' [-Wmissing-prototypes]
     333 | void xsc_eth_free_cq(struct xsc_cq *cq)
         |      ^~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:338:5: warning: no previous prototype for 'xsc_eth_create_rss_qp_rqs' [-Wmissing-prototypes]
     338 | int xsc_eth_create_rss_qp_rqs(struct xsc_core_device *xdev,
         |     ^~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:359:6: warning: no previous prototype for 'xsc_eth_qp_event' [-Wmissing-prototypes]
     359 | void xsc_eth_qp_event(struct xsc_core_qp *qp, int type)
         |      ^~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/main.c:389:5: warning: no previous prototype for 'xsc_eth_create_qp_rq' [-Wmissing-prototypes]
     389 | int xsc_eth_create_qp_rq(struct xsc_core_device *xdev, struct xsc_rq *prq,
         |     ^~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:416:5: warning: no previous prototype for 'xsc_eth_destroy_qp_rq' [-Wmissing-prototypes]
     416 | int xsc_eth_destroy_qp_rq(struct xsc_core_device *xdev, struct xsc_rq *prq)
         |     ^~~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/main.c:469:5: warning: no previous prototype for 'xsc_eth_create_qp_sq' [-Wmissing-prototypes]
     469 | int xsc_eth_create_qp_sq(struct xsc_core_device *xdev, struct xsc_sq *psq,
         |     ^~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/main.c:488:5: warning: no previous prototype for 'xsc_eth_modify_qp_sq' [-Wmissing-prototypes]
     488 | int xsc_eth_modify_qp_sq(struct xsc_core_device *xdev, struct xsc_modify_raw_qp_mbox_in *in)
         |     ^~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/main.c:506:5: warning: no previous prototype for 'xsc_eth_destroy_qp_sq' [-Wmissing-prototypes]
     506 | int xsc_eth_destroy_qp_sq(struct xsc_core_device *xdev, struct xsc_sq *psq)
         |     ^~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:750:5: warning: no previous prototype for 'xsc_eth_set_hw_mtu' [-Wmissing-prototypes]
     750 | int xsc_eth_set_hw_mtu(struct xsc_core_device *dev, u16 mtu, u16 rx_buf_sz)
         |     ^~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:775:5: warning: no previous prototype for 'xsc_eth_get_mac' [-Wmissing-prototypes]
     775 | int xsc_eth_get_mac(struct xsc_core_device *dev, char *mac)
         |     ^~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:806:5: warning: no previous prototype for 'xsc_eth_modify_qps_channel' [-Wmissing-prototypes]
     806 | int xsc_eth_modify_qps_channel(struct xsc_adapter *adapter, struct xsc_channel *c)
         |     ^~~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:828:5: warning: no previous prototype for 'xsc_eth_modify_qps' [-Wmissing-prototypes]
     828 | int xsc_eth_modify_qps(struct xsc_adapter *adapter,
         |     ^~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:845:5: warning: no previous prototype for 'xsc_rx_get_linear_frag_sz' [-Wmissing-prototypes]
     845 | u32 xsc_rx_get_linear_frag_sz(u32 mtu)
         |     ^~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:852:6: warning: no previous prototype for 'xsc_rx_is_linear_skb' [-Wmissing-prototypes]
     852 | bool xsc_rx_is_linear_skb(u32 mtu)
         |      ^~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/main.c:1316:5: warning: no previous prototype for 'xsc_eth_open_channel' [-Wmissing-prototypes]
    1316 | int xsc_eth_open_channel(struct xsc_adapter *adapter,
         |     ^~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:1528:5: warning: no previous prototype for 'xsc_eth_open_channels' [-Wmissing-prototypes]
    1528 | int xsc_eth_open_channels(struct xsc_adapter *adapter)
         |     ^~~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/main.c:1640:6: warning: no previous prototype for 'xsc_eth_activate_channel' [-Wmissing-prototypes]
    1640 | void xsc_eth_activate_channel(struct xsc_channel *c)
         |      ^~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:1646:6: warning: no previous prototype for 'xsc_eth_deactivate_channel' [-Wmissing-prototypes]
    1646 | void xsc_eth_deactivate_channel(struct xsc_channel *c)
         |      ^~~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:1692:6: warning: no previous prototype for 'xsc_eth_activate_priv_channels' [-Wmissing-prototypes]
    1692 | void xsc_eth_activate_priv_channels(struct xsc_adapter *adapter)
         |      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:1707:6: warning: no previous prototype for 'xsc_eth_deactivate_priv_channels' [-Wmissing-prototypes]
    1707 | void xsc_eth_deactivate_priv_channels(struct xsc_adapter *adapter)
         |      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:1850:5: warning: no previous prototype for 'xsc_eth_change_link_status' [-Wmissing-prototypes]
    1850 | int xsc_eth_change_link_status(struct xsc_adapter *adapter)
         |     ^~~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:1907:6: warning: no previous prototype for 'xsc_eth_event_handler' [-Wmissing-prototypes]
    1907 | void xsc_eth_event_handler(void *arg)
         |      ^~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:1915:5: warning: no previous prototype for 'xsc_eth_enable_nic_hca' [-Wmissing-prototypes]
    1915 | int xsc_eth_enable_nic_hca(struct xsc_adapter *adapter)
         |     ^~~~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/main.c:1977:5: warning: no previous prototype for 'xsc_eth_disable_nic_hca' [-Wmissing-prototypes]
    1977 | int xsc_eth_disable_nic_hca(struct xsc_adapter *adapter)
         |     ^~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:2010:6: warning: no previous prototype for 'xsc_eth_rss_params_change' [-Wmissing-prototypes]
    2010 | void xsc_eth_rss_params_change(struct xsc_adapter *adapter, u32 change, void *modify)
         |      ^~~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/main.c:2318:6: warning: no previous prototype for 'xsc_build_default_indir_rqt' [-Wmissing-prototypes]
    2318 | void xsc_build_default_indir_rqt(u32 *indirection_rqt, int len,
         |      ^~~~~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/main.c:2416:5: warning: no previous prototype for 'xsc_eth_nic_mtu_changed' [-Wmissing-prototypes]
    2416 | int xsc_eth_nic_mtu_changed(struct xsc_adapter *priv)
         |     ^~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:2479:5: warning: no previous prototype for 'xsc_set_vf_mac' [-Wmissing-prototypes]
    2479 | int xsc_set_vf_mac(struct net_device *netdev, int vf, u8 *mac)
         |     ^~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:2496:5: warning: no previous prototype for 'xsc_get_vf_config' [-Wmissing-prototypes]
    2496 | int xsc_get_vf_config(struct net_device *dev,
         |     ^~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:2512:5: warning: no previous prototype for 'set_feature_rxcsum' [-Wmissing-prototypes]
    2512 | int set_feature_rxcsum(struct net_device *netdev, bool enable)
         |     ^~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:2564:5: warning: no previous prototype for 'xsc_eth_set_features' [-Wmissing-prototypes]
    2564 | int xsc_eth_set_features(struct net_device *netdev, netdev_features_t features)
         |     ^~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/main.c:2581:5: warning: no previous prototype for 'xsc_select_queue' [-Wmissing-prototypes]
    2581 | u16 xsc_select_queue(struct net_device *dev, struct sk_buff *skb,
         |     ^~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c: In function 'xsc_get_phys_port_name':
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:2628:28: error: 'struct pci_dev' has no member named 'physfn'; did you mean 'is_physfn'?
    2628 |                 if (!pdev->physfn)
         |                            ^~~~~~
         |                            is_physfn
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:2630:49: error: 'struct pci_dev' has no member named 'physfn'; did you mean 'is_physfn'?
    2630 |                 pf_xdev = pci_get_drvdata(pdev->physfn);
         |                                                 ^~~~~~
         |                                                 is_physfn
   drivers/net/ethernet/yunsilicon/xsc/net/main.c: At top level:
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:2769:24: warning: no previous prototype for 'xsc_tirc_get_default_config' [-Wmissing-prototypes]
    2769 | struct xsc_tirc_config xsc_tirc_get_default_config(enum xsc_traffic_types tt)
         |                        ^~~~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:2774:6: warning: no previous prototype for 'xsc_build_rss_params' [-Wmissing-prototypes]
    2774 | void xsc_build_rss_params(struct xsc_rss_params *rss_params, u16 num_channels)
         |      ^~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:2792:6: warning: no previous prototype for 'xsc_eth_build_nic_params' [-Wmissing-prototypes]
    2792 | void xsc_eth_build_nic_params(struct xsc_adapter *adapter, u32 ch_num, u32 tc_num)
         |      ^~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/main.c:2814:6: warning: no previous prototype for 'xsc_eth_build_nic_netdev' [-Wmissing-prototypes]
    2814 | void xsc_eth_build_nic_netdev(struct xsc_adapter *adapter)
         |      ^~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/main.c:2885:5: warning: no previous prototype for 'xsc_eth_create_xdev_resources' [-Wmissing-prototypes]
    2885 | int xsc_eth_create_xdev_resources(struct xsc_core_device *xdev)
         |     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/main.c:2906:5: warning: no previous prototype for 'xsc_eth_init_nic_rx' [-Wmissing-prototypes]
    2906 | int xsc_eth_init_nic_rx(struct xsc_adapter *adapter)
         |     ^~~~~~~~~~~~~~~~~~~
--
   drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ctrl.c:302:6: warning: no previous prototype for 'xsc_eth_ctrl_fini' [-Wmissing-prototypes]
     302 | void xsc_eth_ctrl_fini(void)
         |      ^~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ctrl.c:307:5: warning: no previous prototype for 'xsc_eth_ctrl_init' [-Wmissing-prototypes]
     307 | int xsc_eth_ctrl_init(void)
         |     ^~~~~~~~~~~~~~~~~
--
   drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_tx.c:30:5: warning: no previous prototype for 'xsc_tx_get_gso_ihs' [-Wmissing-prototypes]
      30 | u16 xsc_tx_get_gso_ihs(struct xsc_sq *sq, struct sk_buff *skb)
         |     ^~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_tx.c:51:6: warning: no previous prototype for 'xsc_txwqe_build_cseg_csum' [-Wmissing-prototypes]
      51 | void xsc_txwqe_build_cseg_csum(struct xsc_sq *sq,
         |      ^~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_tx.c:219:6: warning: no previous prototype for 'xsc_txwqe_complete' [-Wmissing-prototypes]
     219 | void xsc_txwqe_complete(struct xsc_sq *sq, struct sk_buff *skb,
         |      ^~~~~~~~~~~~~~~~~~
--
>> drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_rx.c:478:6: warning: no previous prototype for 'xsc_page_dma_unmap' [-Wmissing-prototypes]
     478 | void xsc_page_dma_unmap(struct xsc_rq *rq, struct xsc_dma_info *dma_info)
         |      ^~~~~~~~~~~~~~~~~~
--
   drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ethtool.c:124:5: warning: no previous prototype for 'xsc_priv_flags_num' [-Wmissing-prototypes]
     124 | int xsc_priv_flags_num(void)
         |     ^~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ethtool.c:129:13: warning: no previous prototype for 'xsc_priv_flags_name' [-Wmissing-prototypes]
     129 | const char *xsc_priv_flags_name(int flag)
         |             ^~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ethtool.c:155:5: warning: no previous prototype for 'xsc_set_priv_flags' [-Wmissing-prototypes]
     155 | int xsc_set_priv_flags(struct net_device *dev, u32 pflags)
         |     ^~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ethtool.c:254:5: warning: no previous prototype for 'xsc_get_priv_flags' [-Wmissing-prototypes]
     254 | u32 xsc_get_priv_flags(struct net_device *dev)
         |     ^~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ethtool.c:736:5: warning: no previous prototype for 'xsc_get_rxnfc' [-Wmissing-prototypes]
     736 | int xsc_get_rxnfc(struct net_device *dev, struct ethtool_rxnfc *info, u32 *rule_locs)
         |     ^~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ethtool.c:759:5: warning: no previous prototype for 'xsc_set_rxnfc' [-Wmissing-prototypes]
     759 | int xsc_set_rxnfc(struct net_device *dev, struct ethtool_rxnfc *cmd)
         |     ^~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ethtool.c:788:5: warning: no previous prototype for 'xsc_get_rxfh' [-Wmissing-prototypes]
     788 | int xsc_get_rxfh(struct net_device *netdev, u32 *indir, u8 *key, u8 *hfunc)
         |     ^~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/net/xsc_eth_ethtool.c:807:5: warning: no previous prototype for 'xsc_set_rxfh' [-Wmissing-prototypes]
     807 | int xsc_set_rxfh(struct net_device *dev, const u32 *indir, const u8 *key, const u8 hfunc)
         |     ^~~~~~~~~~~~
--
   drivers/net/ethernet/yunsilicon/xsc/pci/main.c:136:4: warning: no previous prototype for 'xsc_devid_to_pcie_no' [-Wmissing-prototypes]
     136 | u8 xsc_devid_to_pcie_no(int dev_id)
         |    ^~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/pci/main.c:288:5: warning: no previous prototype for 'xsc_priv_init' [-Wmissing-prototypes]
     288 | int xsc_priv_init(struct xsc_core_device *dev)
         |     ^~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/pci/main.c:302:5: warning: no previous prototype for 'xsc_dev_res_init' [-Wmissing-prototypes]
     302 | int xsc_dev_res_init(struct xsc_core_device *dev)
         |     ^~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/main.c:321:6: warning: no previous prototype for 'xsc_dev_res_cleanup' [-Wmissing-prototypes]
     321 | void xsc_dev_res_cleanup(struct xsc_core_device *dev)
         |      ^~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/main.c:327:6: warning: no previous prototype for 'xsc_init_reg_addr' [-Wmissing-prototypes]
     327 | void xsc_init_reg_addr(struct xsc_core_device *dev)
         |      ^~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/main.c:518:5: warning: no previous prototype for 'xsc_reset_function_resource' [-Wmissing-prototypes]
     518 | int xsc_reset_function_resource(struct xsc_core_device *dev)
         |     ^~~~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/main.c: In function 'xsc_init_once':
   drivers/net/ethernet/yunsilicon/xsc/pci/main.c:612:33: error: 'struct pci_dev' has no member named 'physfn'; did you mean 'is_physfn'?
     612 |                 if (!dev->pdev->physfn) {
         |                                 ^~~~~~
         |                                 is_physfn
   drivers/net/ethernet/yunsilicon/xsc/pci/main.c: At top level:
>> drivers/net/ethernet/yunsilicon/xsc/pci/main.c:718:5: warning: no previous prototype for 'xsc_load_one' [-Wmissing-prototypes]
     718 | int xsc_load_one(struct xsc_core_device *dev, bool boot)
         |     ^~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/main.c:796:5: warning: no previous prototype for 'xsc_unload_one' [-Wmissing-prototypes]
     796 | int xsc_unload_one(struct xsc_core_device *dev, bool cleanup)
         |     ^~~~~~~~~~~~~~
--
   drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:59:5: warning: no previous prototype for 'xsc_cmd_create_lag' [-Wmissing-prototypes]
      59 | int xsc_cmd_create_lag(struct xsc_lag *ldev, u8 flags)
         |     ^~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:130:5: warning: no previous prototype for 'xsc_cmd_modify_lag' [-Wmissing-prototypes]
     130 | int xsc_cmd_modify_lag(struct xsc_lag *ldev)
         |     ^~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:167:5: warning: no previous prototype for 'xsc_cmd_destroy_lag' [-Wmissing-prototypes]
     167 | int xsc_cmd_destroy_lag(struct xsc_lag *ldev, u8 bond_flags)
         |     ^~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:292:6: warning: no previous prototype for 'xsc_activate_lag' [-Wmissing-prototypes]
     292 | void xsc_activate_lag(struct xsc_lag *ldev, u8 flags)
         |      ^~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:310:6: warning: no previous prototype for 'xsc_modify_lag' [-Wmissing-prototypes]
     310 | void xsc_modify_lag(struct xsc_lag *ldev)
         |      ^~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:500:5: warning: no previous prototype for 'xsc_lag_dev_get_netdev_idx' [-Wmissing-prototypes]
     500 | int xsc_lag_dev_get_netdev_idx(struct xsc_lag *ldev,
         |     ^~~~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:512:22: warning: no previous prototype for 'bond_lag_hash_type' [-Wmissing-prototypes]
     512 | enum netdev_lag_hash bond_lag_hash_type(struct bonding *bond)
         |                      ^~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:723:6: warning: no previous prototype for 'xsc_esw_multipath_prereq' [-Wmissing-prototypes]
     723 | bool xsc_esw_multipath_prereq(struct xsc_core_device *xdev0,
         |      ^~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:734:6: warning: no previous prototype for 'xsc_lag_multipath_check_prereq' [-Wmissing-prototypes]
     734 | bool xsc_lag_multipath_check_prereq(struct xsc_lag *ldev)
         |      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:976:28: warning: no previous prototype for 'xsc_lag_init_fib_work' [-Wmissing-prototypes]
     976 | struct xsc_fib_event_work *xsc_lag_init_fib_work(struct xsc_lag *ldev, unsigned long event)
         |                            ^~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:990:5: warning: no previous prototype for 'xsc_lag_fib_event' [-Wmissing-prototypes]
     990 | int xsc_lag_fib_event(struct notifier_block *nb,
         |     ^~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:1063:5: warning: no previous prototype for 'xsc_lag_mp_init' [-Wmissing-prototypes]
    1063 | int xsc_lag_mp_init(struct xsc_lag *ldev)
         |     ^~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:1091:5: warning: no previous prototype for '__xsc_lag_add_xdev' [-Wmissing-prototypes]
    1091 | int __xsc_lag_add_xdev(struct xsc_core_device *xdev)
         |     ^~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:1141:6: warning: no previous prototype for 'xsc_lag_dev_add_pf' [-Wmissing-prototypes]
    1141 | void xsc_lag_dev_add_pf(struct xsc_lag *ldev,
         |      ^~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:1156:6: warning: no previous prototype for 'xsc_lag_update_trackers' [-Wmissing-prototypes]
    1156 | void xsc_lag_update_trackers(struct xsc_lag *ldev)
         |      ^~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:1224:6: warning: no previous prototype for 'xsc_lag_dev_remove_pf' [-Wmissing-prototypes]
    1224 | void xsc_lag_dev_remove_pf(struct xsc_lag *ldev, struct xsc_core_device *xdev)
         |      ^~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:1240:6: warning: no previous prototype for 'xsc_lag_mp_cleanup' [-Wmissing-prototypes]
    1240 | void xsc_lag_mp_cleanup(struct xsc_lag *ldev)
         |      ^~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:1251:6: warning: no previous prototype for 'xsc_lag_dev_free' [-Wmissing-prototypes]
    1251 | void xsc_lag_dev_free(struct kref *ref)
         |      ^~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:1265:6: warning: no previous prototype for 'xsc_lag_dev_put' [-Wmissing-prototypes]
    1265 | void xsc_lag_dev_put(struct xsc_lag *ldev)
         |      ^~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:1285:6: warning: no previous prototype for 'xsc_lag_dev_remove_xdev' [-Wmissing-prototypes]
    1285 | void xsc_lag_dev_remove_xdev(struct xsc_lag *ldev, struct xsc_core_device *xdev)
         |      ^~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/xsc_lag.c:1303:6: warning: no previous prototype for '__xsc_lag_remove_xdev' [-Wmissing-prototypes]
    1303 | void __xsc_lag_remove_xdev(struct xsc_core_device *xdev)
         |      ^~~~~~~~~~~~~~~~~~~~~
--
>> drivers/net/ethernet/yunsilicon/xsc/pci/xsc_pci_ctrl.c:255:5: warning: no previous prototype for 'noop_pre' [-Wmissing-prototypes]
     255 | int noop_pre(struct kprobe *p, struct pt_regs *regs) { return 0; }
         |     ^~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/xsc_pci_ctrl.c:264:5: warning: no previous prototype for 'find_kallsyms_lookup_name' [-Wmissing-prototypes]
     264 | int find_kallsyms_lookup_name(void)
         |     ^~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/xsc_pci_ctrl.c:310:5: warning: no previous prototype for 'xsc_pci_ctrl_exec_ioctl' [-Wmissing-prototypes]
     310 | int xsc_pci_ctrl_exec_ioctl(struct xsc_core_device *xdev, void *in, int in_size, void *out,
         |     ^~~~~~~~~~~~~~~~~~~~~~~
--
   drivers/net/ethernet/yunsilicon/xsc/pci/pci_irq.c:721:5: warning: no previous prototype for 'xsc_request_irq_for_cmdq' [-Wmissing-prototypes]
     721 | int xsc_request_irq_for_cmdq(struct xsc_core_device *dev, u8 vecidx)
         |     ^~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/pci_irq.c:734:6: warning: no previous prototype for 'xsc_free_irq_for_cmdq' [-Wmissing-prototypes]
     734 | void xsc_free_irq_for_cmdq(struct xsc_core_device *dev)
         |      ^~~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/pci/pci_irq.c:756:5: warning: no previous prototype for 'xsc_request_irq_for_event' [-Wmissing-prototypes]
     756 | int xsc_request_irq_for_event(struct xsc_core_device *dev)
         |     ^~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/yunsilicon/xsc/pci/pci_irq.c:767:6: warning: no previous prototype for 'xsc_free_irq_for_event' [-Wmissing-prototypes]
     767 | void xsc_free_irq_for_event(struct xsc_core_device *dev)
         |      ^~~~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/yunsilicon/xsc/pci/pci_irq.c:773:5: warning: no previous prototype for 'xsc_cmd_enable_msix' [-Wmissing-prototypes]
     773 | int xsc_cmd_enable_msix(struct xsc_core_device *xdev)
         |     ^~~~~~~~~~~~~~~~~~~
..
vim +/xsc_eth_cq_error_event +197 drivers/net/ethernet/yunsilicon/xsc/net/main.c
   165	
 > 166	int xsc_rx_alloc_page_cache(struct xsc_rq *rq, int node, u8 log_init_sz)
   167	{
   168		struct xsc_page_cache *cache = &rq->page_cache;
   169	
   170		cache->sz = 1 << log_init_sz;
   171		cache->page_cache = kvzalloc_node(cache->sz * sizeof(*cache->page_cache),
   172						  GFP_KERNEL, node);
   173		if (!cache->page_cache)
   174			return -ENOMEM;
   175	
   176		return 0;
   177	}
   178	
   179	void xsc_rx_free_page_cache(struct xsc_rq *rq)
   180	{
   181		struct xsc_page_cache *cache = &rq->page_cache;
   182		u32 i;
   183	
   184		for (i = cache->head; i != cache->tail; i = (i + 1) & (cache->sz - 1)) {
   185			struct xsc_dma_info *dma_info = &cache->page_cache[i];
   186	
   187			xsc_page_release_dynamic(rq, dma_info, false);
   188		}
   189		kvfree(cache->page_cache);
   190	}
   191	
   192	int xsc_eth_reset(struct xsc_core_device *dev)
   193	{
   194		return 0;
   195	}
   196	
 > 197	void xsc_eth_cq_error_event(struct xsc_core_cq *xcq, enum xsc_event event)
   198	{
   199		struct xsc_cq *xsc_cq = container_of(xcq, struct xsc_cq, xcq);
   200		struct xsc_core_device *xdev = xsc_cq->xdev;
   201	
   202		if (event != XSC_EVENT_TYPE_CQ_ERROR) {
   203			xsc_core_err(xdev, "Unexpected event type %d on CQ %06x\n",
   204				     event, xcq->cqn);
   205			return;
   206		}
   207	
   208		xsc_core_err(xdev, "Eth catch CQ ERROR:%x, cqn: %d\n", event, xcq->cqn);
   209	}
   210	
 > 211	void xsc_eth_completion_event(struct xsc_core_cq *xcq)
   212	{
   213		struct xsc_cq *cq = container_of(xcq, struct xsc_cq, xcq);
   214		struct xsc_core_device *xdev = cq->xdev;
   215		struct xsc_rq *rq = NULL;
   216	
   217		if (unlikely(!cq->channel)) {
   218			xsc_core_warn(xdev, "cq%d->channel is null\n", xcq->cqn);
   219			return;
   220		}
   221	
   222		rq = &cq->channel->qp.rq[0];
   223	
   224		set_bit(XSC_CHANNEL_NAPI_SCHED, &cq->channel->flags);
   225		cq->channel->stats->events++;
   226		cq->channel->stats->poll = 0;
   227		if (cq->rx)
   228			cq->channel->rx_int = 1;
   229		else
   230			cq->channel->rx_int = 0;
   231	
   232		if (!test_bit(XSC_ETH_RQ_STATE_ENABLED, &rq->state))
   233			xsc_core_warn(xdev, "ch%d_cq%d, napi_flag=0x%lx\n",
   234				      cq->channel->chl_idx, xcq->cqn, cq->napi->state);
   235	
   236		napi_schedule(cq->napi);
   237	}
   238	
   239	static inline int xsc_cmd_destroy_cq(struct xsc_core_device *dev, struct xsc_core_cq *xcq)
   240	{
   241		struct xsc_destroy_cq_mbox_in in;
   242		struct xsc_destroy_cq_mbox_out out;
   243		int err;
   244	
   245		memset(&in, 0, sizeof(in));
   246		memset(&out, 0, sizeof(out));
   247		in.hdr.opcode = cpu_to_be16(XSC_CMD_OP_DESTROY_CQ);
   248		in.cqn = cpu_to_be32(xcq->cqn);
   249		err = xsc_cmd_exec(dev, &in, sizeof(in), &out, sizeof(out));
   250		if (err || out.hdr.status) {
   251			xsc_core_err(dev, "failed to destroy cq, err=%d out.status=%u\n",
   252				     err, out.hdr.status);
   253			return -ENOEXEC;
   254		}
   255	
   256		xcq->cqn = 0;
   257		return 0;
   258	}
   259	
   260	int xsc_eth_create_cq(struct xsc_core_device *xdev, struct xsc_core_cq *xcq,
   261			      struct xsc_create_cq_mbox_in *in, int insize)
   262	{
   263		int err, ret = -1;
   264		struct xsc_cq_table *table = &xdev->dev_res->cq_table;
   265		struct xsc_create_cq_mbox_out out;
   266	
   267		in->hdr.opcode = cpu_to_be16(XSC_CMD_OP_CREATE_CQ);
   268		ret = xsc_cmd_exec(xdev, in, insize, &out, sizeof(out));
   269		if (ret || out.hdr.status) {
   270			xsc_core_err(xdev, "failed to create cq, err=%d out.status=%u\n",
   271				     ret, out.hdr.status);
   272			return -ENOEXEC;
   273		}
   274	
   275		xcq->cqn = be32_to_cpu(out.cqn) & 0xffffff;
   276		xcq->cons_index = 0;
   277		xcq->arm_sn = 0;
   278		atomic_set(&xcq->refcount, 1);
   279		init_completion(&xcq->free);
   280	
   281		spin_lock_irq(&table->lock);
   282		ret = radix_tree_insert(&table->tree, xcq->cqn, xcq);
   283		spin_unlock_irq(&table->lock);
   284		if (ret)
   285			goto err_insert_cq;
   286		return 0;
   287	
   288	err_insert_cq:
   289		err = xsc_cmd_destroy_cq(xdev, xcq);
   290		if (err)
   291			xsc_core_warn(xdev, "failed to destroy cqn=%d, err=%d\n", xcq->cqn, err);
   292		return ret;
   293	}
   294	
   295	int xsc_eth_destroy_cq(struct xsc_core_device *xdev, struct xsc_cq *cq)
   296	{
   297		struct xsc_cq_table *table = &xdev->dev_res->cq_table;
   298		struct xsc_core_cq *tmp;
   299		int err;
   300	
   301		spin_lock_irq(&table->lock);
   302		tmp = radix_tree_delete(&table->tree, cq->xcq.cqn);
   303		spin_unlock_irq(&table->lock);
   304		if (!tmp) {
   305			err = -ENOENT;
   306			goto err_delete_cq;
   307		}
   308	
   309		if (tmp != &cq->xcq) {
   310			err = -EINVAL;
   311			goto err_delete_cq;
   312		}
   313	
   314		err = xsc_cmd_destroy_cq(xdev, &cq->xcq);
   315		if (err)
   316			goto err_destroy_cq;
   317	
   318		if (atomic_dec_and_test(&cq->xcq.refcount))
   319			complete(&cq->xcq.free);
   320		wait_for_completion(&cq->xcq.free);
   321		return 0;
   322	
   323	err_destroy_cq:
   324		xsc_core_warn(xdev, "failed to destroy cqn=%d, err=%d\n",
   325			      cq->xcq.cqn, err);
   326		return err;
   327	err_delete_cq:
   328		xsc_core_warn(xdev, "cqn=%d not found in tree, err=%d\n",
   329			      cq->xcq.cqn, err);
   330		return err;
   331	}
   332	
 > 333	void xsc_eth_free_cq(struct xsc_cq *cq)
   334	{
   335		xsc_eth_wq_destroy(&cq->wq_ctrl);
   336	}
   337	
   338	int xsc_eth_create_rss_qp_rqs(struct xsc_core_device *xdev,
   339				      struct xsc_create_multiqp_mbox_in *in,
   340				      int insize,
   341				      int *prqn_base)
   342	{
   343		int ret;
   344		struct xsc_create_multiqp_mbox_out out;
   345	
   346		in->hdr.opcode = cpu_to_be16(XSC_CMD_OP_CREATE_MULTI_QP);
   347		ret = xsc_cmd_exec(xdev, in, insize, &out, sizeof(out));
   348		if (ret || out.hdr.status) {
   349			xsc_core_err(xdev,
   350				     "failed to create rss rq, qp_num=%d, type=%d, err=%d out.status=%u\n",
   351				     in->qp_num, in->qp_type, ret, out.hdr.status);
   352			return -ENOEXEC;
   353		}
   354	
   355		*prqn_base = be32_to_cpu(out.qpn_base) & 0xffffff;
   356		return 0;
   357	}
   358	
 > 359	void xsc_eth_qp_event(struct xsc_core_qp *qp, int type)
   360	{
   361		struct xsc_rq *rq;
   362		struct xsc_sq *sq;
   363		struct xsc_core_device *xdev;
   364	
   365		if (qp->eth_queue_type == XSC_RES_RQ) {
   366			rq = container_of(qp, struct xsc_rq, cqp);
   367			xdev = rq->cq.xdev;
   368		} else if (qp->eth_queue_type == XSC_RES_SQ) {
   369			sq = container_of(qp, struct xsc_sq, cqp);
   370			xdev = sq->cq.xdev;
   371		} else {
   372			pr_err("%s:Unknown eth qp type %d\n", __func__, type);
   373			return;
   374		}
   375	
   376		switch (type) {
   377		case XSC_EVENT_TYPE_WQ_CATAS_ERROR:
   378		case XSC_EVENT_TYPE_WQ_INVAL_REQ_ERROR:
   379		case XSC_EVENT_TYPE_WQ_ACCESS_ERROR:
   380			xsc_core_err(xdev, "%s:Async event %x on QP %d\n", __func__, type, qp->qpn);
   381			break;
   382		default:
   383			xsc_core_err(xdev, "%s: Unexpected event type %d on QP %d\n",
   384				     __func__, type, qp->qpn);
   385			return;
   386		}
   387	}
   388	
 > 389	int xsc_eth_create_qp_rq(struct xsc_core_device *xdev, struct xsc_rq *prq,
   390				 struct xsc_create_qp_mbox_in *in, int insize)
   391	{
   392		int ret = -1;
   393		struct xsc_create_qp_mbox_out out;
   394	
   395		in->hdr.opcode = cpu_to_be16(XSC_CMD_OP_CREATE_QP);
   396		ret = xsc_cmd_exec(xdev, in, insize, &out, sizeof(out));
   397		if (ret || out.hdr.status) {
   398			xsc_core_err(xdev, "failed to create rq, err=%d out.status=%u\n",
   399				     ret, out.hdr.status);
   400			return -ENOEXEC;
   401		}
   402	
   403		prq->rqn = be32_to_cpu(out.qpn) & 0xffffff;
   404		prq->cqp.event = xsc_eth_qp_event;
   405		prq->cqp.eth_queue_type = XSC_RES_RQ;
   406	
   407		ret = create_resource_common(xdev, &prq->cqp);
   408		if (ret) {
   409			xsc_core_err(xdev, "%s:error qp:%d errno:%d\n", __func__, prq->rqn, ret);
   410			return ret;
   411		}
   412	
   413		return 0;
   414	}
   415	
-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
                    
                  
                  
                          
                            
                            1
                            
                          
                          
                            
                            0
                            
                          
                          
                            
    
                          
                        
                    
                        
                            
                                
                            
                            [PATCH OLK-6.6] ocfs2: fix slab-use-after-free due to dangling pointer dqi_priv
                        
                        
by Xiangwei Li 22 Jan '25
                    by Xiangwei Li 22 Jan '25
22 Jan '25
                    
                        From: Dennis Lam <dennis.lamerice(a)gmail.com>
mainline inclusion
from mainline-v6.13-rc6
commit 5f3fd772d152229d94602bca243fbb658068a597
category: bugfix
bugzilla: https://gitee.com/src-openeuler/kernel/issues/IBID30
CVE: CVE-2024-57892
Reference: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?…
-------------------------------------
When mounting ocfs2 and then remounting it as read-only, a
slab-use-after-free occurs after the user uses a syscall to
quota_getnextquota.  Specifically, sb_dqinfo(sb, type)->dqi_priv is the
dangling pointer.
During the remounting process, the pointer dqi_priv is freed but is never
set as null leaving it to be accessed.  Additionally, the read-only option
for remounting sets the DQUOT_SUSPENDED flag instead of setting the
DQUOT_USAGE_ENABLED flags.  Moreover, later in the process of getting the
next quota, the function ocfs2_get_next_id is called and only checks the
quota usage flags and not the quota suspended flags.
To fix this, I set dqi_priv to null when it is freed after remounting with
read-only and put a check for DQUOT_SUSPENDED in ocfs2_get_next_id.
[akpm(a)linux-foundation.org: coding-style cleanups]
Link: https://lkml.kernel.org/r/20241218023924.22821-2-dennis.lamerice@gmail.com
Fixes: 8f9e8f5fcc05 ("ocfs2: Fix Q_GETNEXTQUOTA for filesystem without quotas")
Signed-off-by: Dennis Lam <dennis.lamerice(a)gmail.com>
Reported-by: syzbot+d173bf8a5a7faeede34c(a)syzkaller.appspotmail.com
Tested-by: syzbot+d173bf8a5a7faeede34c(a)syzkaller.appspotmail.com
Closes: https://lore.kernel.org/all/6731d26f.050a0220.1fb99c.014b.GAE@google.com/T/
Reviewed-by: Joseph Qi <joseph.qi(a)linux.alibaba.com>
Cc: Mark Fasheh <mark(a)fasheh.com>
Cc: Joel Becker <jlbec(a)evilplan.org>
Cc: Junxiao Bi <junxiao.bi(a)oracle.com>
Cc: Changwei Ge <gechangwei(a)live.cn>
Cc: Jun Piao <piaojun(a)huawei.com>
Cc: <stable(a)vger.kernel.org>
Signed-off-by: Andrew Morton <akpm(a)linux-foundation.org>
Signed-off-by: Xiangwei Li <liwei728(a)huawei.com>
---
 fs/ocfs2/quota_global.c | 2 +-
 fs/ocfs2/quota_local.c  | 1 +
 2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/fs/ocfs2/quota_global.c b/fs/ocfs2/quota_global.c
index dc9f76ab7e13..0dffd6a44d39 100644
--- a/fs/ocfs2/quota_global.c
+++ b/fs/ocfs2/quota_global.c
@@ -881,7 +881,7 @@ static int ocfs2_get_next_id(struct super_block *sb, struct kqid *qid)
 	int status = 0;
 
 	trace_ocfs2_get_next_id(from_kqid(&init_user_ns, *qid), type);
-	if (!sb_has_quota_loaded(sb, type)) {
+	if (!sb_has_quota_active(sb, type)) {
 		status = -ESRCH;
 		goto out;
 	}
diff --git a/fs/ocfs2/quota_local.c b/fs/ocfs2/quota_local.c
index 257f13cdd14c..4b4fa58cd32f 100644
--- a/fs/ocfs2/quota_local.c
+++ b/fs/ocfs2/quota_local.c
@@ -864,6 +864,7 @@ static int ocfs2_local_free_info(struct super_block *sb, int type)
 	brelse(oinfo->dqi_libh);
 	brelse(oinfo->dqi_lqi_bh);
 	kfree(oinfo);
+	info->dqi_priv = NULL;
 	return status;
 }
 
-- 
2.25.1
                    
                  
                  
                          
                            
                            2
                            
                          
                          
                            
                            1
                            
                          
                          
                            
    
                          
                        
                    
                    
                        Dennis Lam (1):
  ocfs2: fix slab-use-after-free due to dangling pointer dqi_priv
Joseph Qi (1):
  ocfs2: correct return value of ocfs2_local_free_info()
 fs/ocfs2/quota_global.c |  2 +-
 fs/ocfs2/quota_local.c  | 10 ++++------
 2 files changed, 5 insertions(+), 7 deletions(-)
-- 
2.25.1
                    
                  
                  
                          
                            
                            2
                            
                          
                          
                            
                            3
                            
                          
                          
                            
    
                          
                        
                    
                    
                        Dennis Lam (1):
  ocfs2: fix slab-use-after-free due to dangling pointer dqi_priv
Joseph Qi (1):
  ocfs2: correct return value of ocfs2_local_free_info()
 fs/ocfs2/quota_global.c |  2 +-
 fs/ocfs2/quota_local.c  | 10 ++++------
 2 files changed, 5 insertions(+), 7 deletions(-)
-- 
2.25.1
                    
                  
                  
                          
                            
                            2
                            
                          
                          
                            
                            3
                            
                          
                          
                            
    
                          
                        
                    
                    
                        fix CVE-2024-57906
Javier Carrasco (1):
  iio: adc: ti-ads8688: fix information leak in triggered buffer
 drivers/iio/adc/ti-ads8688.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
-- 
2.34.1
                    
                  
                  
                          
                            
                            2
                            
                          
                          
                            
                            2
                            
                          
                          
                            
    
                          
                        
                    
                        
                            
                                
                            
                            [openeuler:OLK-6.6 1834/1834] drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1741:9: sparse: sparse: Using plain integer as NULL pointer
                        
                        
by kernel test robot 22 Jan '25
                    by kernel test robot 22 Jan '25
22 Jan '25
                    
                        tree:   https://gitee.com/openeuler/kernel.git OLK-6.6
head:   75c81bcddd82381fbd4cef477a5b56eb2fe56697
commit: 4b4aa2fdd905bb63f965668452f1d1986555e1a3 [1834/1834] Huawei BMA: Adding Huawei BMA driver: cdev_veth_drv
config: x86_64-randconfig-121-20250122 (https://download.01.org/0day-ci/archive/20250122/202501221622.ZyAVvHaC-lkp@…)
compiler: gcc-12 (Debian 12.2.0-14) 12.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250122/202501221622.ZyAVvHaC-lkp@…)
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(a)intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202501221622.ZyAVvHaC-lkp@intel.com/
sparse warnings: (new ones prefixed by >>)
>> drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1741:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1750:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1764:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1812:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1816:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1832:25: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1838:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1842:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1849:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:56:17: sparse: sparse: incorrect type in initializer (different base types) @@     expected restricted __poll_t ( *poll )( ... ) @@     got unsigned int ( * )( ... ) @@
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:56:17: sparse:     expected restricted __poll_t ( *poll )( ... )
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:56:17: sparse:     got unsigned int ( * )( ... )
>> drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:52:30: sparse: sparse: symbol 'g_eth_edma_cdev_fops' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:68:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:71:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:75:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:61:6: sparse: sparse: symbol 'dump_global_info' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:112:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:99:6: sparse: sparse: symbol 'edma_veth_free_tx_resources' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:115:6: sparse: sparse: symbol 'edma_veth_free_all_tx_resources' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:133:17: sparse: sparse: Using plain integer as NULL pointer
>> drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:124:5: sparse: sparse: symbol 'edma_veth_setup_tx_resources' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:158:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:148:5: sparse: sparse: symbol 'edma_veth_setup_all_tx_resources' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:201:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:192:5: sparse: sparse: symbol 'edma_veth_setup_rx_resources' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:226:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:216:5: sparse: sparse: symbol 'edma_veth_setup_all_rx_resources' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:273:9: sparse: sparse: Using plain integer as NULL pointer
>> drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:259:6: sparse: sparse: symbol 'edma_veth_free_rx_resources' was not declared. Should it be static?
>> drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:276:6: sparse: sparse: symbol 'edma_veth_free_all_rx_resources' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:316:25: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:322:25: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:334:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:346:25: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:352:25: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:364:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:285:5: sparse: sparse: symbol 'edma_veth_setup_all_rxtx_queue' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:381:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:385:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:390:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:394:9: sparse: sparse: Using plain integer as NULL pointer
>> drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:369:6: sparse: sparse: symbol 'edma_veth_dump' was not declared. Should it be static?
>> drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:398:5: sparse: sparse: symbol 'edma_veth_setup_resource' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:424:5: sparse: sparse: symbol 'edma_veth_free_rxtx_queue' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:466:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:469:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:472:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:463:6: sparse: sparse: symbol 'edma_veth_free_resource' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:484:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:492:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:500:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:506:25: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:525:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:475:5: sparse: sparse: symbol 'edma_veth_send_one_pkt' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:577:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:608:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:615:33: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:631:33: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:647:25: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:652:25: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:661:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:673:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:684:25: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:716:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:722:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:740:33: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:745:25: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:746:25: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:754:25: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:764:25: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:772:25: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:787:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:833:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:840:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:843:25: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:858:25: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:875:25: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:801:5: sparse: sparse: symbol 'edma_veth_recv_pkt' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:883:6: sparse: sparse: symbol 'edma_task_do_packet_recv' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:916:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:923:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:908:5: sparse: sparse: symbol '__dmacmp_err_deal_2' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:941:5: sparse: sparse: symbol 'edma_veth_check_dma_status' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1005:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1008:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1023:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1026:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:962:5: sparse: sparse: symbol '__check_dmacmp_H_2' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1059:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1078:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1096:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1042:5: sparse: sparse: symbol '__checkspace_H_2' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1147:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1167:17: sparse: sparse: Using plain integer as NULL pointer
>> drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1116:5: sparse: sparse: symbol '__make_dmalistbd_h2b_H_2' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1227:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1249:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1198:5: sparse: sparse: symbol '__make_dmalistbd_b2h_H_2' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1289:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1309:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1278:5: sparse: sparse: symbol '__start_dmalist_H_2' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1322:5: sparse: sparse: symbol 'check_dma_queue_fault_2' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1361:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1367:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1376:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1383:25: sparse: sparse: Using plain integer as NULL pointer
>> drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1352:5: sparse: sparse: symbol '__dma_rxtx_H_2' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1424:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1425:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1439:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1440:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1419:6: sparse: sparse: symbol 'edma_task_do_data_transmit' was not declared. Should it be static?
>> drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1456:5: sparse: sparse: symbol 'edma_tasklet_setup' was not declared. Should it be static?
>> drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1504:6: sparse: sparse: symbol 'edma_tasklet_free' was not declared. Should it be static?
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1554:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1577:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1588:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1598:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1612:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1619:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1645:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1680:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1693:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1720:17: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1725:9: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1405:25: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:1405:25: sparse: sparse: Using plain integer as NULL pointer
   drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c:94:26: sparse: sparse: cast removes address space '__iomem' of expression
vim +1741 drivers/net/ethernet/huawei/bma/cdev_veth_drv/virtual_cdev_eth_net.c
  1736	
  1737	int cdev_open(struct inode *inode_ptr, struct file *filp)
  1738	{
  1739		struct cdev_dev_s *dev = &g_eth_edmaprivate.cdev;
  1740	
> 1741		LOG(DLOG_DEBUG, "Open device.");
  1742	
  1743		if (!inode_ptr || !filp)
  1744			return -EFAULT;
  1745	
  1746		/* only one instance is allowed. */
  1747		if (IS_CDEV_IN_OPEN_STATE())
  1748			return -EBUSY;
  1749	
  1750		LOG(DLOG_DEBUG, "Init flag, rx: %d, tx:%d",
  1751		    g_eth_edmaprivate.prx_queue->pshmqhd_v->init,
  1752		    g_eth_edmaprivate.ptx_queue->pshmqhd_v->init);
  1753	
  1754		/* save to private data. */
  1755		filp->private_data = dev;
  1756		SET_CDEV_OPEN_STATE(CDEV_OPENED);
  1757		g_read_pos = 0;
  1758	
  1759		return 0;
  1760	}
  1761	
  1762	int cdev_release(struct inode *inode_ptr, struct file *filp)
  1763	{
  1764		LOG(DLOG_DEBUG, "Close device.");
  1765	
  1766		if (!filp)
  1767			return 0;
  1768	
  1769		filp->private_data = NULL;
  1770	
  1771		SET_CDEV_OPEN_STATE(CDEV_CLOSED);
  1772	
  1773		return 0;
  1774	}
  1775	
  1776	unsigned int cdev_poll(struct file *filp, poll_table *wait)
  1777	{
  1778		unsigned int mask = 0;
  1779		wait_queue_head_t *queue_head = NULL;
  1780	
  1781		if (!filp)
  1782			return 0;
  1783	
  1784		edma_veth_dump();
  1785	
  1786		queue_head = (wait_queue_head_t *)
  1787		    bma_cdev_get_wait_queue(GET_PRIVATE_DATA(filp));
  1788		if (!queue_head)
  1789			return 0;
  1790	
  1791		/* check or add to wait queue. */
  1792		poll_wait(filp, queue_head, wait);
  1793	
  1794		if (!edma_is_queue_ready(g_eth_edmaprivate.prx_queue))
  1795			return 0;
  1796	
  1797		if (cdev_check_ring_recv() > 0)
  1798			mask = (POLLIN | POLLRDNORM);
  1799	
  1800		return mask;
  1801	}
  1802	
  1803	ssize_t cdev_read(struct file *filp, char __user *data,
  1804			  size_t count, loff_t *ppos)
  1805	{
  1806		struct edma_eth_dev_s *dev = &g_eth_edmaprivate;
  1807		ssize_t length = 0;
  1808	
  1809		if (!data || count >= MAX_PACKET_LEN)
  1810			return -EFAULT;
  1811	
  1812		LOG(DLOG_DEBUG, "read begin, count: %zu, pos: %u.", count, g_read_pos);
  1813	
  1814		length = cdev_copy_packet_to_user(dev, data, count);
  1815	
> 1816		LOG(DLOG_DEBUG, "read done, length: %zd, pos: %u.", length, g_read_pos);
  1817	
  1818		return length;
  1819	}
  1820	
-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
                    
                  
                  
                          
                            
                            1
                            
                          
                          
                            
                            0
                            
                          
                          
                            
    
                          
                        
                    
                        
                            
                                
                            
                            [PATCH OLK-6.6] arm64: ptrace: fix partial SETREGSET for NT_ARM_TAGGED_ADDR_CTRL
                        
                        
by Yuntao Liu 22 Jan '25
                    by Yuntao Liu 22 Jan '25
22 Jan '25
                    
                        From: Mark Rutland <mark.rutland(a)arm.com>
stable inclusion
from stable-v6.6.66
commit 96035c0093db258975b8887676afe59a64c34a72
category: bugfix
bugzilla: https://gitee.com/src-openeuler/kernel/issues/IBJC6J
CVE: CVE-2024-57874
Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id…
--------------------------------
Currently tagged_addr_ctrl_set() doesn't initialize the temporary 'ctrl'
variable, and a SETREGSET call with a length of zero will leave this
uninitialized. Consequently tagged_addr_ctrl_set() will consume an
arbitrary value, potentially leaking up to 64 bits of memory from the
kernel stack. The read is limited to a specific slot on the stack, and
the issue does not provide a write mechanism.
As set_tagged_addr_ctrl() only accepts values where bits [63:4] zero and
rejects other values, a partial SETREGSET attempt will randomly succeed
or fail depending on the value of the uninitialized value, and the
exposure is significantly limited.
Fix this by initializing the temporary value before copying the regset
from userspace, as for other regsets (e.g. NT_PRSTATUS, NT_PRFPREG,
NT_ARM_SYSTEM_CALL). In the case of a zero-length write, the existing
value of the tagged address ctrl will be retained.
The NT_ARM_TAGGED_ADDR_CTRL regset is only visible in the
user_aarch64_view used by a native AArch64 task to manipulate another
native AArch64 task. As get_tagged_addr_ctrl() only returns an error
value when called for a compat task, tagged_addr_ctrl_get() and
tagged_addr_ctrl_set() should never observe an error value from
get_tagged_addr_ctrl(). Add a WARN_ON_ONCE() to both to indicate that
such an error would be unexpected, and error handlnig is not missing in
either case.
Fixes: 2200aa7154cb ("arm64: mte: ptrace: Add NT_ARM_TAGGED_ADDR_CTRL regset")
Cc: <stable(a)vger.kernel.org> # 5.10.x
Signed-off-by: Mark Rutland <mark.rutland(a)arm.com>
Cc: Will Deacon <will(a)kernel.org>
Reviewed-by: Mark Brown <broonie(a)kernel.org>
Link: https://lore.kernel.org/r/20241205121655.1824269-2-mark.rutland@arm.com
Signed-off-by: Catalin Marinas <catalin.marinas(a)arm.com>
Signed-off-by: Yuntao Liu <liuyuntao12(a)huawei.com>
---
 arch/arm64/kernel/ptrace.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/arch/arm64/kernel/ptrace.c b/arch/arm64/kernel/ptrace.c
index 28a5ddcf0a1e..d34b57caad49 100644
--- a/arch/arm64/kernel/ptrace.c
+++ b/arch/arm64/kernel/ptrace.c
@@ -1384,7 +1384,7 @@ static int tagged_addr_ctrl_get(struct task_struct *target,
 {
 	long ctrl = get_tagged_addr_ctrl(target);
 
-	if (IS_ERR_VALUE(ctrl))
+	if (WARN_ON_ONCE(IS_ERR_VALUE(ctrl)))
 		return ctrl;
 
 	return membuf_write(&to, &ctrl, sizeof(ctrl));
@@ -1398,6 +1398,10 @@ static int tagged_addr_ctrl_set(struct task_struct *target, const struct
 	int ret;
 	long ctrl;
 
+	ctrl = get_tagged_addr_ctrl(target);
+	if (WARN_ON_ONCE(IS_ERR_VALUE(ctrl)))
+		return ctrl;
+
 	ret = user_regset_copyin(&pos, &count, &kbuf, &ubuf, &ctrl, 0, -1);
 	if (ret)
 		return ret;
-- 
2.34.1
                    
                  
                  
                          
                            
                            2
                            
                          
                          
                            
                            1
                            
                          
                          
                            
    
                          
                        
                    
                        
                            
                                
                            
                            [openeuler:openEuler-1.0-LTS 1410/1410] arch/x86/entry/entry_64.o: warning: objtool: If this is a retpoline, please patch it in with alternatives and annotate it with ANNOTATE_NOSPEC_ALTERNATIVE.
                        
                        
by kernel test robot 22 Jan '25
                    by kernel test robot 22 Jan '25
22 Jan '25
                    
                        Hi Peter,
First bad commit (maybe != root cause):
tree:   https://gitee.com/openeuler/kernel.git openEuler-1.0-LTS
head:   4d48400e0254b5310842eb2ad33c6ccba43b0f1d
commit: 3acbac72baea337e0ac79801a8ba4b81e3b67014 [1410/1410] x86/speculation: Change FILL_RETURN_BUFFER to work with objtool
config: x86_64-randconfig-102-20250121 (https://download.01.org/0day-ci/archive/20250122/202501221629.J60ha3Fd-lkp@…)
compiler: gcc-12 (Debian 12.2.0-14) 12.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250122/202501221629.J60ha3Fd-lkp@…)
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(a)intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202501221629.J60ha3Fd-lkp@intel.com/
All warnings (new ones prefixed by >>):
>> arch/x86/entry/entry_64.o: warning: objtool: .entry.text+0x1e2: unsupported intra-function call
>> arch/x86/entry/entry_64.o: warning: objtool: If this is a retpoline, please patch it in with alternatives and annotate it with ANNOTATE_NOSPEC_ALTERNATIVE.
-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
                    
                  
                  
                          
                            
                            1
                            
                          
                          
                            
                            0
                            
                          
                          
                            
    
                          
                        
                    
                    
                        Namjae Jeon (2):
  ksmbd: fix slab-out-of-bounds in smb_strndup_from_utf16()
  ksmbd: fix potencial out-of-bounds when buffer offset is invalid
 fs/ksmbd/smb2misc.c | 26 +++++++++++++++++-------
 fs/ksmbd/smb2pdu.c  | 48 ++++++++++++++++++++++++---------------------
 2 files changed, 45 insertions(+), 29 deletions(-)
-- 
2.34.3
                    
                  
                  
                          
                            
                            2
                            
                          
                          
                            
                            3