Re: [PATCH net 2/2] xsk: Fix zero-copy AF_XDP fragment drop
From: kernel test robot <hidden>
Date: 2026-02-05 09:29:03
Also in:
oe-kbuild-all
Hi Nikhil, kernel test robot noticed the following build warnings: [auto build test WARNING on net/main] url: https://github.com/intel-lab-lkp/linux/commits/Nikhil-P-Rao/xsk-Fix-fragment-node-deletion-to-prevent-buffer-leak/20260205-082128 base: net/main patch link: https://lore.kernel.org/r/20260205001935.11562-3-nikhil.rao%40amd.com patch subject: [PATCH net 2/2] xsk: Fix zero-copy AF_XDP fragment drop config: xtensa-randconfig-r072-20260205 (https://download.01.org/0day-ci/archive/20260205/202602051720.YfZO23pZ-lkp@intel.com/config) compiler: xtensa-linux-gcc (GCC) 8.5.0 smatch version: v0.5.0-8994-gd50c5a4c 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 [off-list ref] | Closes: https://lore.kernel.org/oe-kbuild-all/202602051720.YfZO23pZ-lkp@intel.com/ (local) New smatch warnings: net/xdp/xsk.c:191 xsk_rcv_zc() warn: inconsistent indenting Old smatch warnings: arch/xtensa/include/asm/thread_info.h:97 current_thread_info() warn: inconsistent indenting vim +191 net/xdp/xsk.c 162 163 static int xsk_rcv_zc(struct xdp_sock *xs, struct xdp_buff *xdp, u32 len) 164 { 165 struct xdp_buff_xsk *xskb = container_of(xdp, struct xdp_buff_xsk, xdp); 166 u32 frags = xdp_buff_has_frags(xdp); 167 struct xdp_buff_xsk *pos, *tmp; 168 struct list_head *xskb_list; 169 u32 num_desc = 1; 170 u32 contd = 0; 171 172 if (frags) { 173 num_desc = xdp_get_shared_info_from_buff(xdp)->nr_frags + 1; 174 contd = XDP_PKT_CONTD; 175 } 176 177 if (xskq_prod_nb_free(xs->rx, num_desc) < num_desc) { 178 xs->rx_queue_full++; 179 return -ENOBUFS; 180 } 181 182 __xsk_rcv_zc(xs, xskb, len, contd); 183 if (likely(!frags)) 184 return 0; 185 186 xskb_list = &xskb->pool->xskb_list; 187 list_for_each_entry_safe(pos, tmp, xskb_list, list_node) { 188 if (list_is_singular(xskb_list)) 189 contd = 0; 190 len = pos->xdp.data_end - pos->xdp.data; > 191 __xsk_rcv_zc(xs, pos, len, contd); 192 list_del_init(&pos->list_node); 193 } 194 195 return 0; 196 } 197 -- 0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki