1 /* SPDX-License-Identifier: GPL-2.0-only */
3 #include <commonlib/sdhci.h>
4 #include <commonlib/storage.h>
5 #include <commonlib/storage/sd_mmc.h>
6 #include <commonlib/storage/sdhci.h>
7 #include <commonlib/sd_mmc_ctrlr.h>
8 #include <soc/addressmap.h>
10 #include <soc/sdhci_msm.h>
12 int qc_emmc_early_init(void)
14 struct sd_mmc_ctrlr
*ctrlr
;
15 struct storage_media media
= {0};
17 ctrlr
= new_sdhci_msm_host((void *)(uintptr_t)SDC1_HC_BASE
);
22 SET_BUS_WIDTH(ctrlr
, 1);
23 SET_CLOCK(ctrlr
, 384 * 1000);
26 return mmc_send_cmd1(&media
);