summaryrefslogtreecommitdiff
path: root/include/linux/kexec.h
diff options
context:
space:
mode:
authorThiago Jung Bauermann <bauerman@linux.vnet.ibm.com>2016-11-29 23:45:48 +1100
committerMichael Ellerman <mpe@ellerman.id.au>2016-11-30 23:14:59 +1100
commitec2b9bfaac44ea889625a6b9473d33898b10d35f (patch)
treeabb247ab853ca78135948da2e30da525b4a5839f /include/linux/kexec.h
parent60fe3910bb029e3671ce7ac080a7acb7e032b9e0 (diff)
kexec_file: Change kexec_add_buffer to take kexec_buf as argument.
This is done to simplify the kexec_add_buffer argument list. Adapt all callers to set up a kexec_buf to pass to kexec_add_buffer. In addition, change the type of kexec_buf.buffer from char * to void *. There is no particular reason for it to be a char *, and the change allows us to get rid of 3 existing casts to char * in the code. Signed-off-by: Thiago Jung Bauermann <bauerman@linux.vnet.ibm.com> Acked-by: Dave Young <dyoung@redhat.com> Acked-by: Balbir Singh <bsingharora@gmail.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Diffstat (limited to 'include/linux/kexec.h')
-rw-r--r--include/linux/kexec.h8
1 files changed, 2 insertions, 6 deletions
diff --git a/include/linux/kexec.h b/include/linux/kexec.h
index 5e320ddaaa82..437ef1b47428 100644
--- a/include/linux/kexec.h
+++ b/include/linux/kexec.h
@@ -163,7 +163,7 @@ struct kexec_file_ops {
*/
struct kexec_buf {
struct kimage *image;
- char *buffer;
+ void *buffer;
unsigned long bufsz;
unsigned long mem;
unsigned long memsz;
@@ -175,6 +175,7 @@ struct kexec_buf {
int __weak arch_kexec_walk_mem(struct kexec_buf *kbuf,
int (*func)(u64, u64, void *));
+extern int kexec_add_buffer(struct kexec_buf *kbuf);
#endif /* CONFIG_KEXEC_FILE */
struct kimage {
@@ -239,11 +240,6 @@ extern asmlinkage long sys_kexec_load(unsigned long entry,
struct kexec_segment __user *segments,
unsigned long flags);
extern int kernel_kexec(void);
-extern int kexec_add_buffer(struct kimage *image, char *buffer,
- unsigned long bufsz, unsigned long memsz,
- unsigned long buf_align, unsigned long buf_min,
- unsigned long buf_max, bool top_down,
- unsigned long *load_addr);
extern struct page *kimage_alloc_control_pages(struct kimage *image,
unsigned int order);
extern int kexec_load_purgatory(struct kimage *image, unsigned long min,