diff options
Diffstat (limited to 'doc')
-rw-r--r-- | doc/README.dfu | 30 | ||||
-rw-r--r-- | doc/arch/sandbox.rst | 35 |
2 files changed, 50 insertions, 15 deletions
diff --git a/doc/README.dfu b/doc/README.dfu index be53b5b393..eacd5bbfb4 100644 --- a/doc/README.dfu +++ b/doc/README.dfu @@ -17,7 +17,7 @@ Overview: - The access to mediums is done in DFU backends (driver/dfu) Today the supported DFU backends are: - - MMC (RAW or FAT / EXT2 / EXT3 / EXT4 file system) + - MMC (RAW or FAT / EXT2 / EXT3 / EXT4 file system / SKIP / SCRIPT) - NAND - RAM - SF (serial flash) @@ -91,6 +91,8 @@ Commands: <name> part <dev> <part_id> [mmcpart <num>] raw access to partition <name> fat <dev> <part_id> [mmcpart <num>] file in FAT partition <name> ext4 <dev> <part_id> [mmcpart <num>] file in EXT4 partition + <name> skip 0 0 ignore flashed data + <name> script 0 0 execute commands in shell with <partid> being the GPT or DOS partition index, with <num> being the eMMC hardware partition number. @@ -103,6 +105,32 @@ Commands: "u-boot raw 0x80 0x800;uImage ext4 0 2" + If don't want to flash given image file to storage, use "skip" type + entity. + - It can be used to protect flashing wrong image for the specific board. + - Especailly, this layout will be useful when thor protocol is used, + which performs flashing in batch mode, where more than one file is + processed. + For example, if one makes a single tar file with support for the two + boards with u-boot-<board1>.bin and u-boot-<board2>.bin files, one + can use it to flash a proper u-boot image on both without a failure: + + "u-boot-<board1>.bin raw 0x80 0x800; u-boot-<board2>.bin skip 0 0" + + When flashing new system image requires do some more complex things + than just writing data to the storage medium, one can use 'script' + type. Data written to such entity will be executed as a command list + in the u-boot's shell. This for example allows to re-create partition + layout and even set new dfu_alt_info for the newly created paritions. + Such script would look like: + --->8--- + setenv dfu_alt_info ... + setenv mbr_parts ... + mbr write ... + --->8--- + Please note that this means that user will be able to execute any + arbitrary commands just like in the u-boot's shell. + "nand" (raw slc nand device) cmd: dfu 0 nand <dev> each element in "dfu_alt_info" = diff --git a/doc/arch/sandbox.rst b/doc/arch/sandbox.rst index 4674c420ac..60ee1e0741 100644 --- a/doc/arch/sandbox.rst +++ b/doc/arch/sandbox.rst @@ -99,37 +99,44 @@ Command-line Options Various options are available, mostly for test purposes. Use -h to see available options. Some of these are described below: -* -t, --terminal <arg> - - The terminal is normally in what is called 'raw-with-sigs' mode. This means +-t, --terminal <arg> + The terminal is normally in what is called 'raw-with-sigs' mode. This means that you can use arrow keys for command editing and history, but if you press Ctrl-C, U-Boot will exit instead of handling this as a keypress. Other options are 'raw' (so Ctrl-C is handled within U-Boot) and 'cooked' (where the terminal is in cooked mode and cursor keys will not work, Ctrl-C will exit). -* -l - - Show the LCD emulation window. +-l + Show the LCD emulation window. -* -d <device_tree> - - A device tree binary file can be provided with -d. If you edit the source +-d <device_tree> + A device tree binary file can be provided with -d. If you edit the source (it is stored at arch/sandbox/dts/sandbox.dts) you must rebuild U-Boot to recreate the binary file. -* -D - - To use the default device tree, use -D. +-D + To use the default device tree, use -D. -* -T - - To use the test device tree, use -T. +-T + To use the test device tree, use -T. -* -c [<cmd>;]<cmd> - - To execute commands directly, use the -c option. You can specify a single +-c [<cmd>;]<cmd> + To execute commands directly, use the -c option. You can specify a single command, or multiple commands separated by a semicolon, as is normal in U-Boot. Be careful with quoting as the shell will normally process and swallow quotes. When -c is used, U-Boot exits after the command is complete, but you can force it to go to interactive mode instead with -i. -* -i - - Go to interactive mode after executing the commands specified by -c. +-i + Go to interactive mode after executing the commands specified by -c. + +Environment Variables +--------------------- + +UBOOT_SB_TIME_OFFSET + This environment variable stores the offset of the emulated real time clock + to the host's real time clock in seconds. The offset defaults to zero. Memory Emulation ---------------- |