diff options
| author | Tom Rini <[email protected]> | 2025-10-26 07:51:18 -0600 |
|---|---|---|
| committer | Tom Rini <[email protected]> | 2025-10-26 09:03:36 -0600 |
| commit | 9094482ca7576877b2bfaa57c8e73cfeb536f8b9 (patch) | |
| tree | a7ab2b7409802fe0dd3b2e36ecad3960c4b52004 /doc/usage/cmd/write.rst | |
| parent | fd976ff3a233ae7c6a9f5bec790b02bbbf57bb24 (diff) | |
| parent | 5335f8d25b2f39b9dd954981364f3cddde01895f (diff) | |
Merge tag 'efi-2026-01-rc1-2' of https://source.denx.de/u-boot/custodians/u-boot-efi
Pull request efi-2026-01-rc1-2
CI:
* https://source.denx.de/u-boot/custodians/u-boot-efi/-/pipelines/28024
Documentation:
* develop: virtio: Fix qemu example (true/false -> on/off)
* separate read and write command documentation
* usage: Add general rule for `$?`
* askenv: Reword and remove return value
* seama: Reword return value section
* usage: Use glob for all commands
* Fix typos and formatting
UEFI:
* console: support editable input fields
Diffstat (limited to 'doc/usage/cmd/write.rst')
| -rw-r--r-- | doc/usage/cmd/write.rst | 41 |
1 files changed, 39 insertions, 2 deletions
diff --git a/doc/usage/cmd/write.rst b/doc/usage/cmd/write.rst index f42dc003dd4..737eb28c069 100644 --- a/doc/usage/cmd/write.rst +++ b/doc/usage/cmd/write.rst @@ -1,4 +1,4 @@ -.. SPDX-License-Identifier: GPL-2.0-or-later: +.. SPDX-License-Identifier: GPL-2.0-or-later .. index:: single: write (command) @@ -6,4 +6,41 @@ write command ============= -See :doc:`read`. +Synopsis +-------- + +:: + + write <interface> <dev[:part|#partname]> <addr> <blk#> <cnt> + +Description +----------- + +The write command can be used for raw writing data to a block device +(or partition therein), i.e. without going through a file system. + +The block device is specified using the <interface> (e.g. "mmc") and +<dev> parameters. If the block device has a partition table, one can +optionally specify a partition number (using the :part syntax) or +partition name (using the #partname syntax). The command then reads +the <cnt> blocks of data starting at block number <blk#> of the given +device/partition to the memory address <addr>. + +Examples +-------- + +.. code-block:: bash + + # Write to the third sector of the partition named 'bootdata' of mmc device 0 + write mmc 0#bootdata $loadaddr 2 1 + +Configuration +------------- + +The write command is only available if CONFIG_CMD_WRITE=y. + +Return value +------------ + +The command sets the return value $? to 0 (true) on success and to 1 (false) in +case of an error. |
