zero-page.txt 3.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889
  1. Summary of boot_params layout (kernel point of view)
  2. ( collected by Hans Lermen and Martin Mares )
  3. The contents of boot_params are used to pass parameters from the
  4. 16-bit realmode code of the kernel to the 32-bit part. References/settings
  5. to it mainly are in:
  6. arch/i386/boot/setup.S
  7. arch/i386/boot/video.S
  8. arch/i386/kernel/head.S
  9. arch/i386/kernel/setup.c
  10. Offset Type Description
  11. ------ ---- -----------
  12. 0 32 bytes struct screen_info, SCREEN_INFO
  13. ATTENTION, overlaps the following !!!
  14. 2 unsigned short EXT_MEM_K, extended memory size in Kb (from int 0x15)
  15. 0x20 unsigned short CL_MAGIC, commandline magic number (=0xA33F)
  16. 0x22 unsigned short CL_OFFSET, commandline offset
  17. Address of commandline is calculated:
  18. 0x90000 + contents of CL_OFFSET
  19. (only taken, when CL_MAGIC = 0xA33F)
  20. 0x40 20 bytes struct apm_bios_info, APM_BIOS_INFO
  21. 0x60 16 bytes Intel SpeedStep (IST) BIOS support information
  22. 0x80 16 bytes hd0-disk-parameter from intvector 0x41
  23. 0x90 16 bytes hd1-disk-parameter from intvector 0x46
  24. 0xa0 16 bytes System description table truncated to 16 bytes.
  25. ( struct sys_desc_table_struct )
  26. 0xb0 - 0x13f Free. Add more parameters here if you really need them.
  27. 0x140- 0x1be EDID_INFO Video mode setup
  28. 0x1c4 unsigned long EFI system table pointer
  29. 0x1c8 unsigned long EFI memory descriptor size
  30. 0x1cc unsigned long EFI memory descriptor version
  31. 0x1d0 unsigned long EFI memory descriptor map pointer
  32. 0x1d4 unsigned long EFI memory descriptor map size
  33. 0x1e0 unsigned long ALT_MEM_K, alternative mem check, in Kb
  34. 0x1e4 unsigned long Scratch field for the kernel setup code
  35. 0x1e8 char number of entries in E820MAP (below)
  36. 0x1e9 unsigned char number of entries in EDDBUF (below)
  37. 0x1ea unsigned char number of entries in EDD_MBR_SIG_BUFFER (below)
  38. 0x1f1 char size of setup.S, number of sectors
  39. 0x1f2 unsigned short MOUNT_ROOT_RDONLY (if !=0)
  40. 0x1f4 unsigned short size of compressed kernel-part in the
  41. (b)zImage-file (in 16 byte units, rounded up)
  42. 0x1f6 unsigned short swap_dev (unused AFAIK)
  43. 0x1f8 unsigned short RAMDISK_FLAGS
  44. 0x1fa unsigned short VGA-Mode (old one)
  45. 0x1fc unsigned short ORIG_ROOT_DEV (high=Major, low=minor)
  46. 0x1ff char AUX_DEVICE_INFO
  47. 0x200 short jump to start of setup code aka "reserved" field.
  48. 0x202 4 bytes Signature for SETUP-header, ="HdrS"
  49. 0x206 unsigned short Version number of header format
  50. Current version is 0x0201...
  51. 0x208 8 bytes (used by setup.S for communication with boot loaders,
  52. look there)
  53. 0x210 char LOADER_TYPE, = 0, old one
  54. else it is set by the loader:
  55. 0xTV: T=0 for LILO
  56. 1 for Loadlin
  57. 2 for bootsect-loader
  58. 3 for SYSLINUX
  59. 4 for ETHERBOOT
  60. 5 for ELILO
  61. 7 for GRuB
  62. 8 for U-BOOT
  63. 9 for Xen
  64. V = version
  65. 0x211 char loadflags:
  66. bit0 = 1: kernel is loaded high (bzImage)
  67. bit7 = 1: Heap and pointer (see below) set by boot
  68. loader.
  69. 0x212 unsigned short (setup.S)
  70. 0x214 unsigned long KERNEL_START, where the loader started the kernel
  71. 0x218 unsigned long INITRD_START, address of loaded ramdisk image
  72. 0x21c unsigned long INITRD_SIZE, size in bytes of ramdisk image
  73. 0x220 4 bytes (setup.S)
  74. 0x224 unsigned short setup.S heap end pointer
  75. 0x226 unsigned short zero_pad
  76. 0x228 unsigned long cmd_line_ptr
  77. 0x22c unsigned long ramdisk_max
  78. 0x230 16 bytes trampoline
  79. 0x290 - 0x2cf EDD_MBR_SIG_BUFFER (edd.S)
  80. 0x2d0 - 0xd00 E820MAP
  81. 0xd00 - 0xeff EDDBUF (edd.S) for disk signature read sector
  82. 0xd00 - 0xeeb EDDBUF (edd.S) for edd data