提交 58aef72d 编写于 作者: F Fabio Estevam 提交者: Albert ARIBAUD

mx51evk: Configure the pins as GPIOs prior to using gpio_get_value

Configure the pins as GPIO prior to using gpio_get_value.
Signed-off-by: NFabio Estevam <fabio.estevam@freescale.com>
上级 3ee3729e
......@@ -265,6 +265,9 @@ int board_mmc_getcd(u8 *cd, struct mmc *mmc)
{
struct fsl_esdhc_cfg *cfg = (struct fsl_esdhc_cfg *)mmc->priv;
mxc_request_iomux(MX51_PIN_GPIO1_0, IOMUX_CONFIG_ALT1);
mxc_request_iomux(MX51_PIN_GPIO1_6, IOMUX_CONFIG_ALT0);
if (cfg->esdhc_base == MMC_SDHC1_BASE_ADDR)
*cd = gpio_get_value(0);
else
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册