public inbox for llvm@lists.linux.dev
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Jason Xing <kernelxing@tencent.com>
Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev,
	0day robot <lkp@intel.com>
Subject: net/core/dev.c:4896:5: warning: no previous prototype for function 'xsk_direct_xmit_batch'
Date: Sun, 19 Apr 2026 13:53:57 +0200	[thread overview]
Message-ID: <202604191309.zcfqiXcM-lkp@intel.com> (raw)

tree:   https://github.com/intel-lab-lkp/linux/commits/Jason-Xing/xsk-introduce-XDP_GENERIC_XMIT_BATCH-setsockopt/20260419-142943
head:   4b82e4780ff9a121b25fbf30a8f9e6fcb9b0eb04
commit: f15c37d19d6d8ef60bfc87a982a5374e83994ac2 xsk: add direct xmit in batch function
date:   5 hours ago
config: x86_64-kexec (https://download.01.org/0day-ci/archive/20260419/202604191309.zcfqiXcM-lkp@intel.com/config)
compiler: clang version 20.1.8 (https://github.com/llvm/llvm-project 87f0227cb60147a26a1eeb4fb06e3b505e9c7261)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260419/202604191309.zcfqiXcM-lkp@intel.com/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@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202604191309.zcfqiXcM-lkp@intel.com/

All warnings (new ones prefixed by >>):

>> net/core/dev.c:4896:5: warning: no previous prototype for function 'xsk_direct_xmit_batch' [-Wmissing-prototypes]
    4896 | int xsk_direct_xmit_batch(struct xdp_sock *xs, struct net_device *dev)
         |     ^
   net/core/dev.c:4896:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
    4896 | int xsk_direct_xmit_batch(struct xdp_sock *xs, struct net_device *dev)
         | ^
         | static 
   1 warning generated.


vim +/xsk_direct_xmit_batch +4896 net/core/dev.c

  4895	
> 4896	int xsk_direct_xmit_batch(struct xdp_sock *xs, struct net_device *dev)
  4897	{
  4898		u16 queue_id = xs->queue_id;
  4899		struct netdev_queue *txq = netdev_get_tx_queue(dev, queue_id);
  4900		struct sk_buff_head *send_queue = &xs->batch.send_queue;
  4901		int ret = NETDEV_TX_BUSY;
  4902		struct sk_buff *skb;
  4903	
  4904		local_bh_disable();
  4905		HARD_TX_LOCK(dev, txq, smp_processor_id());
  4906		while ((skb = __skb_dequeue(send_queue)) != NULL) {
  4907			struct sk_buff *orig_skb = skb;
  4908			bool again = false;
  4909	
  4910			skb = validate_xmit_skb_list(skb, dev, &again);
  4911			if (skb != orig_skb) {
  4912				dev_core_stats_tx_dropped_inc(dev);
  4913				kfree_skb_list(skb);
  4914				ret = NET_XMIT_DROP;
  4915				break;
  4916			}
  4917	
  4918			if (netif_xmit_frozen_or_drv_stopped(txq)) {
  4919				__skb_queue_head(send_queue, skb);
  4920				break;
  4921			}
  4922			skb_set_queue_mapping(skb, queue_id);
  4923			ret = netdev_start_xmit(skb, dev, txq, false);
  4924			if (ret != NETDEV_TX_OK) {
  4925				if (ret == NETDEV_TX_BUSY)
  4926					__skb_queue_head(send_queue, skb);
  4927				break;
  4928			}
  4929		}
  4930		HARD_TX_UNLOCK(dev, txq);
  4931		local_bh_enable();
  4932	
  4933		return ret;
  4934	}
  4935	

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

                 reply	other threads:[~2026-04-19 11:54 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=202604191309.zcfqiXcM-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=kernelxing@tencent.com \
    --cc=llvm@lists.linux.dev \
    --cc=oe-kbuild-all@lists.linux.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox