bootparam.h 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. #ifndef _ASM_BOOTPARAM_H
  2. #define _ASM_BOOTPARAM_H
  3. #include <linux/types.h>
  4. #include <linux/screen_info.h>
  5. #include <linux/apm_bios.h>
  6. #include <linux/edd.h>
  7. #include <asm/e820.h>
  8. #include <asm/ist.h>
  9. #include <video/edid.h>
  10. struct setup_header {
  11. u8 setup_sects;
  12. u16 root_flags;
  13. u32 syssize;
  14. u16 ram_size;
  15. u16 vid_mode;
  16. u16 root_dev;
  17. u16 boot_flag;
  18. u16 jump;
  19. u32 header;
  20. u16 version;
  21. u32 realmode_swtch;
  22. u16 start_sys;
  23. u16 kernel_version;
  24. u8 type_of_loader;
  25. u8 loadflags;
  26. #define LOADED_HIGH 0x01
  27. #define CAN_USE_HEAP 0x80
  28. u16 setup_move_size;
  29. u32 code32_start;
  30. u32 ramdisk_image;
  31. u32 ramdisk_size;
  32. u32 bootsect_kludge;
  33. u16 heap_end_ptr;
  34. u16 _pad1;
  35. u32 cmd_line_ptr;
  36. u32 initrd_addr_max;
  37. u32 kernel_alignment;
  38. u8 relocatable_kernel;
  39. } __attribute__((packed));
  40. struct sys_desc_table {
  41. u16 length;
  42. u8 table[14];
  43. };
  44. struct efi_info {
  45. u32 _pad1;
  46. u32 efi_systab;
  47. u32 efi_memdesc_size;
  48. u32 efi_memdesc_version;
  49. u32 efi_memmap;
  50. u32 efi_memmap_size;
  51. u32 _pad2[2];
  52. };
  53. /* The so-called "zeropage" */
  54. struct boot_params {
  55. struct screen_info screen_info; /* 0x000 */
  56. struct apm_bios_info apm_bios_info; /* 0x040 */
  57. u8 _pad2[12]; /* 0x054 */
  58. struct ist_info ist_info; /* 0x060 */
  59. u8 _pad3[16]; /* 0x070 */
  60. u8 hd0_info[16]; /* obsolete! */ /* 0x080 */
  61. u8 hd1_info[16]; /* obsolete! */ /* 0x090 */
  62. struct sys_desc_table sys_desc_table; /* 0x0a0 */
  63. u8 _pad4[144]; /* 0x0b0 */
  64. struct edid_info edid_info; /* 0x140 */
  65. struct efi_info efi_info; /* 0x1c0 */
  66. u32 alt_mem_k; /* 0x1e0 */
  67. u32 scratch; /* Scratch field! */ /* 0x1e4 */
  68. u8 e820_entries; /* 0x1e8 */
  69. u8 eddbuf_entries; /* 0x1e9 */
  70. u8 edd_mbr_sig_buf_entries; /* 0x1ea */
  71. u8 _pad6[6]; /* 0x1eb */
  72. struct setup_header hdr; /* setup header */ /* 0x1f1 */
  73. u8 _pad7[0x290-0x1f1-sizeof(struct setup_header)];
  74. u32 edd_mbr_sig_buffer[EDD_MBR_SIG_MAX]; /* 0x290 */
  75. struct e820entry e820_map[E820MAX]; /* 0x2d0 */
  76. u8 _pad8[48]; /* 0xcd0 */
  77. struct edd_info eddbuf[EDDMAXNR]; /* 0xd00 */
  78. u8 _pad9[276]; /* 0xeec */
  79. } __attribute__((packed));
  80. #endif /* _ASM_BOOTPARAM_H */