kexec: move sys_kexec_load() prototype to syscalls.h
authorDominik Brodowski <linux@dominikbrodowski.net>
Thu, 22 Mar 2018 16:46:57 +0000 (17:46 +0100)
committerDominik Brodowski <linux@dominikbrodowski.net>
Mon, 2 Apr 2018 18:16:15 +0000 (20:16 +0200)
As the syscall function should only be called from the system call table
but not from elsewhere in the kernel, move the prototype for
sys_kexec_load() to include/syscall.h.

Cc: Eric Biederman <ebiederm@xmission.com>
Cc: kexec@lists.infradead.org
Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
include/linux/kexec.h
include/linux/syscalls.h

index f16f6ceb387591abca37812cfe7aa4f2fc328eca..0ebcbeb210566468c9c167937b8aa17070f4e38e 100644 (file)
@@ -223,10 +223,6 @@ struct kimage {
 extern void machine_kexec(struct kimage *image);
 extern int machine_kexec_prepare(struct kimage *image);
 extern void machine_kexec_cleanup(struct kimage *image);
-extern asmlinkage long sys_kexec_load(unsigned long entry,
-                                       unsigned long nr_segments,
-                                       struct kexec_segment __user *segments,
-                                       unsigned long flags);
 extern int kernel_kexec(void);
 extern struct page *kimage_alloc_control_pages(struct kimage *image,
                                                unsigned int order);
index 815fbdd9cca1071916bd8bb63d3450f91711be63..8330f046541eefe83e96a540b98edcd07526b27d 100644 (file)
@@ -936,6 +936,10 @@ asmlinkage long sys_pkey_mprotect(unsigned long start, size_t len,
                                  unsigned long prot, int pkey);
 asmlinkage long sys_pkey_alloc(unsigned long flags, unsigned long init_val);
 asmlinkage long sys_pkey_free(int pkey);
+asmlinkage long sys_kexec_load(unsigned long entry,
+                              unsigned long nr_segments,
+                              struct kexec_segment __user *segments,
+                              unsigned long flags);
 asmlinkage long sys_statx(int dfd, const char __user *path, unsigned flags,
                          unsigned mask, struct statx __user *buffer);