#define pr_fmt(fmt) …
#include <linux/buildid.h>
#include <linux/init.h>
#include <linux/utsname.h>
#include <linux/vmalloc.h>
#include <linux/sizes.h>
#include <linux/kexec.h>
#include <linux/memory.h>
#include <linux/mm.h>
#include <linux/cpuhotplug.h>
#include <linux/memblock.h>
#include <linux/kmemleak.h>
#include <linux/crash_core.h>
#include <linux/reboot.h>
#include <linux/btf.h>
#include <linux/objtool.h>
#include <asm/page.h>
#include <asm/sections.h>
#include <crypto/sha1.h>
#include "kallsyms_internal.h"
#include "kexec_internal.h"
note_buf_t __percpu *crash_notes;
#ifdef CONFIG_CRASH_DUMP
int kimage_crash_copy_vmcoreinfo(struct kimage *image)
{ … }
int kexec_should_crash(struct task_struct *p)
{ … }
int kexec_crash_loaded(void)
{ … }
EXPORT_SYMBOL_GPL(…);
void __noclone __crash_kexec(struct pt_regs *regs)
{ … }
STACK_FRAME_NON_STANDARD(…);
__bpf_kfunc void crash_kexec(struct pt_regs *regs)
{ … }
static inline resource_size_t crash_resource_size(const struct resource *res)
{ … }
int crash_prepare_elf64_headers(struct crash_mem *mem, int need_kernel_map,
void **addr, unsigned long *sz)
{ … }
int crash_exclude_mem_range(struct crash_mem *mem,
unsigned long long mstart, unsigned long long mend)
{ … }
ssize_t crash_get_memory_size(void)
{ … }
static int __crash_shrink_memory(struct resource *old_res,
unsigned long new_size)
{ … }
int crash_shrink_memory(unsigned long new_size)
{ … }
void crash_save_cpu(struct pt_regs *regs, int cpu)
{ … }
static int __init crash_notes_memory_init(void)
{ … }
subsys_initcall(crash_notes_memory_init);
#endif
#ifdef CONFIG_CRASH_HOTPLUG
#undef pr_fmt
#define pr_fmt(fmt) …
static DEFINE_MUTEX(__crash_hotplug_lock);
#define crash_hotplug_lock() …
#define crash_hotplug_unlock() …
int crash_check_hotplug_support(void)
{ … }
static void crash_handle_hotplug_event(unsigned int hp_action, unsigned int cpu, void *arg)
{ … }
static int crash_memhp_notifier(struct notifier_block *nb, unsigned long val, void *arg)
{ … }
static struct notifier_block crash_memhp_nb = …;
static int crash_cpuhp_online(unsigned int cpu)
{ … }
static int crash_cpuhp_offline(unsigned int cpu)
{ … }
static int __init crash_hotplug_init(void)
{ … }
subsys_initcall(crash_hotplug_init);
#endif