Re: [PATCH net-next v3 23/27] virtio_net: xsk: rx: support recv merge mode

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

 



Hi Xuan,

kernel test robot noticed the following build warnings:

[auto build test WARNING on mst-vhost/linux-next]
[cannot apply to net-next/main linus/master horms-ipvs/master v6.7-rc7 next-20231222]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]

url:    https://github.com/intel-lab-lkp/linux/commits/Xuan-Zhuo/virtio_net-rename-free_old_xmit_skbs-to-free_old_xmit/20231229-155253
base:   https://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost.git linux-next
patch link:    https://lore.kernel.org/r/20231229073108.57778-24-xuanzhuo%40linux.alibaba.com
patch subject: [PATCH net-next v3 23/27] virtio_net: xsk: rx: support recv merge mode
config: x86_64-rhel-8.3-rust (https://download.01.org/0day-ci/archive/20231230/202312300404.1R72Ssbh-lkp@xxxxxxxxx/config)
compiler: ClangBuiltLinux clang version 17.0.6 (https://github.com/llvm/llvm-project 6009708b4367171ccdbf4b5905cb6a803753fe18)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20231230/202312300404.1R72Ssbh-lkp@xxxxxxxxx/reproduce)

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@xxxxxxxxx>
| Closes: https://lore.kernel.org/oe-kbuild-all/202312300404.1R72Ssbh-lkp@xxxxxxxxx/

All warnings (new ones prefixed by >>):

>> drivers/net/virtio/xsk.c:216:17: warning: variable 'xdp' is uninitialized when used here [-Wuninitialized]
     216 |                 xsk_buff_free(xdp);
         |                               ^~~
   drivers/net/virtio/xsk.c:210:22: note: initialize the variable 'xdp' to silence this warning
     210 |         struct xdp_buff *xdp;
         |                             ^
         |                              = NULL
   1 warning generated.


vim +/xdp +216 drivers/net/virtio/xsk.c

   202	
   203	struct sk_buff *virtnet_receive_xsk_buf(struct virtnet_info *vi, struct virtnet_rq *rq,
   204						void *buf, u32 len,
   205						unsigned int *xdp_xmit,
   206						struct virtnet_rq_stats *stats)
   207	{
   208		struct net_device *dev = vi->dev;
   209		struct sk_buff *skb = NULL;
   210		struct xdp_buff *xdp;
   211	
   212		if (unlikely(len < vi->hdr_len + ETH_HLEN)) {
   213			pr_debug("%s: short packet %i\n", dev->name, len);
   214			DEV_STATS_INC(dev, rx_length_errors);
   215	
 > 216			xsk_buff_free(xdp);
   217			return NULL;
   218		}
   219	
   220		len -= vi->hdr_len;
   221	
   222		u64_stats_add(&stats->bytes, len);
   223	
   224		xdp = buf_to_xdp(vi, rq, buf, len);
   225		if (!xdp)
   226			return NULL;
   227	
   228		if (vi->mergeable_rx_bufs)
   229			skb = virtnet_receive_xsk_merge(dev, vi, rq, xdp, xdp_xmit, stats);
   230	
   231		return skb;
   232	}
   233	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki




[Index of Archives]     [KVM Development]     [Libvirt Development]     [Libvirt Users]     [CentOS Virtualization]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux