I have my raspberry pi zero, and during development I spend a lot of time to eject-inject SD card and re-flash it. SD card image is prepared in Buildroot, so it includes boot partition with kernel, device tree overlays and partition with rootfs. Is there simpler way to re-flash SD card? For example via network? I know that U-boot can load kernel via tftp, but if I need not only kernel, but whole image(device tree overlays are extremely important)?
Asked
Active
Viewed 1,478 times
1 Answers
6
Use TFTP to load the kernel image, and NFS to mount the root filesystem over the network.

Thomas Petazzoni
- 5,636
- 17
- 25
-
But what about device tree and it's overlays? – artsin Feb 14 '17 at 10:33
-
As I understand, U-boot can load device tree blob, so seems I can apply all overlays on device tree, make blob and than load it after kernel via tftp. Am I right? – artsin Feb 14 '17 at 12:30
-
1So yes, with modern U-Boot you can use 'fdt apply' to apply overlays on top of the device tree that you have loaded into memory and boot that. You could further write that to wherever you like, assuming that you have enabled the commands to write wherever it is you want to write to. – Tom Rini Feb 14 '17 at 21:14
-
1@artsin or you can use [FIT](http://elinux.org/images/f/f4/Elc2013_Fernandes.pdf) image right away. – yegorich Feb 15 '17 at 15:18