arch/riscv/include/asm/kexec.h

Source file repositories/reference/linux-study-clean/arch/riscv/include/asm/kexec.h

File Facts

System
Linux kernel
Corpus path
arch/riscv/include/asm/kexec.h
Extension
.h
Size
2130 bytes
Lines
79
Domain
Architecture Layer
Bucket
arch/riscv
Inferred role
Architecture Layer: implementation source
Status
source implementation candidate

Why This File Exists

CPU and platform-specific kernel glue: boot entry, traps, syscall entry, interrupts, page tables, context switch, and low-level barriers.

Dependency Surface

Detected Declarations

Annotated Snippet

struct kimage_arch {
	void *fdt; /* For CONFIG_KEXEC_FILE */
	unsigned long fdt_addr;
};

extern const unsigned char riscv_kexec_relocate[];
extern const unsigned int riscv_kexec_relocate_size;

typedef void (*riscv_kexec_method)(unsigned long first_ind_entry,
				   unsigned long jump_addr,
				   unsigned long fdt_addr,
				   unsigned long hartid,
				   unsigned long va_pa_off);

extern riscv_kexec_method riscv_kexec_norelocate;

#ifdef CONFIG_KEXEC_FILE
extern const struct kexec_file_ops elf_kexec_ops;
extern const struct kexec_file_ops image_kexec_ops;

struct purgatory_info;
int arch_kexec_apply_relocations_add(struct purgatory_info *pi,
				     Elf_Shdr *section,
				     const Elf_Shdr *relsec,
				     const Elf_Shdr *symtab);
#define arch_kexec_apply_relocations_add arch_kexec_apply_relocations_add

struct kimage;
int arch_kimage_file_post_load_cleanup(struct kimage *image);
#define arch_kimage_file_post_load_cleanup arch_kimage_file_post_load_cleanup

int load_extra_segments(struct kimage *image, unsigned long kernel_start,
			unsigned long kernel_len, char *initrd,
			unsigned long initrd_len, char *cmdline,
			unsigned long cmdline_len);
#endif

#endif

Annotation

Implementation Notes