From: kernel test robot <lkp@intel.com>
To: Dave Hansen <dave.hansen@linux.intel.com>
Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev
Subject: [daveh-devel:kss-2026-10-23 25/25] arch/x86/kernel/cet.c:330:6: error: redefinition of 'arch_kernel_stack_lock_current'
Date: Sun, 25 Oct 2026 10:24:36 +0800 [thread overview]
Message-ID: <202610251021.TiL9FTBK-lkp@intel.com> (raw)
tree: https://git.kernel.org/pub/scm/linux/kernel/git/daveh/devel.git kss-2026-10-23
head: b6fa923e47fcecf329844fd91ed615de35478ea3
commit: b6fa923e47fcecf329844fd91ed615de35478ea3 [25/25] x86/boot: Add CPU shadow stack bootstrapping
config: x86_64-kexec (https://download.01.org/0day-ci/archive/20261025/202610251021.TiL9FTBK-lkp@intel.com/config)
compiler: clang version 22.1.8 (https://github.com/llvm/llvm-project ca7933e47d3a3451d81e72ac174dcb5aa28b59d1)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20261025/202610251021.TiL9FTBK-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/202610251021.TiL9FTBK-lkp@intel.com/
All errors (new ones prefixed by >>):
arch/x86/kernel/cet.c:277:17: warning: no previous prototype for function 'kshstk_build' [-Wmissing-prototypes]
277 | asmlinkage void kshstk_build(unsigned long *root_sp)
| ^
arch/x86/kernel/cet.c:277:12: note: declare 'static' if the function is not intended to be used outside of this translation unit
277 | asmlinkage void kshstk_build(unsigned long *root_sp)
| ^
| static
>> arch/x86/kernel/cet.c:330:6: error: redefinition of 'arch_kernel_stack_lock_current'
330 | void arch_kernel_stack_lock_current(void)
| ^
arch/x86/include/asm/shstk.h:49:20: note: previous definition is here
49 | static inline void arch_kernel_stack_lock_current(void) {}
| ^
>> arch/x86/kernel/cet.c:351:18: error: no member named 'kshstk_ssp' in 'struct thread_struct'
351 | current->thread.kshstk_ssp = kshstk_enable_current();
| ~~~~~~~~~~~~~~~ ^
>> arch/x86/kernel/cet.c:351:31: error: call to undeclared function 'kshstk_enable_current'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
351 | current->thread.kshstk_ssp = kshstk_enable_current();
| ^
1 warning and 3 errors generated.
vim +/arch_kernel_stack_lock_current +330 arch/x86/kernel/cet.c
320
321 /*
322 * This "locks" the stack in place and does not allow any control
323 * flow manipulation to occur because of changes to the stack.
324 *
325 * CPU enters with shadow stacks disabled and leaves with them
326 * enabled.
327 *
328 * Must be called before the CPU does its first context switch.
329 */
> 330 void arch_kernel_stack_lock_current(void)
331 {
332 unsigned long flags;
333
334 if (!cpu_feature_enabled(X86_FEATURE_KERN_SHSTK))
335 return;
336
337 kshstk_prepare_pages();
338
339 /*
340 * Regular interrupts are delivered on stack level 0. There
341 * is a window within the enabling where CET_SHSTK_EN=1 but
342 * SSP is not yet set. If an interrupt is delivered in that
343 * window, it would try to push on to this stack. Disable
344 * regular interrupts over this window.
345 *
346 * Interrupts that use other stack levels (like NMI) are OK
347 * because FRED switches stacks for them and does not push
348 * on stack level 0.
349 */
350 local_irq_save(flags);
> 351 current->thread.kshstk_ssp = kshstk_enable_current();
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
next reply other threads:[~2026-10-25 2:25 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-25 2:24 kernel test robot [this message]
-- strict thread matches above, loose matches on Subject: below --
2026-10-24 0:50 [daveh-devel:kss-2026-10-23 25/25] arch/x86/kernel/cet.c:330:6: error: redefinition of 'arch_kernel_stack_lock_current' kernel test robot
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=202610251021.TiL9FTBK-lkp@intel.com \
--to=lkp@intel.com \
--cc=dave.hansen@linux.intel.com \
--cc=llvm@lists.linux.dev \
--cc=oe-kbuild-all@lists.linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.