summaryrefslogtreecommitdiff
path: root/kexec/kexec-syscall.h
diff options
context:
space:
mode:
Diffstat (limited to 'kexec/kexec-syscall.h')
-rw-r--r--kexec/kexec-syscall.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/kexec/kexec-syscall.h b/kexec/kexec-syscall.h
index bea29d4..be6ccd5 100644
--- a/kexec/kexec-syscall.h
+++ b/kexec/kexec-syscall.h
@@ -39,6 +39,9 @@
#ifdef __s390__
#define __NR_kexec_load 277
#endif
+#ifdef __loongarch__
+#define __NR_kexec_load 104
+#endif
#if defined(__arm__) || defined(__arm64__)
#define __NR_kexec_load __NR_SYSCALL_BASE + 347
#endif
@@ -134,6 +137,7 @@ static inline long kexec_file_load(int kernel_fd, int initrd_fd,
#define KEXEC_ARCH_MIPS_LE (10 << 16)
#define KEXEC_ARCH_MIPS ( 8 << 16)
#define KEXEC_ARCH_CRIS (76 << 16)
+#define KEXEC_ARCH_LOONGARCH (258 << 16)
#define KEXEC_MAX_SEGMENTS 16
@@ -177,5 +181,8 @@ static inline long kexec_file_load(int kernel_fd, int initrd_fd,
#if defined(__arm64__)
#define KEXEC_ARCH_NATIVE KEXEC_ARCH_ARM64
#endif
+#if defined(__loongarch__)
+#define KEXEC_ARCH_NATIVE KEXEC_ARCH_LOONGARCH
+#endif
#endif /* KEXEC_SYSCALL_H */