Thread (12 messages) 12 messages, 6 authors, 2025-07-29

Re: [PATCH v4 0/4] stackleak: Support Clang stack depth tracking

From: Kees Cook <kees@kernel.org>
Date: 2025-07-26 21:47:59
Also in: kexec, kvm, linux-acpi, linux-efi, linux-hardening, linux-kbuild, linux-mm, linux-security-module, lkml, llvm, platform-driver-x86

On Fri, Jul 25, 2025 at 05:43:13PM -0700, Nathan Chancellor wrote:
  ld.lld: error: undefined symbol: __sanitizer_cov_stack_depth
  >>> referenced by atags_to_fdt.c
Proposed fix:
https://lore.kernel.org/lkml/20250726212945.work.975-kees@kernel.org/ (local)
  kernel/kstack_erase.c:168:2: warning: function with attribute 'no_caller_saved_registers' should only call a function with attribute 'no_caller_saved_registers' or be compiled with '-mgeneral-regs-only' [-Wexcessive-regsave]
Proposed fix:
https://lore.kernel.org/lkml/20250726212615.work.800-kees@kernel.org/ (local)
  In file included from kernel/fork.c:96:
  include/linux/kstack_erase.h:29:37: error: passing 'const struct task_struct *' to parameter of type 'struct task_struct *' discards qualifiers [-Werror,-Wincompatible-pointer-types-discards-qualifiers]
     29 |         return (unsigned long)end_of_stack(tsk) + sizeof(unsigned long);
        |                                            ^~~
  include/linux/sched/task_stack.h:56:63: note: passing argument to parameter 'p' here
     56 | static inline unsigned long *end_of_stack(struct task_struct *p)
        |                                                               ^
Proposed fix:
https://lore.kernel.org/lkml/20250726210641.work.114-kees@kernel.org/ (local)

Thanks for the reports! :)

-Kees

-- 
Kees Cook
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help