Lines Matching refs:mmc
59 struct mmc_host *mmc; member
121 dev_dbg(mmc_dev(host->mmc), "%s enter flags: 0x%x\n", __func__, data->flags); in sdh_setup_data()
158 host->dma_len = dma_map_sg(mmc_dev(host->mmc), data->sg, data->sg_len, host->dma_dir); in sdh_setup_data()
174 dev_dbg(mmc_dev(host->mmc), "%d: start_addr:0x%lx, " in sdh_setup_data()
206 dev_dbg(mmc_dev(host->mmc), "%s exit\n", __func__); in sdh_setup_data()
215 dev_dbg(mmc_dev(host->mmc), "%s enter cmd: 0x%p\n", __func__, cmd); in sdh_start_cmd()
246 dev_dbg(mmc_dev(host->mmc), "%s enter\n", __func__); in sdh_finish_request()
250 mmc_request_done(host->mmc, mrq); in sdh_finish_request()
258 dev_dbg(mmc_dev(host->mmc), "%s enter cmd: %p\n", __func__, cmd); in sdh_cmd_done()
297 dev_dbg(mmc_dev(host->mmc), "%s enter stat: 0x%x\n", __func__, stat); in sdh_data_done()
302 dma_unmap_sg(mmc_dev(host->mmc), data->sg, data->sg_len, in sdh_data_done()
333 static void sdh_request(struct mmc_host *mmc, struct mmc_request *mrq) in sdh_request() argument
335 struct sdh_host *host = mmc_priv(mmc); in sdh_request()
338 dev_dbg(mmc_dev(host->mmc), "%s enter, mrp:%p, cmd:%p\n", __func__, mrq, mrq->cmd); in sdh_request()
356 static void sdh_set_ios(struct mmc_host *mmc, struct mmc_ios *ios) in sdh_set_ios() argument
364 host = mmc_priv(mmc); in sdh_set_ios()
450 dev_dbg(mmc_dev(host->mmc), "SDH: clk_div = 0x%x actual clock:%ld expected clock:%d\n", in sdh_set_ios()
465 dev_dbg(mmc_dev(host->mmc), "%s enter, irq_stat: 0x%04lx\n", __func__, in sdh_dma_irq()
479 dev_dbg(mmc_dev(host->mmc), "%s enter\n", __func__); in sdh_stat_irq()
485 mmc_detect_change(host->mmc, 0); in sdh_stat_irq()
502 dev_dbg(mmc_dev(host->mmc), "%s exit\n\n", __func__); in sdh_stat_irq()
526 struct mmc_host *mmc; in sdh_probe() local
537 mmc = mmc_alloc_host(sizeof(struct sdh_host), &pdev->dev); in sdh_probe()
538 if (!mmc) { in sdh_probe()
543 mmc->ops = &sdh_ops; in sdh_probe()
545 mmc->max_segs = 1; in sdh_probe()
547 mmc->max_segs = PAGE_SIZE / sizeof(struct dma_desc_array); in sdh_probe()
550 mmc->max_seg_size = -1; in sdh_probe()
552 mmc->max_seg_size = 1 << 16; in sdh_probe()
554 mmc->max_blk_size = 1 << 11; in sdh_probe()
555 mmc->max_blk_count = 1 << 11; in sdh_probe()
556 mmc->max_req_size = PAGE_SIZE; in sdh_probe()
557 mmc->ocr_avail = MMC_VDD_32_33 | MMC_VDD_33_34; in sdh_probe()
558 mmc->f_max = get_sclk(); in sdh_probe()
559 mmc->f_min = mmc->f_max >> 9; in sdh_probe()
560 mmc->caps = MMC_CAP_4_BIT_DATA | MMC_CAP_NEEDS_POLL; in sdh_probe()
561 host = mmc_priv(mmc); in sdh_probe()
562 host->mmc = mmc; in sdh_probe()
587 platform_set_drvdata(pdev, mmc); in sdh_probe()
603 mmc_add_host(mmc); in sdh_probe()
609 mmc_remove_host(mmc); in sdh_probe()
614 mmc_free_host(mmc); in sdh_probe()
621 struct mmc_host *mmc = platform_get_drvdata(pdev); in sdh_remove() local
623 if (mmc) { in sdh_remove()
624 struct sdh_host *host = mmc_priv(mmc); in sdh_remove()
626 mmc_remove_host(mmc); in sdh_remove()
633 mmc_free_host(mmc); in sdh_remove()