Re: [PATCH v3 3/4] mmc: sh_mobile_sdhi: Add tuning support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Simon,

On Tue, May 24, 2016 at 4:43 AM, Simon Horman
<horms+renesas@xxxxxxxxxxxx> wrote:
> --- a/drivers/mmc/host/sh_mobile_sdhi.c
> +++ b/drivers/mmc/host/sh_mobile_sdhi.c

> @@ -403,6 +580,30 @@ static int sh_mobile_sdhi_probe(struct platform_device *pdev)
>         if (ret < 0)
>                 goto efree;
>
> +       if (host->mmc->caps & MMC_CAP_UHS_SDR104)
> +               host->mmc->caps |= MMC_CAP_HW_RESET;
> +
> +       if (of_id && of_id->data) {
> +               const struct sh_mobile_sdhi_of_data *of_data = of_id->data;
> +               const struct sh_mobile_sdhi_scc *taps = of_data->taps;
> +               bool hit = false;
> +
> +               for (i = 0; i < of_data->taps_num; i++) {
> +                       if (taps[i].clk_rate == 0 ||
> +                           taps[i].clk_rate == host->mmc->f_max) {
> +                               host->scc_tappos = taps->tap;
> +                               hit = true;
> +                               break;
> +                       }
> +               }
> +
> +               if (!hit)
> +                       dev_warn(&host->pdev->dev, "Unknown clock rate for SDR104 and HS200\n");

This warning triggers on sh7a0/kzm9g, r8a73a4/ape6evm, and
r8a7740/armadillo.

Perhaps the tap code should check if MMC_CAP_UHS_SDR104 is
enabled?

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@xxxxxxxxxxxxxx

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds
--
To unsubscribe from this list: send the line "unsubscribe linux-mmc" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux