kexec.h 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. #ifndef _ASM_POWERPC_KEXEC_H
  2. #define _ASM_POWERPC_KEXEC_H
  3. /*
  4. * Maximum page that is mapped directly into kernel memory.
  5. * XXX: Since we copy virt we can use any page we allocate
  6. */
  7. #define KEXEC_SOURCE_MEMORY_LIMIT (-1UL)
  8. /*
  9. * Maximum address we can reach in physical address mode.
  10. * XXX: I want to allow initrd in highmem. Otherwise set to rmo on LPAR.
  11. */
  12. #define KEXEC_DESTINATION_MEMORY_LIMIT (-1UL)
  13. /* Maximum address we can use for the control code buffer */
  14. #ifdef __powerpc64__
  15. #define KEXEC_CONTROL_MEMORY_LIMIT (-1UL)
  16. #else
  17. /* TASK_SIZE, probably left over from use_mm ?? */
  18. #define KEXEC_CONTROL_MEMORY_LIMIT TASK_SIZE
  19. #endif
  20. #define KEXEC_CONTROL_CODE_SIZE 4096
  21. /* The native architecture */
  22. #ifdef __powerpc64__
  23. #define KEXEC_ARCH KEXEC_ARCH_PPC64
  24. #else
  25. #define KEXEC_ARCH KEXEC_ARCH_PPC
  26. #endif
  27. #ifndef __ASSEMBLY__
  28. #define MAX_NOTE_BYTES 1024
  29. typedef u32 note_buf_t[MAX_NOTE_BYTES / sizeof(u32)];
  30. extern note_buf_t crash_notes[];
  31. #ifdef __powerpc64__
  32. extern void kexec_smp_wait(void); /* get and clear naca physid, wait for
  33. master to copy new code to 0 */
  34. extern void __init kexec_setup(void);
  35. #else
  36. struct kimage;
  37. extern void machine_kexec_simple(struct kimage *image);
  38. #endif
  39. #endif /* ! __ASSEMBLY__ */
  40. #endif /* _ASM_POWERPC_KEXEC_H */