5 #include <linux/types.h>
6 #include <linux/list.h>
10 * This structure is used to hold the arguments that are used when loading
14 typedef unsigned long kimage_entry_t;
15 #define IND_DESTINATION 0x1
16 #define IND_INDIRECTION 0x2
18 #define IND_SOURCE 0x8
20 #define KEXEC_SEGMENT_MAX 8
21 struct kexec_segment {
30 kimage_entry_t *entry;
31 kimage_entry_t *last_entry;
33 unsigned long destination;
36 struct page *control_code_page;
38 unsigned long nr_segments;
39 struct kexec_segment segment[KEXEC_SEGMENT_MAX];
41 struct list_head control_pages;
42 struct list_head dest_pages;
43 struct list_head unuseable_pages;
47 /* kexec interface functions */
48 extern void machine_kexec(struct kimage *image);
49 extern int machine_kexec_prepare(struct kimage *image);
50 extern void machine_kexec_cleanup(struct kimage *image);
51 extern asmlinkage long sys_kexec(unsigned long entry, long nr_segments,
52 struct kexec_segment *segments);
53 extern struct page *kimage_alloc_control_pages(struct kimage *image, unsigned int order);
54 extern struct kimage *kexec_image;
55 extern struct kimage *kexec_crash_image;
57 #endif /* LINUX_KEXEC_H */