mirror of
https://github.com/AsahiLinux/u-boot
synced 2025-02-18 06:58:54 +00:00
imx6: mx6qarm2: updated board_mmc_getcd() to the new prototype
Commit 314284b156
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>
This commit is contained in:
parent
db917fbfed
commit
b125e7bdd8
1 changed files with 5 additions and 4 deletions
|
@ -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)
|
||||
|
|
Loading…
Add table
Reference in a new issue