doc: booting with U-Boot from SD card

This commit is contained in:
Adam Mizerski 2020-12-04 22:25:14 +01:00
parent 50fe52d817
commit 644db3f3a8
No known key found for this signature in database
GPG Key ID: 5F18E708A82A48A0
1 changed files with 34 additions and 5 deletions

View File

@ -28,7 +28,7 @@ the NAND or bootloader happens.
Use cases Use cases
~~~~~~~~ ~~~~~~~~~
In fact, most users do not need it. Either way, possible use cases: In fact, most users do not need it. Either way, possible use cases:
-Changing typos in bootscripts which prevent an operation system -Changing typos in bootscripts which prevent an operation system
@ -48,11 +48,12 @@ In fact, most users do not need it. Either way, possible use cases:
-and more... -and more...
Booting rescueOS
~~~~~~~~~~~~~~~ Booting rescueOS with flasher
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Note: You can not store persistent data in /. Of Note: You can not store persistent data in /. Of
course, it becomes possible on the mount points you mount the EMMC or sd card course, it becomes possible on the mount points you mount the EMMC or sd card
to. to.
Note: It comes without any promises and without any warranty. Therefore you Note: It comes without any promises and without any warranty. Therefore you
are doing everything at your own risk. are doing everything at your own risk.
@ -93,6 +94,34 @@ should block and wait. Now connect the N900 to the PC with the data cable; the
flasher should detect the device, upload rescueOS, launch it, and then exit. flasher should detect the device, upload rescueOS, launch it, and then exit.
Booting rescueOS with U-Boot from SD card
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Use this method if you have installed U-Boot (https://talk.maemo.org/showthread.php?t=81613)
and battery is so depleted, that flashing doesn't work.
You'll need "mkimage" command from "u-boot-tools" package.
Preparing required files:
mkimage -A arm -O linux -T kernel -C none -a 80008000 -e 80008000 -n kernel -d rescueOS_n900_kernel_1.3.zImage rescueOS_n900_kernel_1.3.uImage
mkimage -A arm -O linux -T ramdisk -C none -a 0 -e 0 -n initrd -d rescueOS-1.3.img rescueOS-1.3.uimg
cat >boot.cmd <<EOF
setenv bootargs rootdelay root=/dev/ram0;
setenv setup_omap_atag 1;
setenv mmckernfile rescueOS_n900_kernel_1.3.uImage;
setenv mmcinitrdfile rescueOS-1.3.uimg;
setenv mmcscriptfile;
run trymmckerninitrdboot;
EOF
mkimage -c none -A arm -T script -d boot.cmd boot.scr
Preparing SD card:
Your SD card needs to have the first partition formatted as ext2/3/4 or FAT.
Put generated files (without boot.cmd) in the root directory.
Now you should be able to boot rescueOS with generic "External SD card" option from U-Boot.
~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~
How to use it How to use it
~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~
@ -115,7 +144,7 @@ code_reset
# This will set the lock code back to the default ('12345'). # This will set the lock code back to the default ('12345').
USB Networking USB Networking
------------- --------------
/rescueOS/usbnetworking-enable.sh /rescueOS/usbnetworking-enable.sh
Sets up USB networking in the following way: Sets up USB networking in the following way:
ifconfig usb0 192.168.2.15 up ifconfig usb0 192.168.2.15 up