blob: d34f065807e60e16784f594dace80bbc0385bdad [file] [log] [blame]
Elliott Hughes180edef2023-11-02 00:08:05 +00001/*
2 * This file is auto-generated. Modifications will be lost.
3 *
4 * See https://android.googlesource.com/platform/bionic/+/master/libc/kernel/
5 * for more information.
6 */
Ben Cheng655a7c02013-10-16 16:09:24 -07007#ifndef _UAPILINUX_KEXEC_H
8#define _UAPILINUX_KEXEC_H
9#include <linux/types.h>
10#define KEXEC_ON_CRASH 0x00000001
Ben Cheng655a7c02013-10-16 16:09:24 -070011#define KEXEC_PRESERVE_CONTEXT 0x00000002
Christopher Ferris67d1e5e2023-10-31 13:36:37 -070012#define KEXEC_UPDATE_ELFCOREHDR 0x00000004
Christopher Ferris7ac54f52024-08-07 21:07:12 +000013#define KEXEC_CRASH_HOTPLUG_SUPPORT 0x00000008
Ben Cheng655a7c02013-10-16 16:09:24 -070014#define KEXEC_ARCH_MASK 0xffff0000
Christopher Ferris82d75042015-01-26 10:57:07 -080015#define KEXEC_FILE_UNLOAD 0x00000001
16#define KEXEC_FILE_ON_CRASH 0x00000002
Christopher Ferris82d75042015-01-26 10:57:07 -080017#define KEXEC_FILE_NO_INITRAMFS 0x00000004
Christopher Ferrisb830ddf2024-03-28 11:48:08 -070018#define KEXEC_FILE_DEBUG 0x00000008
Tao Baod7db5942015-01-28 10:07:51 -080019#define KEXEC_ARCH_DEFAULT (0 << 16)
20#define KEXEC_ARCH_386 (3 << 16)
21#define KEXEC_ARCH_68K (4 << 16)
Christopher Ferris9584fa42019-12-09 15:36:13 -080022#define KEXEC_ARCH_PARISC (15 << 16)
Ben Cheng655a7c02013-10-16 16:09:24 -070023#define KEXEC_ARCH_X86_64 (62 << 16)
24#define KEXEC_ARCH_PPC (20 << 16)
25#define KEXEC_ARCH_PPC64 (21 << 16)
Christopher Ferris38062f92014-07-09 15:33:25 -070026#define KEXEC_ARCH_IA_64 (50 << 16)
Ben Cheng655a7c02013-10-16 16:09:24 -070027#define KEXEC_ARCH_ARM (40 << 16)
28#define KEXEC_ARCH_S390 (22 << 16)
29#define KEXEC_ARCH_SH (42 << 16)
Christopher Ferris38062f92014-07-09 15:33:25 -070030#define KEXEC_ARCH_MIPS_LE (10 << 16)
Tao Baod7db5942015-01-28 10:07:51 -080031#define KEXEC_ARCH_MIPS (8 << 16)
Christopher Ferris49f525c2016-12-12 14:55:36 -080032#define KEXEC_ARCH_AARCH64 (183 << 16)
Christopher Ferrisfcc3b4f2021-07-01 01:30:21 +000033#define KEXEC_ARCH_RISCV (243 << 16)
Christopher Ferris80ae69d2022-08-02 16:32:21 -070034#define KEXEC_ARCH_LOONGARCH (258 << 16)
Ben Cheng655a7c02013-10-16 16:09:24 -070035#define KEXEC_SEGMENT_MAX 16
36struct kexec_segment {
Christopher Ferris49f525c2016-12-12 14:55:36 -080037 const void * buf;
Christopher Ferris10a76e62022-06-08 13:31:52 -070038 __kernel_size_t bufsz;
Tao Baod7db5942015-01-28 10:07:51 -080039 const void * mem;
Christopher Ferris10a76e62022-06-08 13:31:52 -070040 __kernel_size_t memsz;
Christopher Ferris49f525c2016-12-12 14:55:36 -080041};
Nick Kralevicha67e4de2013-01-14 11:28:26 -080042#endif