summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2018-01-03 09:24:24 -0500
committerTom Rini <trini@konsulko.com>2018-01-19 15:49:29 -0500
commitbb2277b3ee163de41f3e6f41bec24624f7f41f80 (patch)
treea739356e31cb8b15d9ff254e2761b08aaaa1cc91
parent0d097b774d5a3470bea32bc702c45bd843cd9378 (diff)
GPIO: tca642x: Rework to not include commands in SPL
The command portion of the GPIO driver can only be used in full SPL so re-work to guard the command related portions and mark it as static. Cc: Dan Murphy <dmurphy@ti.com> Signed-off-by: Tom Rini <trini@konsulko.com>
-rw-r--r--drivers/gpio/tca642x.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/gpio/tca642x.c b/drivers/gpio/tca642x.c
index 6386835d5d..730460a999 100644
--- a/drivers/gpio/tca642x.c
+++ b/drivers/gpio/tca642x.c
@@ -163,7 +163,7 @@ int tca642x_set_inital_state(uchar chip, struct tca642x_bank_info init_data[])
return ret;
}
-#ifdef CONFIG_CMD_TCA642X
+#if defined(CONFIG_CMD_TCA642X) && !defined(CONFIG_SPL_BUILD)
/*
* Display tca642x information
*/
@@ -212,7 +212,7 @@ static int tca642x_info(uchar chip)
return 0;
}
-cmd_tbl_t cmd_tca642x[] = {
+static cmd_tbl_t cmd_tca642x[] = {
U_BOOT_CMD_MKENT(device, 3, 0, (void *)TCA642X_CMD_DEVICE, "", ""),
U_BOOT_CMD_MKENT(output, 4, 0, (void *)TCA642X_CMD_OUTPUT, "", ""),
U_BOOT_CMD_MKENT(input, 3, 0, (void *)TCA642X_CMD_INPUT, "", ""),
@@ -220,7 +220,7 @@ cmd_tbl_t cmd_tca642x[] = {
U_BOOT_CMD_MKENT(info, 2, 0, (void *)TCA642X_CMD_INFO, "", ""),
};
-int do_tca642x(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
+static int do_tca642x(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
{
static uchar chip = CONFIG_SYS_I2C_TCA642X_ADDR;
int ret = CMD_RET_USAGE, val;