Commit 19f8c4dfb6e744a31da59bdd23b24d144152f1dc
Committed by
Heiko Schocher
1 parent
40ecdbc648
Exists in
smarc_8mq_lf_v2020.04
and in
11 other branches
cmd: i2c: Fix help output of i2c command.
In case SYS_I2C or DM_I2C are defined, then the "i2c " prefix of the "i2c crc32" command is missing. This patch addresses this, so that users can't get confused by the "crc32" command. Without the patch we get => i2c help i2c - I2C sub-system Usage: i2c bus [muxtype:muxaddr:muxchannel] - show I2C bus info crc32 chip address[.0, .1, .2] count - compute CRC32 checksum i2c dev [dev] - show or set current I2C bus [...] With the patch we get => i2c help i2c - I2C sub-system Usage: i2c bus [muxtype:muxaddr:muxchannel] - show I2C bus info i2c crc32 chip address[.0, .1, .2] count - compute CRC32 checksum i2c dev [dev] - show or set current I2C bus ... Signed-off-by: Christoph Muellner <christoph.muellner@theobroma-systems.com> Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com> Reviewed-by: Heiko Schocher <hs@denx.de>
Showing 1 changed file with 1 additions and 0 deletions Side-by-side Diff
cmd/i2c.c
... | ... | @@ -2023,6 +2023,7 @@ |
2023 | 2023 | static char i2c_help_text[] = |
2024 | 2024 | #if defined(CONFIG_SYS_I2C) || defined(CONFIG_DM_I2C) |
2025 | 2025 | "bus [muxtype:muxaddr:muxchannel] - show I2C bus info\n" |
2026 | + "i2c " /* That's the prefix for the crc32 command below. */ | |
2026 | 2027 | #endif |
2027 | 2028 | "crc32 chip address[.0, .1, .2] count - compute CRC32 checksum\n" |
2028 | 2029 | #if defined(CONFIG_SYS_I2C) || \ |