lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <202506240921.WNcmLMhg-lkp@intel.com>
Date: Tue, 24 Jun 2025 09:36:25 +0800
From: kernel test robot <lkp@...el.com>
To: Sebastian Andrzej Siewior <bigeasy@...utronix.de>
Cc: llvm@...ts.linux.dev, oe-kbuild-all@...ts.linux.dev,
	linux-kernel@...r.kernel.org, Jakub Kicinski <kuba@...nel.org>,
	Toke Høiland-Jørgensen <toke@...hat.com>
Subject: net/bpf/test_run.c:370:12: warning: stack frame size (1152) exceeds
 limit (1024) in 'bpf_test_run_xdp_live'

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   78f4e737a53e1163ded2687a922fce138aee73f5
commit: 3f9fe37d9e16a6cfd5f4d1f536686ea71db3196f net: Move per-CPU flush-lists to bpf_net_context on PREEMPT_RT.
date:   12 months ago
config: powerpc-allyesconfig (https://download.01.org/0day-ci/archive/20250624/202506240921.WNcmLMhg-lkp@intel.com/config)
compiler: clang version 21.0.0git (https://github.com/llvm/llvm-project 875b36a8742437b95f623bab1e0332562c7b4b3f)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250624/202506240921.WNcmLMhg-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@...el.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202506240921.WNcmLMhg-lkp@intel.com/

All warnings (new ones prefixed by >>):

   include/linux/vmstat.h:514:36: warning: arithmetic between different enumeration types ('enum node_stat_item' and 'enum lru_list') [-Wenum-enum-conversion]
     514 |         return node_stat_name(NR_LRU_BASE + lru) + 3; // skip "nr_"
         |                               ~~~~~~~~~~~ ^ ~~~
   include/linux/vmstat.h:519:43: warning: arithmetic between different enumeration types ('enum zone_stat_item' and 'enum numa_stat_item') [-Wenum-enum-conversion]
     519 |         return vmstat_text[NR_VM_ZONE_STAT_ITEMS +
         |                            ~~~~~~~~~~~~~~~~~~~~~ ^
     520 |                            NR_VM_NUMA_EVENT_ITEMS +
         |                            ~~~~~~~~~~~~~~~~~~~~~~
   include/linux/vmstat.h:528:43: warning: arithmetic between different enumeration types ('enum zone_stat_item' and 'enum numa_stat_item') [-Wenum-enum-conversion]
     528 |         return vmstat_text[NR_VM_ZONE_STAT_ITEMS +
         |                            ~~~~~~~~~~~~~~~~~~~~~ ^
     529 |                            NR_VM_NUMA_EVENT_ITEMS +
         |                            ~~~~~~~~~~~~~~~~~~~~~~
   In file included from net/bpf/test_run.c:17:
   In file included from include/net/tcp.h:32:
   In file included from include/net/inet_hashtables.h:26:
   include/net/ip.h:472:14: warning: default initialization of an object of type 'typeof (rt->dst.expires)' (aka 'const unsigned long') leaves the object uninitialized [-Wdefault-const-init-var-unsafe]
     472 |                 if (mtu && time_before(jiffies, rt->dst.expires))
         |                            ^
   include/linux/jiffies.h:138:26: note: expanded from macro 'time_before'
     138 | #define time_before(a,b)        time_after(b,a)
         |                                 ^
   include/linux/jiffies.h:128:3: note: expanded from macro 'time_after'
     128 |         (typecheck(unsigned long, a) && \
         |          ^
   include/linux/typecheck.h:11:12: note: expanded from macro 'typecheck'
      11 |         typeof(x) __dummy2; \
         |                   ^
   net/bpf/test_run.c:451:26: warning: default initialization of an object of type 'typeof ((kattr->test.data_out))' (aka 'const unsigned long long') leaves the object uninitialized [-Wdefault-const-init-var-unsafe]
     451 |         void __user *data_out = u64_to_user_ptr(kattr->test.data_out);
         |                                 ^
   include/linux/kernel.h:52:2: note: expanded from macro 'u64_to_user_ptr'
      52 |         typecheck(u64, (x));            \
         |         ^
   include/linux/typecheck.h:11:12: note: expanded from macro 'typecheck'
      11 |         typeof(x) __dummy2; \
         |                   ^
   net/bpf/test_run.c:658:25: warning: default initialization of an object of type 'typeof ((kattr->test.data_in))' (aka 'const unsigned long long') leaves the object uninitialized [-Wdefault-const-init-var-unsafe]
     658 |         void __user *data_in = u64_to_user_ptr(kattr->test.data_in);
         |                                ^
   include/linux/kernel.h:52:2: note: expanded from macro 'u64_to_user_ptr'
      52 |         typecheck(u64, (x));            \
         |         ^
   include/linux/typecheck.h:11:12: note: expanded from macro 'typecheck'
      11 |         typeof(x) __dummy2; \
         |                   ^
   net/bpf/test_run.c:755:24: warning: default initialization of an object of type 'typeof ((kattr->test.ctx_in))' (aka 'const unsigned long long') leaves the object uninitialized [-Wdefault-const-init-var-unsafe]
     755 |         void __user *ctx_in = u64_to_user_ptr(kattr->test.ctx_in);
         |                               ^
   include/linux/kernel.h:52:2: note: expanded from macro 'u64_to_user_ptr'
      52 |         typecheck(u64, (x));            \
         |         ^
   include/linux/typecheck.h:11:12: note: expanded from macro 'typecheck'
      11 |         typeof(x) __dummy2; \
         |                   ^
   net/bpf/test_run.c:811:25: warning: default initialization of an object of type 'typeof ((kattr->test.ctx_in))' (aka 'const unsigned long long') leaves the object uninitialized [-Wdefault-const-init-var-unsafe]
     811 |         void __user *data_in = u64_to_user_ptr(kattr->test.ctx_in);
         |                                ^
   include/linux/kernel.h:52:2: note: expanded from macro 'u64_to_user_ptr'
      52 |         typecheck(u64, (x));            \
         |         ^
   include/linux/typecheck.h:11:12: note: expanded from macro 'typecheck'
      11 |         typeof(x) __dummy2; \
         |                   ^
   net/bpf/test_run.c:812:26: warning: default initialization of an object of type 'typeof ((kattr->test.ctx_out))' (aka 'const unsigned long long') leaves the object uninitialized [-Wdefault-const-init-var-unsafe]
     812 |         void __user *data_out = u64_to_user_ptr(kattr->test.ctx_out);
         |                                 ^
   include/linux/kernel.h:52:2: note: expanded from macro 'u64_to_user_ptr'
      52 |         typecheck(u64, (x));            \
         |         ^
   include/linux/typecheck.h:11:12: note: expanded from macro 'typecheck'
      11 |         typeof(x) __dummy2; \
         |                   ^
   net/bpf/test_run.c:844:26: warning: default initialization of an object of type 'typeof ((kattr->test.ctx_out))' (aka 'const unsigned long long') leaves the object uninitialized [-Wdefault-const-init-var-unsafe]
     844 |         void __user *data_out = u64_to_user_ptr(kattr->test.ctx_out);
         |                                 ^
   include/linux/kernel.h:52:2: note: expanded from macro 'u64_to_user_ptr'
      52 |         typecheck(u64, (x));            \
         |         ^
   include/linux/typecheck.h:11:12: note: expanded from macro 'typecheck'
      11 |         typeof(x) __dummy2; \
         |                   ^
   net/bpf/test_run.c:1251:26: warning: default initialization of an object of type 'typeof ((kattr->test.data_in))' (aka 'const unsigned long long') leaves the object uninitialized [-Wdefault-const-init-var-unsafe]
    1251 |                 void __user *data_in = u64_to_user_ptr(kattr->test.data_in);
         |                                        ^
   include/linux/kernel.h:52:2: note: expanded from macro 'u64_to_user_ptr'
      52 |         typecheck(u64, (x));            \
         |         ^
   include/linux/typecheck.h:11:12: note: expanded from macro 'typecheck'
      11 |         typeof(x) __dummy2; \
         |                   ^
   net/bpf/test_run.c:1508:24: warning: default initialization of an object of type 'typeof ((kattr->test.ctx_in))' (aka 'const unsigned long long') leaves the object uninitialized [-Wdefault-const-init-var-unsafe]
    1508 |         void __user *ctx_in = u64_to_user_ptr(kattr->test.ctx_in);
         |                               ^
   include/linux/kernel.h:52:2: note: expanded from macro 'u64_to_user_ptr'
      52 |         typecheck(u64, (x));            \
         |         ^
   include/linux/typecheck.h:11:12: note: expanded from macro 'typecheck'
      11 |         typeof(x) __dummy2; \
         |                   ^
>> net/bpf/test_run.c:370:12: warning: stack frame size (1152) exceeds limit (1024) in 'bpf_test_run_xdp_live' [-Wframe-larger-than]
     370 | static int bpf_test_run_xdp_live(struct bpf_prog *prog, struct xdp_buff *ctx,
         |            ^
   15 warnings generated.


vim +/bpf_test_run_xdp_live +370 net/bpf/test_run.c

b530e9e1063ed2 Toke Høiland-Jørgensen 2022-03-09  369  
b530e9e1063ed2 Toke Høiland-Jørgensen 2022-03-09 @370  static int bpf_test_run_xdp_live(struct bpf_prog *prog, struct xdp_buff *ctx,
b530e9e1063ed2 Toke Høiland-Jørgensen 2022-03-09  371  				 u32 repeat, u32 batch_size, u32 *time)
b530e9e1063ed2 Toke Høiland-Jørgensen 2022-03-09  372  

:::::: The code at line 370 was first introduced by commit
:::::: b530e9e1063ed2b817eae7eec6ed2daa8be11608 bpf: Add "live packet" mode for XDP in BPF_PROG_RUN

:::::: TO: Toke Høiland-Jørgensen <toke@...hat.com>
:::::: CC: Alexei Starovoitov <ast@...nel.org>

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

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ