aboutsummaryrefslogtreecommitdiff
path: root/cmd/i2c.c
diff options
context:
space:
mode:
Diffstat (limited to 'cmd/i2c.c')
-rw-r--r--cmd/i2c.c20
1 files changed, 2 insertions, 18 deletions
diff --git a/cmd/i2c.c b/cmd/i2c.c
index dd803ee227..80831561c6 100644
--- a/cmd/i2c.c
+++ b/cmd/i2c.c
@@ -1939,16 +1939,6 @@ static struct cmd_tbl cmd_i2c_sub[] = {
U_BOOT_CMD_MKENT(speed, 1, 1, do_i2c_bus_speed, "", ""),
};
-static __maybe_unused void i2c_reloc(void)
-{
- static int relocated;
-
- if (!relocated) {
- fixup_cmdtable(cmd_i2c_sub, ARRAY_SIZE(cmd_i2c_sub));
- relocated = 1;
- };
-}
-
/**
* do_i2c() - Handle the "i2c" command-line command
* @cmdtp: Command data struct pointer
@@ -1963,10 +1953,6 @@ static int do_i2c(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[])
{
struct cmd_tbl *c;
-#ifdef CONFIG_NEEDS_MANUAL_RELOC
- i2c_reloc();
-#endif
-
if (argc < 2)
return CMD_RET_USAGE;
@@ -1983,8 +1969,7 @@ static int do_i2c(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[])
}
/***************************************************/
-#ifdef CONFIG_SYS_LONGHELP
-static char i2c_help_text[] =
+U_BOOT_LONGHELP(i2c,
#if CONFIG_IS_ENABLED(SYS_I2C_LEGACY) || CONFIG_IS_ENABLED(DM_I2C)
"bus [muxtype:muxaddr:muxchannel] - show I2C bus info\n"
"i2c " /* That's the prefix for the crc32 command below. */
@@ -2013,8 +1998,7 @@ static char i2c_help_text[] =
#if defined(CONFIG_CMD_SDRAM)
"i2c sdram chip - print SDRAM configuration information\n"
#endif
- "i2c speed [speed] - show or set I2C bus speed";
-#endif
+ "i2c speed [speed] - show or set I2C bus speed");
U_BOOT_CMD(
i2c, 7, 1, do_i2c,