zImage_layout.txt 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. Information about the Linux/PPC kernel images
  2. =====================================================================
  3. Please mail me (Cort Dougan, cort@fsmlabs.com) if you have questions,
  4. comments or corrections.
  5. This document is meant to answer several questions I've had about how
  6. the PReP system boots and how Linux/PPC interacts with that mechanism.
  7. It would be nice if we could have information on how other architectures
  8. boot here as well. If you have anything to contribute, please
  9. let me know.
  10. 1. PReP boot file
  11. This is the file necessary to boot PReP systems from floppy or
  12. hard drive. The firmware reads the PReP partition table entry
  13. and will load the image accordingly.
  14. To boot the zImage, copy it onto a floppy with dd if=zImage of=/dev/fd0h1440
  15. or onto a PReP hard drive partition with dd if=zImage of=/dev/sda4
  16. assuming you've created a PReP partition (type 0x41) with fdisk on
  17. /dev/sda4.
  18. The layout of the image format is:
  19. 0x0 +------------+
  20. | | PReP partition table entry
  21. | |
  22. 0x400 +------------+
  23. | | Bootstrap program code + data
  24. | |
  25. | |
  26. +------------+
  27. | | compressed kernel, elf header removed
  28. +------------+
  29. | | initrd (if loaded)
  30. +------------+
  31. | | Elf section table for bootstrap program
  32. +------------+
  33. 2. MBX boot file
  34. The MBX boards can load an elf image, and relocate it to the
  35. proper location in memory - it copies the image to the location it was
  36. linked at.