Lines Matching refs:plat
86 static int sdhci_cdns_write_phy_reg(struct sdhci_cdns_plat *plat, in sdhci_cdns_write_phy_reg() argument
89 void __iomem *reg = plat->hrs_addr + SDHCI_CDNS_HRS04; in sdhci_cdns_write_phy_reg()
110 static int sdhci_cdns_phy_init(struct sdhci_cdns_plat *plat, in sdhci_cdns_phy_init() argument
122 ret = sdhci_cdns_write_phy_reg(plat, in sdhci_cdns_phy_init()
135 struct sdhci_cdns_plat *plat = dev_get_platdata(mmc->dev); in sdhci_cdns_set_control_reg() local
158 tmp = readl(plat->hrs_addr + SDHCI_CDNS_HRS06); in sdhci_cdns_set_control_reg()
161 writel(tmp, plat->hrs_addr + SDHCI_CDNS_HRS06); in sdhci_cdns_set_control_reg()
168 static int sdhci_cdns_set_tune_val(struct sdhci_cdns_plat *plat, in sdhci_cdns_set_tune_val() argument
171 void __iomem *reg = plat->hrs_addr + SDHCI_CDNS_HRS06; in sdhci_cdns_set_tune_val()
190 struct sdhci_cdns_plat *plat = dev_get_platdata(dev); in sdhci_cdns_execute_tuning() local
191 struct mmc *mmc = &plat->mmc; in sdhci_cdns_execute_tuning()
209 if (sdhci_cdns_set_tune_val(plat, i) || in sdhci_cdns_execute_tuning()
226 return sdhci_cdns_set_tune_val(plat, end_of_streak - max_streak / 2); in sdhci_cdns_execute_tuning()
233 struct sdhci_cdns_plat *plat = dev_get_platdata(dev); in sdhci_cdns_bind() local
235 return sdhci_bind(dev, &plat->mmc, &plat->cfg); in sdhci_cdns_bind()
242 struct sdhci_cdns_plat *plat = dev_get_platdata(dev); in sdhci_cdns_probe() local
251 plat->hrs_addr = devm_ioremap(dev, base, SZ_1K); in sdhci_cdns_probe()
252 if (!plat->hrs_addr) in sdhci_cdns_probe()
256 host->ioaddr = plat->hrs_addr + SDHCI_CDNS_SRS_BASE; in sdhci_cdns_probe()
264 ret = mmc_of_parse(dev, &plat->cfg); in sdhci_cdns_probe()
268 ret = sdhci_cdns_phy_init(plat, gd->fdt_blob, dev_of_offset(dev)); in sdhci_cdns_probe()
272 ret = sdhci_setup_cfg(&plat->cfg, host, 0, 0); in sdhci_cdns_probe()
276 upriv->mmc = &plat->mmc; in sdhci_cdns_probe()
277 host->mmc = &plat->mmc; in sdhci_cdns_probe()