diff options
author | Tom Rini <trini@ti.com> | 2014-10-26 14:03:08 -0400 |
---|---|---|
committer | Tom Rini <trini@ti.com> | 2014-10-26 14:03:08 -0400 |
commit | 84a6df09c78bc9e9cbc6265d99c9097f5f1079f2 (patch) | |
tree | 3b2bf1b3689e9aad0d20f5a69ada168cae3cc769 /drivers/mmc | |
parent | c69ecd9722af22d50295eff81d0b9cd5b8adc2e0 (diff) | |
parent | c2ded962d4703a3f9522553004db4a6fe540f7e6 (diff) | |
download | u-boot-imx-84a6df09c78bc9e9cbc6265d99c9097f5f1079f2.zip u-boot-imx-84a6df09c78bc9e9cbc6265d99c9097f5f1079f2.tar.gz u-boot-imx-84a6df09c78bc9e9cbc6265d99c9097f5f1079f2.tar.bz2 |
Merge git://git.denx.de/u-boot-dm
Fix a trivial conflict over adding <dm.h>
Conflicts:
arch/arm/cpu/armv7/omap3/board.c
Signed-off-by: Tom Rini <trini@ti.com>
Diffstat (limited to 'drivers/mmc')
-rw-r--r-- | drivers/mmc/omap_hsmmc.c | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/drivers/mmc/omap_hsmmc.c b/drivers/mmc/omap_hsmmc.c index 5b0c302..ef2cbf9 100644 --- a/drivers/mmc/omap_hsmmc.c +++ b/drivers/mmc/omap_hsmmc.c @@ -67,14 +67,19 @@ static int mmc_write_data(struct hsmmc *mmc_base, const char *buf, #ifdef OMAP_HSMMC_USE_GPIO static int omap_mmc_setup_gpio_in(int gpio, const char *label) { - if (!gpio_is_valid(gpio)) - return -1; + int ret; - if (gpio_request(gpio, label) < 0) +#ifndef CONFIG_DM_GPIO + if (!gpio_is_valid(gpio)) return -1; +#endif + ret = gpio_request(gpio, label); + if (ret) + return ret; - if (gpio_direction_input(gpio) < 0) - return -1; + ret = gpio_direction_input(gpio); + if (ret) + return ret; return gpio; } |