Guest User

Raspberry Pi 2 B network boot

a guest
Aug 22nd, 2016
375
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 7.44 KB | None | 0 0
  1. # Files downloaded via TFTP by `bootcode.bin` (firmware 6272ee1c3fd9f0a87015adb36830a18f3e3b7245) on Raspberry Pi 2 B #
  2.  
  3. ## Boot process #1 ##
  4.  
  5. `<SERIAL_NUMBER>/` on the TFTP server contains all files from `/boot` after updating to the "next" branch **plus** `recovery.elf` symlinked to `start.elf`, `recovery.cmdline` symlinked to `cmdline.txt`, as without that the boot process didn't work as you can see in #2 below:
  6.  
  7. * <SERIAL_NUMBER>/start.elf - fails after receiving first data packet with:
  8. ```
  9. Opcode: Error Code (5)
  10. Error code: Not defined (0)
  11. Error message: Early terminate
  12. ```
  13. According to [1] (paragraph "TFTP FILE READ") this is just a check for existence done by the Raspi.
  14. * <SERIAL_NUMBER>/autoboot.txt - fails with "File not found"
  15. * <SERIAL_NUMBER>/config.txt - download succeeds
  16. * <SERIAL_NUMBER>/recovery.elf - succeeds, because I linked it to `start.elf`
  17. * <SERIAL_NUMBER>/fixup_rc.dat - fails with "File not found"
  18. * <SERIAL_NUMBER>/recovery.elf - existence positively checked
  19. * <SERIAL_NUMBER>/config.txt - download succeeds
  20. * <SERIAL_NUMBER>/dt-blob.bin - fails with "File not found"
  21. * <SERIAL_NUMBER>/recovery.elf - existence positively checked
  22. * <SERIAL_NUMBER>/config.txt - download succeeds
  23. * <SERIAL_NUMBER>/bootcfg.txt - fails with "File not found"
  24. * <SERIAL_NUMBER>/recovery.cmdline - succeeds, because I linked it to `cmdline.txt`
  25. * <SERIAL_NUMBER>/recovery.img - fails with "File not found"
  26. * <SERIAL_NUMBER>/recovery7.img - fails with "File not found"
  27. * <SERIAL_NUMBER>/recovery.img - fails with "File not found"
  28. * <SERIAL_NUMBER>/kernel7.img - existence positively checked
  29. * <SERIAL_NUMBER>/armstub7.bin - fails with "File not found"
  30. * <SERIAL_NUMBER>/armstub.bin - fails with "File not found"
  31. * <SERIAL_NUMBER>/kernel7.img - download succeeds
  32. * <SERIAL_NUMBER>/recovery.rfs - fails with "File not found"
  33. * <SERIAL_NUMBER>/bcm2709-rpi-2-b.dtb - download succeeds
  34. * <SERIAL_NUMBER>/config.txt - download succeeds
  35. * <SERIAL_NUMBER>/overlays/i2c-rtc.dtbo - download succeeds
  36.  
  37. [1]: https://www.raspberrypi.org/documentation/hardware/raspberrypi/bootmodes/net.md
  38.  
  39. => Pi boots, but memory is limited to 128 MiB!
  40. ```
  41. # dmesg
  42. [...]
  43. [ 0.000000] Memory: 111532K/131072K available (6348K kernel code, 432K rwdata, 1712K rodata, 480K init, 764K bss, 11348K reserved, 8192K cma-reserved)
  44. [...]
  45. # cat /proc/cmdline
  46. dma.dmachans=0x7f35 bcm2708_fb.fbwidth=1184 bcm2708_fb.fbheight=624 bcm2709.boardrev=0xa01041 bcm2709.serial=0xecaa6d73 smsc95xx.macaddr=B8:27:EB:12:34:56 bcm2708_fb.fbswap=1 bcm2709.uart_clock=3000000 bcm2709.disk_led_gpio=47 bcm2709.disk_led_active_low=0 vc_mem.mem_base=0xec00000 vc_mem.mem_size=0x10000000 dwc_otg.lpm_enable=0 console=ttyAMA0,115200 console=tty1 root=/dev/nfs ip=dhcp elevator=deadline rootwait
  47. ```
  48.  
  49. ## Boot process #2 ##
  50.  
  51. Same as #1 but with `recovery.elf`, `recovery.cmdline` removed:
  52.  
  53. * <SERIAL_NUMBER>/start.elf - existence positively checked
  54. * <SERIAL_NUMBER>/autoboot.txt - fails with "File not found"
  55. * <SERIAL_NUMBER>/config.txt - download succeeds
  56. * <SERIAL_NUMBER>/recovery.elf - fails with "File not found"
  57. * <SERIAL_NUMBER>/ - fails, but maybe check for existence of directory, although this should be already clear by now
  58. * <SERIAL_NUMBER>/ - fails, but maybe check for existence of directory, although this should be already clear by now
  59.  
  60. => Pi does not boot!
  61.  
  62. ## Boot process #3 ##
  63.  
  64. Same as #1 but `config.txt`, `recovery.elf`, `recovery.cmdline` removed:
  65.  
  66. * <SERIAL_NUMBER>/start.elf - existence positively checked
  67. * <SERIAL_NUMBER>/autoboot.txt - fails with "File not found"
  68. * <SERIAL_NUMBER>/config.txt - fails with "File not found"
  69. * <SERIAL_NUMBER>/recovery.elf - fails with "File not found"
  70. * <SERIAL_NUMBER>/start.elf - download succeeds
  71. * <SERIAL_NUMBER>/ - fails, but maybe check for existence of directory, although this should be already clear by now
  72. * <SERIAL_NUMBER>/recovery.elf - fails with "File not found"
  73. * <SERIAL_NUMBER>/config.txt - fails with "File not found"
  74. * <SERIAL_NUMBER>/dt-blob.bin - fails with "File not found"
  75. * <SERIAL_NUMBER>/recovery.elf - fails with "File not found"
  76. * <SERIAL_NUMBER>/config.txt - fails with "File not found"
  77. * <SERIAL_NUMBER>/bootcfg.txt - fails with "File not found"
  78. * <SERIAL_NUMBER>/cmdline.txt - download succeeds
  79. * <SERIAL_NUMBER>/recovery7.img - fails with "File not found"
  80. * <SERIAL_NUMBER>/recovery.img - fails with "File not found"
  81. * <SERIAL_NUMBER>/kernel7.img - existence positively checked
  82. * <SERIAL_NUMBER>/armstub7.img - fails with "File not found"
  83. * <SERIAL_NUMBER>/armstub.img - fails with "File not found"
  84. * <SERIAL_NUMBER>/kernel7.img - download succeeds
  85. * <SERIAL_NUMBER>/bcm2709-rpi-2-b.dtb - download succeeds
  86. * <SERIAL_NUMBER>/config.txt - fails with "File not found"
  87.  
  88. => Pi boots, but memory is limited to 128 MiB!
  89. ```
  90. # dmesg
  91. [...]
  92. [ 0.000000] Memory: 111532K/131072K available (6348K kernel code, 432K rwdata, 1712K rodata, 480K init, 764K bss, 11348K reserved, 8192K cma-reserved)
  93. [...]
  94. # cat /proc/cmdline
  95. dma.dmachans=0x7f35 bcm2708_fb.fbwidth=1184 bcm2708_fb.fbheight=624 bcm2709.boardrev=0xa01041 bcm2709.serial=0xecaa6d73 smsc95xx.macaddr=B8:27:EB:12:34:56 bcm2708_fb.fbswap=1 bcm2709.uart_clock=3000000 bcm2709.disk_led_gpio=47 bcm2709.disk_led_active_low=0 vc_mem.mem_base=0xec00000 vc_mem.mem_size=0x10000000 dwc_otg.lpm_enable=0 console=ttyAMA0,115200 console=tty1 root=/dev/nfs ip=dhcp elevator=deadline rootwait
  96. ```
  97.  
  98. ## Boot process #4 ##
  99.  
  100. `<SERIAL_NUMBER>/` on the TFTP server contains all files from `/boot` after updating to the "next" branch (i.e. should be the same as #2 but actually worked!):
  101.  
  102. * <SERIAL_NUMBER>/start.elf - existence positively checked
  103. * <SERIAL_NUMBER>/autoboot.txt - fails with "File not found"
  104. * <SERIAL_NUMBER>/config.txt - download succeeds
  105. * <SERIAL_NUMBER>/recovery.elf - fails with "File not found"
  106. * <SERIAL_NUMBER>/start.elf - download succeeds
  107. * <SERIAL_NUMBER>/ - fails, but maybe check for existence of directory, although this should be already clear by now
  108. * <SERIAL_NUMBER>/recovery.elf - fails with "File not found"
  109. * <SERIAL_NUMBER>/config.txt - download succeeds
  110. * <SERIAL_NUMBER>/dt-blob.bin - fails with "File not found"
  111. * <SERIAL_NUMBER>/recovery.elf - fails with "File not found"
  112. * <SERIAL_NUMBER>/config.txt - download succeeds
  113. * <SERIAL_NUMBER>/bootcfg.txt - fails with "File not found"
  114. * <SERIAL_NUMBER>/cmdline.txt - download succeeds
  115. * <SERIAL_NUMBER>/recovery7.img - fails with "File not found"
  116. * <SERIAL_NUMBER>/recovery.img - fails with "File not found"
  117. * <SERIAL_NUMBER>/kernel7.img - existence positively checked
  118. * <SERIAL_NUMBER>/armstub7.img - fails with "File not found"
  119. * <SERIAL_NUMBER>/armstub.img - fails with "File not found"
  120. * <SERIAL_NUMBER>/kernel7.img - download succeeds
  121. * <SERIAL_NUMBER>/bcm2709-rpi-2-b.dtb - download succeeds
  122. * <SERIAL_NUMBER>/config.txt - download succeeds
  123.  
  124. => Pi boots, but memory is limited to 128 MiB!
  125. ```
  126. # dmesg
  127. [...]
  128. [ 0.000000] Memory: 111532K/131072K available (6348K kernel code, 432K rwdata, 1712K rodata, 480K init, 764K bss, 11348K reserved, 8192K cma-reserved)
  129. [...]
  130. # cat /proc/cmdline
  131. dma.dmachans=0x7f35 bcm2708_fb.fbwidth=1184 bcm2708_fb.fbheight=624 bcm2709.boardrev=0xa01041 bcm2709.serial=0xecaa6d73 smsc95xx.macaddr=B8:27:EB:12:34:56 bcm2708_fb.fbswap=1 bcm2709.uart_clock=3000000 bcm2709.disk_led_gpio=47 bcm2709.disk_led_active_low=0 vc_mem.mem_base=0xec00000 vc_mem.mem_size=0x10000000 dwc_otg.lpm_enable=0 console=ttyAMA0,115200 console=tty1 root=/dev/nfs ip=dhcp elevator=deadline rootwait
  132. ```
Add Comment
Please, Sign In to add comment