summaryrefslogtreecommitdiff
path: root/board/freescale/mx6qarm2/mx6qarm2.c
diff options
context:
space:
mode:
authorStefano Babic <sbabic@denx.de>2012-01-17 12:15:00 +0100
committerAlbert ARIBAUD <albert.u.boot@aribaud.net>2012-02-12 10:11:26 +0100
commitb125e7bdd819024d1fb59b54349202190fcadd37 (patch)
treec7b69da09e9282569f30a86373998c66599df806 /board/freescale/mx6qarm2/mx6qarm2.c
parentdb917fbfed5ab26d0b86d567a9729ed14c26cc99 (diff)
downloadu-boot-imx-b125e7bdd819024d1fb59b54349202190fcadd37.zip
u-boot-imx-b125e7bdd819024d1fb59b54349202190fcadd37.tar.gz
u-boot-imx-b125e7bdd819024d1fb59b54349202190fcadd37.tar.bz2
imx6: mx6qarm2: updated board_mmc_getcd() to the new prototype
Commit 314284b1567f1ce29c19060641e7f213146f7ab8 has changed board_mmc_getcd() function prototype, while mx6qarm2 has still the old one. Signed-off-by: Stefano Babic <sbabic@denx.de> CC: Jason Liu <jason.hui@linaro.org> Acked-by: Dirk Behme <dirk.behme@de.bosch.com> Acked-by: Jason Liu <jason.hui@linaro.org> Tested-by: Jason Liu <jason.hui@linaro.org>
Diffstat (limited to 'board/freescale/mx6qarm2/mx6qarm2.c')
-rw-r--r--board/freescale/mx6qarm2/mx6qarm2.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/board/freescale/mx6qarm2/mx6qarm2.c b/board/freescale/mx6qarm2/mx6qarm2.c
index 9894245..1367b88 100644
--- a/board/freescale/mx6qarm2/mx6qarm2.c
+++ b/board/freescale/mx6qarm2/mx6qarm2.c
@@ -120,17 +120,18 @@ struct fsl_esdhc_cfg usdhc_cfg[2] = {
{USDHC4_BASE_ADDR, 1},
};
-int board_mmc_getcd(u8 *cd, struct mmc *mmc)
+int board_mmc_getcd(struct mmc *mmc)
{
struct fsl_esdhc_cfg *cfg = (struct fsl_esdhc_cfg *)mmc->priv;
+ int ret;
if (cfg->esdhc_base == USDHC3_BASE_ADDR) {
gpio_direction_input(171); /*GPIO6_11*/
- *cd = gpio_get_value(171);
+ ret = !gpio_get_value(171);
} else /* Don't have the CD GPIO pin on board */
- *cd = 0;
+ ret = 1;
- return 0;
+ return ret;
}
int board_mmc_init(bd_t *bis)