[mingo-tip:master 2130/2300] drivers/net/fddi/defza.c:104:16: warning: returning 'int' from a function with return type 'struct sk_buff *' makes pointer from integer without a cast
From: kernel test robot
Date: Sat Jan 08 2022 - 12:02:05 EST
tree: git://git.kernel.org/pub/scm/linux/kernel/git/mingo/tip.git master
head: 4e348e961395297bb17f101cc63bc133d8a348e9
commit: 849a5d0b76b20f2ffe001b8c745fe15441b98bc7 [2130/2300] headers/deps: net: Optimize <linux/netdevice_api.h> dependencies, remove various headers
config: mips-decstation_defconfig (https://download.01.org/0day-ci/archive/20220109/202201090043.nAZcpAke-lkp@xxxxxxxxx/config)
compiler: mipsel-linux-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/mingo/tip.git/commit/?id=849a5d0b76b20f2ffe001b8c745fe15441b98bc7
git remote add mingo-tip git://git.kernel.org/pub/scm/linux/kernel/git/mingo/tip.git
git fetch --no-tags mingo-tip master
git checkout 849a5d0b76b20f2ffe001b8c745fe15441b98bc7
# 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=mips SHELL=/bin/bash arch/mips/dec/ drivers/net/fddi/ drivers/video/fbdev/
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/fddi/defza.c: In function 'fza_alloc_skb_irq':
drivers/net/fddi/defza.c:104:16: error: implicit declaration of function '__netdev_alloc_skb' [-Werror=implicit-function-declaration]
104 | return __netdev_alloc_skb(dev, length, GFP_ATOMIC);
| ^~~~~~~~~~~~~~~~~~
>> drivers/net/fddi/defza.c:104:16: warning: returning 'int' from a function with return type 'struct sk_buff *' makes pointer from integer without a cast [-Wint-conversion]
104 | return __netdev_alloc_skb(dev, length, GFP_ATOMIC);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/fddi/defza.c: In function 'fza_alloc_skb':
drivers/net/fddi/defza.c:110:16: warning: returning 'int' from a function with return type 'struct sk_buff *' makes pointer from integer without a cast [-Wint-conversion]
110 | return __netdev_alloc_skb(dev, length, GFP_KERNEL);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/fddi/defza.c: In function 'fza_skb_align':
drivers/net/fddi/defza.c:120:9: error: implicit declaration of function 'skb_reserve' [-Werror=implicit-function-declaration]
120 | skb_reserve(skb, y - x);
| ^~~~~~~~~~~
drivers/net/fddi/defza.c: In function 'fza_rx':
drivers/net/fddi/defza.c:757:25: error: implicit declaration of function 'skb_put' [-Werror=implicit-function-declaration]
757 | skb_put(skb, pkt_len); /* And cut off FCS. */
| ^~~~~~~
drivers/net/fddi/defza.c: In function 'fza_tx_smt':
drivers/net/fddi/defza.c:827:33: error: implicit declaration of function 'skb_reset_network_header'; did you mean 'skb_inner_network_header'? [-Werror=implicit-function-declaration]
827 | skb_reset_network_header(skb);
| ^~~~~~~~~~~~~~~~~~~~~~~~
| skb_inner_network_header
drivers/net/fddi/defza.c: In function 'fza_start_xmit':
drivers/net/fddi/defza.c:1091:9: error: implicit declaration of function 'skb_push' [-Werror=implicit-function-declaration]
1091 | skb_push(skb, 3); /* Make room for PRH. */
| ^~~~~~~~
drivers/net/fddi/defza.c:1148:9: error: implicit declaration of function 'dev_kfree_skb'; did you mean 'dev_kfree_skb_any'? [-Werror=implicit-function-declaration]
1148 | dev_kfree_skb(skb);
| ^~~~~~~~~~~~~
| dev_kfree_skb_any
cc1: some warnings being treated as errors
vim +104 drivers/net/fddi/defza.c
61414f5ec9834d Maciej W. Rozycki 2018-10-09 100
61414f5ec9834d Maciej W. Rozycki 2018-10-09 101 static inline struct sk_buff *fza_alloc_skb_irq(struct net_device *dev,
61414f5ec9834d Maciej W. Rozycki 2018-10-09 102 unsigned int length)
61414f5ec9834d Maciej W. Rozycki 2018-10-09 103 {
61414f5ec9834d Maciej W. Rozycki 2018-10-09 @104 return __netdev_alloc_skb(dev, length, GFP_ATOMIC);
61414f5ec9834d Maciej W. Rozycki 2018-10-09 105 }
61414f5ec9834d Maciej W. Rozycki 2018-10-09 106
:::::: The code at line 104 was first introduced by commit
:::::: 61414f5ec9834df8aa4f55c90de16b71a3d6ca8d FDDI: defza: Add support for DEC FDDIcontroller 700 TURBOchannel adapter
:::::: TO: Maciej W. Rozycki <macro@xxxxxxxxxxxxxx>
:::::: CC: David S. Miller <davem@xxxxxxxxxxxxx>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx