]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
cmd: eeprom: Fix usage help for the eeprom command
authorMarek Behún <kabel@kernel.org>
Tue, 21 May 2024 07:13:29 +0000 (09:13 +0200)
committerTom Rini <trini@konsulko.com>
Fri, 7 Jun 2024 16:47:59 +0000 (10:47 -0600)
The bus and devaddr arguments of the eeprom command are optional, and if
only one is given, it is assumed to be devaddr. Change the usage help
from
  <bus> <devaddr>
to
  [[bus] [devaddr]

Signed-off-by: Marek Behún <kabel@kernel.org>
cmd/eeprom.c

index 322765ad02a013b1c5dff318f1f4285207f9714a..0d604832e445cdac998442eb49093b6484a8fb06 100644 (file)
@@ -418,14 +418,14 @@ int do_eeprom(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[])
 U_BOOT_CMD(
        eeprom, 8,      1,      do_eeprom,
        "EEPROM sub-system",
-       "read  <bus> <devaddr> addr off cnt\n"
-       "eeprom write <bus> <devaddr> addr off cnt\n"
+       "read  [[bus] devaddr] addr off cnt\n"
+       "eeprom write [[bus] devaddr] addr off cnt\n"
        "       - read/write `cnt' bytes from `devaddr` EEPROM at offset `off'"
 #ifdef CONFIG_CMD_EEPROM_LAYOUT
        "\n"
-       "eeprom print [-l <layout_version>] <bus> <devaddr>\n"
+       "eeprom print [-l <layout_version>] [[bus] devaddr]\n"
        "       - Print layout fields and their data in human readable format\n"
-       "eeprom update [-l <layout_version>] <bus> <devaddr> field_name field_value\n"
+       "eeprom update [-l <layout_version>] [[bus] devaddr] field_name field_value\n"
        "       - Update a specific eeprom field with new data.\n"
        "         The new data must be written in the same human readable format as shown by the print command.\n"
        "\n"