[jimc:scratchpad-v10 15/24] kernel/locking/lockdep.c:265:64: error: macro "SCRATCHREC_INIT" passed 5 arguments, but takes just 4

kernel test robot <[email protected]>
Newsgroups dev.linux.lists.oe-kbuild-all
Message-ID <[email protected]>
tree:   https://github.com/jimc/linux.git scratchpad-v10
head:   a23fc077806416450fbeb0a5a534fd995e465430
commit: 468ef4eda872252a66884b59339c1331ded8a0fc [15/24] locking/lockdep: Back lock_classes chunk array with dynamic scratchrec pool
config: x86_64-randconfig-006-20260822 (https://download.01.org/0day-ci/archive/20260823/[email protected]/config)
compiler: gcc-12 (Debian 12.4.0-5) 12.4.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260823/[email protected]/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 <[email protected]>
| Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/

Note: the jimc/scratchpad-v10 HEAD a23fc077806416450fbeb0a5a534fd995e465430 builds fine.
      It only hurts bisectability.

All errors (new ones prefixed by >>):

   kernel/locking/lockdep.c:71:71: error: macro "SCRATCHREC_INIT_STATIC" passed 7 arguments, but takes just 6
      71 |                                SCRATCH_64K_ORDER, 0, &lockdep_pool_key);
         |                                                                       ^
   In file included from kernel/locking/lockdep.c:61:
   include/linux/scratchpad.h:360: note: macro "SCRATCHREC_INIT_STATIC" defined here
     360 | #define SCRATCHREC_INIT_STATIC(name, _elem_size, _static_buf, _size_bytes, _min_order, _key) \
         | 
   kernel/locking/lockdep.c:69:9: error: 'SCRATCHREC_INIT_STATIC' undeclared here (not in a function)
      69 |         SCRATCHREC_INIT_STATIC(lockdep_pool, sizeof(struct lock_list),
         |         ^~~~~~~~~~~~~~~~~~~~~~
>> kernel/locking/lockdep.c:265:64: error: macro "SCRATCHREC_INIT" passed 5 arguments, but takes just 4
     265 |                         SCRATCH_64K_ORDER, 0, &lockdep_pool_key);
         |                                                                ^
   include/linux/scratchpad.h:357: note: macro "SCRATCHREC_INIT" defined here
     357 | #define SCRATCHREC_INIT(name, _elem_size, _min_order, _key) \
         | 
>> kernel/locking/lockdep.c:263:9: error: 'SCRATCHREC_INIT' undeclared here (not in a function)
     263 |         SCRATCHREC_INIT(lockdep_class_pool,
         |         ^~~~~~~~~~~~~~~
   kernel/locking/lockdep.c:608:49: error: macro "SCRATCHPAD_INIT_STATIC" passed 6 arguments, but takes just 5
     608 |                                &lockdep_pool_key);
         |                                                 ^
   include/linux/scratchpad.h:153: note: macro "SCRATCHPAD_INIT_STATIC" defined here
     153 | #define SCRATCHPAD_INIT_STATIC(name, _static_buf, _size_bytes, _min_order, _key) \
         | 
   kernel/locking/lockdep.c:605:9: error: 'SCRATCHPAD_INIT_STATIC' undeclared here (not in a function)
     605 |         SCRATCHPAD_INIT_STATIC(lockdep_trace_scratchpad,
         |         ^~~~~~~~~~~~~~~~~~~~~~


vim +/SCRATCHREC_INIT +265 kernel/locking/lockdep.c

   261	
   262	static struct scratchrec lockdep_class_pool =
 > 263		SCRATCHREC_INIT(lockdep_class_pool,
   264				sizeof(struct lock_class) * LOCK_CLASSES_PER_CHUNK,
 > 265				SCRATCH_64K_ORDER, 0, &lockdep_pool_key);
   266	

--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.