int board_mmc_init(bd_t *bis) { cm_fx6_set_usdhc_iomux(); usdhc_cfg.sdhc_clk = mxc_get_clock(MXC_ESDHC3_CLK); return fsl_esdhc_initialize(bis, &usdhc_cfg); }
int board_mmc_init(bd_t *bis) { int i; cm_fx6_set_usdhc_iomux(); for (i = 0; i < CONFIG_SYS_FSL_USDHC_NUM; i++) { usdhc_cfg[i].sdhc_clk = mxc_get_clock(usdhc_clk[i]); usdhc_cfg[i].max_bus_width = 4; fsl_esdhc_initialize(bis, &usdhc_cfg[i]); enable_usdhc_clk(1, i); } return 0; }
int board_init(void) { int ret; gd->bd->bi_boot_params = PHYS_SDRAM_1 + 0x100; cm_fx6_setup_gpmi_nand(); ret = cm_fx6_setup_ecspi(); if (ret) printf("Warning: ECSPI setup failed: %d\n", ret); ret = cm_fx6_setup_usb_otg(); if (ret) printf("Warning: USB OTG setup failed: %d\n", ret); ret = cm_fx6_setup_usb_host(); if (ret) printf("Warning: USB host setup failed: %d\n", ret); /* * cm-fx6 may have iSSD not assembled and in this case it has * bypasses for a (m)SATA socket on the baseboard. The socketed * device is not controlled by those GPIOs. So just print a warning * if the setup fails. */ ret = cm_fx6_setup_issd(); if (ret) printf("Warning: iSSD setup failed: %d\n", ret); /* Warn on failure but do not abort boot */ ret = cm_fx6_setup_i2c(); if (ret) printf("Warning: I2C setup failed: %d\n", ret); cm_fx6_setup_display(); /* This should be done in the MMC driver when MX6 has a clock driver */ #ifdef CONFIG_FSL_ESDHC if (IS_ENABLED(CONFIG_BLK)) { int i; cm_fx6_set_usdhc_iomux(); for (i = 0; i < CONFIG_SYS_FSL_USDHC_NUM; i++) enable_usdhc_clk(1, i); } #endif return 0; }