[linux-next:master 8458/11353] drivers/net/ethernet/fungible/funeth/funeth_tx.c:311:21: warning: assignment to 'struct sk_buff *' from 'int' makes pointer from integer without a cast

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



tree:   https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head:   cb153b68ff91cbc434f3de70ac549e110543e1bb
commit: 749efb1e6d73f528598b13302864227b77810da5 [8458/11353] net/fungible: Kconfig, Makefiles, and MAINTAINERS
config: arc-randconfig-r033-20220307 (https://download.01.org/0day-ci/archive/20220308/202203082156.eFa2lTLH-lkp@xxxxxxxxx/config)
compiler: arc-elf-gcc (GCC) 11.2.0
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/?id=749efb1e6d73f528598b13302864227b77810da5
        git remote add linux-next https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
        git fetch --no-tags linux-next master
        git checkout 749efb1e6d73f528598b13302864227b77810da5
        # save the config file to linux build tree
        mkdir build_dir
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=arc SHELL=/bin/bash drivers/net/ethernet/fungible/funeth/

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@xxxxxxxxx>

All warnings (new ones prefixed by >>):

   drivers/net/ethernet/fungible/funeth/funeth_tx.c: In function 'write_pkt_desc':
   drivers/net/ethernet/fungible/funeth/funeth_tx.c:244:27: error: implicit declaration of function 'tls_driver_ctx' [-Werror=implicit-function-declaration]
     244 |                 tls_ctx = tls_driver_ctx(skb->sk, TLS_OFFLOAD_CTX_DIR_TX);
         |                           ^~~~~~~~~~~~~~
   drivers/net/ethernet/fungible/funeth/funeth_tx.c:244:51: error: 'TLS_OFFLOAD_CTX_DIR_TX' undeclared (first use in this function)
     244 |                 tls_ctx = tls_driver_ctx(skb->sk, TLS_OFFLOAD_CTX_DIR_TX);
         |                                                   ^~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/fungible/funeth/funeth_tx.c:244:51: note: each undeclared identifier is reported only once for each function it appears in
   drivers/net/ethernet/fungible/funeth/funeth_tx.c:245:37: error: invalid use of undefined type 'struct fun_ktls_tx_ctx'
     245 |                 tls->tlsid = tls_ctx->tlsid;
         |                                     ^~
   drivers/net/ethernet/fungible/funeth/funeth_tx.c:246:24: error: invalid use of undefined type 'struct fun_ktls_tx_ctx'
     246 |                 tls_ctx->next_seq += tls_len;
         |                        ^~
   drivers/net/ethernet/fungible/funeth/funeth_tx.c: In function 'fun_start_xmit':
   drivers/net/ethernet/fungible/funeth/funeth_tx.c:310:13: error: implicit declaration of function 'tls_is_sk_tx_device_offloaded' [-Werror=implicit-function-declaration]
     310 |             tls_is_sk_tx_device_offloaded(skb->sk)) {
         |             ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/net/ethernet/fungible/funeth/funeth_tx.c:311:23: error: implicit declaration of function 'fun_tls_tx'; did you mean 'fun_xdp_tx'? [-Werror=implicit-function-declaration]
     311 |                 skb = fun_tls_tx(skb, q, &tls_len);
         |                       ^~~~~~~~~~
         |                       fun_xdp_tx
>> drivers/net/ethernet/fungible/funeth/funeth_tx.c:311:21: warning: assignment to 'struct sk_buff *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
     311 |                 skb = fun_tls_tx(skb, q, &tls_len);
         |                     ^
   cc1: some warnings being treated as errors


vim +311 drivers/net/ethernet/fungible/funeth/funeth_tx.c

db37bc177dae89 Dimitris Michailidis 2022-02-24  300  
db37bc177dae89 Dimitris Michailidis 2022-02-24  301  netdev_tx_t fun_start_xmit(struct sk_buff *skb, struct net_device *netdev)
db37bc177dae89 Dimitris Michailidis 2022-02-24  302  {
db37bc177dae89 Dimitris Michailidis 2022-02-24  303  	struct funeth_priv *fp = netdev_priv(netdev);
db37bc177dae89 Dimitris Michailidis 2022-02-24  304  	unsigned int qid = skb_get_queue_mapping(skb);
db37bc177dae89 Dimitris Michailidis 2022-02-24  305  	struct funeth_txq *q = fp->txqs[qid];
db37bc177dae89 Dimitris Michailidis 2022-02-24  306  	unsigned int tls_len = 0;
db37bc177dae89 Dimitris Michailidis 2022-02-24  307  	unsigned int ndesc;
db37bc177dae89 Dimitris Michailidis 2022-02-24  308  
db37bc177dae89 Dimitris Michailidis 2022-02-24  309  	if (IS_ENABLED(CONFIG_TLS_DEVICE) && skb->sk &&
db37bc177dae89 Dimitris Michailidis 2022-02-24  310  	    tls_is_sk_tx_device_offloaded(skb->sk)) {
db37bc177dae89 Dimitris Michailidis 2022-02-24 @311  		skb = fun_tls_tx(skb, q, &tls_len);
db37bc177dae89 Dimitris Michailidis 2022-02-24  312  		if (unlikely(!skb))
db37bc177dae89 Dimitris Michailidis 2022-02-24  313  			goto dropped;
db37bc177dae89 Dimitris Michailidis 2022-02-24  314  	}
db37bc177dae89 Dimitris Michailidis 2022-02-24  315  
db37bc177dae89 Dimitris Michailidis 2022-02-24  316  	ndesc = write_pkt_desc(skb, q, tls_len);
db37bc177dae89 Dimitris Michailidis 2022-02-24  317  	if (unlikely(!ndesc)) {
db37bc177dae89 Dimitris Michailidis 2022-02-24  318  		dev_kfree_skb_any(skb);
db37bc177dae89 Dimitris Michailidis 2022-02-24  319  		goto dropped;
db37bc177dae89 Dimitris Michailidis 2022-02-24  320  	}
db37bc177dae89 Dimitris Michailidis 2022-02-24  321  
db37bc177dae89 Dimitris Michailidis 2022-02-24  322  	q->prod_cnt += ndesc;
db37bc177dae89 Dimitris Michailidis 2022-02-24  323  	fun_tx_check_stop(q);
db37bc177dae89 Dimitris Michailidis 2022-02-24  324  
db37bc177dae89 Dimitris Michailidis 2022-02-24  325  	skb_tx_timestamp(skb);
db37bc177dae89 Dimitris Michailidis 2022-02-24  326  
db37bc177dae89 Dimitris Michailidis 2022-02-24  327  	if (__netdev_tx_sent_queue(q->ndq, skb->len, netdev_xmit_more()))
db37bc177dae89 Dimitris Michailidis 2022-02-24  328  		fun_txq_wr_db(q);
db37bc177dae89 Dimitris Michailidis 2022-02-24  329  	else
db37bc177dae89 Dimitris Michailidis 2022-02-24  330  		FUN_QSTAT_INC(q, tx_more);
db37bc177dae89 Dimitris Michailidis 2022-02-24  331  
db37bc177dae89 Dimitris Michailidis 2022-02-24  332  	return NETDEV_TX_OK;
db37bc177dae89 Dimitris Michailidis 2022-02-24  333  
db37bc177dae89 Dimitris Michailidis 2022-02-24  334  dropped:
db37bc177dae89 Dimitris Michailidis 2022-02-24  335  	/* A dropped packet may be the last one in a xmit_more train,
db37bc177dae89 Dimitris Michailidis 2022-02-24  336  	 * ring the doorbell just in case.
db37bc177dae89 Dimitris Michailidis 2022-02-24  337  	 */
db37bc177dae89 Dimitris Michailidis 2022-02-24  338  	if (!netdev_xmit_more())
db37bc177dae89 Dimitris Michailidis 2022-02-24  339  		fun_txq_wr_db(q);
db37bc177dae89 Dimitris Michailidis 2022-02-24  340  	return NETDEV_TX_OK;
db37bc177dae89 Dimitris Michailidis 2022-02-24  341  }
db37bc177dae89 Dimitris Michailidis 2022-02-24  342  

:::::: The code at line 311 was first introduced by commit
:::::: db37bc177dae89cef6fc37bdbe6b223929f70245 net/funeth: add the data path

:::::: TO: Dimitris Michailidis <d.michailidis@xxxxxxxxxxxx>
:::::: CC: David S. Miller <davem@xxxxxxxxxxxxx>

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux