Building the Linux kernel with Clang and LLVM
 help / color / mirror / Atom feed
* [davidhildenbrand:nr_cpus 1/1] include/linux/threads.h:16:2: error: "CONFIG_NR_CPUS not defined"
@ 2024-09-24 16:49 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2024-09-24 16:49 UTC (permalink / raw)
  To: David Hildenbrand; +Cc: llvm, oe-kbuild-all

tree:   https://github.com/davidhildenbrand/linux nr_cpus
head:   06e0fc4651a486ac1ce333cccc89b394222431c8
commit: 06e0fc4651a486ac1ce333cccc89b394222431c8 [1/1] fixup
config: um-allnoconfig (https://download.01.org/0day-ci/archive/20240925/202409250044.OFQyPQyO-lkp@intel.com/config)
compiler: 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/20240925/202409250044.OFQyPQyO-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/202409250044.OFQyPQyO-lkp@intel.com/

All errors (new ones prefixed by >>):

   In file included from arch/um/os-Linux/skas/process.c:25:
>> include/linux/threads.h:16:2: error: "CONFIG_NR_CPUS not defined"
      16 | #error "CONFIG_NR_CPUS not defined"
         |  ^
>> arch/um/os-Linux/skas/process.c:256:19: error: use of undeclared identifier 'CONFIG_NR_CPUS'
     256 | int userspace_pid[NR_CPUS];
         |                   ^
   include/linux/threads.h:20:18: note: expanded from macro 'NR_CPUS'
      20 | #define NR_CPUS         CONFIG_NR_CPUS
         |                         ^
   2 errors generated.


vim +16 include/linux/threads.h

     4	
     5	
     6	/*
     7	 * The default limit for the nr of threads is now in
     8	 * /proc/sys/kernel/threads-max.
     9	 */
    10	
    11	/*
    12	 * Maximum supported processors.  Setting this smaller saves quite a
    13	 * bit of memory.  Use nr_cpu_ids instead of this except for static bitmaps.
    14	 */
    15	#ifndef CONFIG_NR_CPUS
  > 16	#error "CONFIG_NR_CPUS not defined"
    17	#endif
    18	

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

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2024-09-24 16:50 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-09-24 16:49 [davidhildenbrand:nr_cpus 1/1] include/linux/threads.h:16:2: error: "CONFIG_NR_CPUS not defined" kernel test robot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox