> +static void > +renesas_sdhi_internal_dmac_init_card(struct tmio_mmc_host *host, > + struct mmc_card *card) > +{ > + if (host->pdev->dev.iommu_group && > + (mmc_card_mmc(card) || mmc_card_sd(card))) > + host->mmc->max_segs = 512; > + else > + host->mmc->max_segs = host->pdata->max_segs; > +} > + Will this work with Gen2 as well if we explicitly set max_segs in of_rcar_gen2_compatible (renesas_sdhi_sys_dmac.c)? Then we could simply move the above chunk to renesas_sdhi_core.c and use this minimal diff. --- a/drivers/mmc/host/renesas_sdhi_core.c +++ b/drivers/mmc/host/renesas_sdhi_core.c @@ -726,6 +726,8 @@ int renesas_sdhi_probe(struct platform_device *pdev, /* SDR speeds are only available on Gen2+ */ if (mmc_data->flags & TMIO_MMC_MIN_RCAR2) { + host->ops.init_card = renesas_sdhi_init_card; + /* card_busy caused issues on r8a73a4 (pre-Gen2) CD-less SDHI */ host->ops.card_busy = renesas_sdhi_card_busy; host->ops.start_signal_voltage_switch = What do you think, Shimoda-san? Otherwise, we probably need to keep the init_card in the dma_ops struct and could do something like + host->ops.init_card = dma_ops->init_card; ? Need to think about the latter a bit more, though.
Attachment:
signature.asc
Description: PGP signature