All of lore.kernel.org
 help / color / mirror / Atom feed
* [broonie-misc:for-kernelci 6/13] include/linux/pgtable.h:237:2: error: call to undeclared function 'arch_enter_lazy_mmu_mode'; ISO C99 and later do not support implicit function declarations
@ 2025-10-15  0:58 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2025-10-15  0:58 UTC (permalink / raw)
  To: Kevin Brodsky; +Cc: llvm, oe-kbuild-all

Hi Kevin,

FYI, the error/warning was bisected to this commit, please ignore it if it's irrelevant.

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/misc.git for-kernelci
head:   cde5afc166019bb0b077b88d78b3706ede96628a
commit: 3763e0f7bacf2669411cf2e580ca62e64eafb813 [6/13] mm: introduce generic lazy_mmu helpers
config: x86_64-allyesconfig (https://download.01.org/0day-ci/archive/20251015/202510150845.bOLBMSFb-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/20251015/202510150845.bOLBMSFb-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/202510150845.bOLBMSFb-lkp@intel.com/

All errors (new ones prefixed by >>):

   In file included from arch/x86/boot/startup/sme.c:38:
   In file included from include/linux/mm.h:31:
>> include/linux/pgtable.h:237:2: error: call to undeclared function 'arch_enter_lazy_mmu_mode'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
     237 |         arch_enter_lazy_mmu_mode();
         |         ^
>> include/linux/pgtable.h:242:2: error: call to undeclared function 'arch_leave_lazy_mmu_mode'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
     242 |         arch_leave_lazy_mmu_mode();
         |         ^
   include/linux/pgtable.h:247:2: error: call to undeclared function 'arch_leave_lazy_mmu_mode'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
     247 |         arch_leave_lazy_mmu_mode();
         |         ^
   include/linux/pgtable.h:252:2: error: call to undeclared function 'arch_enter_lazy_mmu_mode'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
     252 |         arch_enter_lazy_mmu_mode();
         |         ^
   In file included from arch/x86/boot/startup/sme.c:38:
   In file included from include/linux/mm.h:36:
   In file included from include/linux/rcuwait.h:6:
   In file included from include/linux/sched/signal.h:6:
   include/linux/signal.h:98:11: warning: array index 3 is past the end of the array (that has type 'unsigned long[1]') [-Warray-bounds]
      98 |                 return (set->sig[3] | set->sig[2] |
         |                         ^        ~
   arch/x86/include/asm/signal.h:24:2: note: array 'sig' declared here
      24 |         unsigned long sig[_NSIG_WORDS];
         |         ^
   In file included from arch/x86/boot/startup/sme.c:38:
   In file included from include/linux/mm.h:36:
   In file included from include/linux/rcuwait.h:6:
   In file included from include/linux/sched/signal.h:6:
   include/linux/signal.h:98:25: warning: array index 2 is past the end of the array (that has type 'unsigned long[1]') [-Warray-bounds]
      98 |                 return (set->sig[3] | set->sig[2] |
         |                                       ^        ~
   arch/x86/include/asm/signal.h:24:2: note: array 'sig' declared here
      24 |         unsigned long sig[_NSIG_WORDS];
         |         ^
   In file included from arch/x86/boot/startup/sme.c:38:
   In file included from include/linux/mm.h:36:
   In file included from include/linux/rcuwait.h:6:
   In file included from include/linux/sched/signal.h:6:
   include/linux/signal.h:99:4: warning: array index 1 is past the end of the array (that has type 'unsigned long[1]') [-Warray-bounds]
      99 |                         set->sig[1] | set->sig[0]) == 0;
         |                         ^        ~
   arch/x86/include/asm/signal.h:24:2: note: array 'sig' declared here
      24 |         unsigned long sig[_NSIG_WORDS];
         |         ^
   In file included from arch/x86/boot/startup/sme.c:38:
   In file included from include/linux/mm.h:36:
   In file included from include/linux/rcuwait.h:6:
   In file included from include/linux/sched/signal.h:6:
   include/linux/signal.h:101:11: warning: array index 1 is past the end of the array (that has type 'unsigned long[1]') [-Warray-bounds]
     101 |                 return (set->sig[1] | set->sig[0]) == 0;
         |                         ^        ~
   arch/x86/include/asm/signal.h:24:2: note: array 'sig' declared here
      24 |         unsigned long sig[_NSIG_WORDS];
         |         ^
   In file included from arch/x86/boot/startup/sme.c:38:
   In file included from include/linux/mm.h:36:
   In file included from include/linux/rcuwait.h:6:
   In file included from include/linux/sched/signal.h:6:
   include/linux/signal.h:114:11: warning: array index 3 is past the end of the array (that has type 'const unsigned long[1]') [-Warray-bounds]
     114 |                 return  (set1->sig[3] == set2->sig[3]) &&
         |                          ^         ~
   arch/x86/include/asm/signal.h:24:2: note: array 'sig' declared here
      24 |         unsigned long sig[_NSIG_WORDS];
         |         ^
   In file included from arch/x86/boot/startup/sme.c:38:
   In file included from include/linux/mm.h:36:
   In file included from include/linux/rcuwait.h:6:
   In file included from include/linux/sched/signal.h:6:
   include/linux/signal.h:114:27: warning: array index 3 is past the end of the array (that has type 'const unsigned long[1]') [-Warray-bounds]
     114 |                 return  (set1->sig[3] == set2->sig[3]) &&
         |                                          ^         ~
   arch/x86/include/asm/signal.h:24:2: note: array 'sig' declared here
      24 |         unsigned long sig[_NSIG_WORDS];
         |         ^
   In file included from arch/x86/boot/startup/sme.c:38:
   In file included from include/linux/mm.h:36:
   In file included from include/linux/rcuwait.h:6:
   In file included from include/linux/sched/signal.h:6:
   include/linux/signal.h:115:5: warning: array index 2 is past the end of the array (that has type 'const unsigned long[1]') [-Warray-bounds]
     115 |                         (set1->sig[2] == set2->sig[2]) &&
         |                          ^         ~
   arch/x86/include/asm/signal.h:24:2: note: array 'sig' declared here
      24 |         unsigned long sig[_NSIG_WORDS];
         |         ^
   In file included from arch/x86/boot/startup/sme.c:38:
   In file included from include/linux/mm.h:36:
   In file included from include/linux/rcuwait.h:6:
   In file included from include/linux/sched/signal.h:6:
   include/linux/signal.h:115:21: warning: array index 2 is past the end of the array (that has type 'const unsigned long[1]') [-Warray-bounds]
     115 |                         (set1->sig[2] == set2->sig[2]) &&
         |                                          ^         ~
   arch/x86/include/asm/signal.h:24:2: note: array 'sig' declared here
      24 |         unsigned long sig[_NSIG_WORDS];
         |         ^
   In file included from arch/x86/boot/startup/sme.c:38:
   In file included from include/linux/mm.h:36:
   In file included from include/linux/rcuwait.h:6:
   In file included from include/linux/sched/signal.h:6:
   include/linux/signal.h:116:5: warning: array index 1 is past the end of the array (that has type 'const unsigned long[1]') [-Warray-bounds]
     116 |                         (set1->sig[1] == set2->sig[1]) &&
         |                          ^         ~
   arch/x86/include/asm/signal.h:24:2: note: array 'sig' declared here
      24 |         unsigned long sig[_NSIG_WORDS];
         |         ^
   In file included from arch/x86/boot/startup/sme.c:38:
   In file included from include/linux/mm.h:36:


vim +/arch_enter_lazy_mmu_mode +237 include/linux/pgtable.h

   214	
   215	/*
   216	 * A facility to provide lazy MMU batching.  This allows PTE updates and
   217	 * page invalidations to be delayed until a call to leave lazy MMU mode
   218	 * is issued.  Some architectures may benefit from doing this, and it is
   219	 * beneficial for both shadow and direct mode hypervisors, which may batch
   220	 * the PTE updates which happen during this window.  Note that using this
   221	 * interface requires that read hazards be removed from the code.  A read
   222	 * hazard could result in the direct mode hypervisor case, since the actual
   223	 * write to the page tables may not yet have taken place, so reads though
   224	 * a raw PTE pointer after it has been modified are not guaranteed to be
   225	 * up to date.
   226	 *
   227	 * In the general case, no lock is guaranteed to be held between entry and exit
   228	 * of the lazy mode. So the implementation must assume preemption may be enabled
   229	 * and cpu migration is possible; it must take steps to be robust against this.
   230	 * (In practice, for user PTE updates, the appropriate page table lock(s) are
   231	 * held, but for kernel PTE updates, no lock is held). Nesting is not permitted
   232	 * and the mode cannot be used in interrupt context.
   233	 */
   234	#ifdef CONFIG_ARCH_LAZY_MMU
   235	static inline void lazy_mmu_mode_enable(void)
   236	{
 > 237		arch_enter_lazy_mmu_mode();
   238	}
   239	
   240	static inline void lazy_mmu_mode_disable(void)
   241	{
 > 242		arch_leave_lazy_mmu_mode();
   243	}
   244	

-- 
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:[~2025-10-15  0:59 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-10-15  0:58 [broonie-misc:for-kernelci 6/13] include/linux/pgtable.h:237:2: error: call to undeclared function 'arch_enter_lazy_mmu_mode'; ISO C99 and later do not support implicit function declarations kernel test robot

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.