#ifndef _LINUX_STACKPROTECTOR_H
#define _LINUX_STACKPROTECTOR_H …
#include <linux/compiler.h>
#include <linux/sched.h>
#include <linux/random.h>
#ifdef CONFIG_64BIT
# ifdef __LITTLE_ENDIAN
#define CANARY_MASK …
# else
#define CANARY_MASK …
# endif
#else
#define CANARY_MASK …
#endif
static inline unsigned long get_random_canary(void)
{ … }
#if defined(CONFIG_STACKPROTECTOR) || defined(CONFIG_ARM64_PTR_AUTH)
# include <asm/stackprotector.h>
#else
static inline void boot_init_stack_canary(void)
{
}
#endif
#endif