Re: [PATCH] mmc: tegra: Add and use tegra_sdhci_get_max_clock()
From: Jon Hunter
Date: Mon Jul 16 2018 - 15:47:19 EST
On 13/07/18 16:39, Aapo Vienamo wrote:
...
>>> that it returns the current clock rate of the host instead of the
>>> maximum one, which can lead to unnecessarily small clock rates.
>>>
>>> This differs from the previous implementation of
>>> tegra_sdhci_get_max_clock() in that it doesn't divide the result by two.
>>
>> Why?
>
> As far as I can tell the original tegra_sdhci_get_max_clock() was
> implemented this way in order to force sdhci_calc_clk() to always set
> the SDHCI clock divider to two on sdhci_set_clock(). The requirement to
> configure the SDHCI divider to two is specific to DDR50/52 modes on
> Tegra.
>
> The .get_max_clock() callback retuning half of the actual maximum will
> result in HS200 and HS400 modes not being able to run at full speed.
> Another mechanism to enforce the divider requirement has to be figured
> out in order to enable DDR50/52 modes on Tegra SoCs.
OK, thanks. Ah I see Stefan's patch for doubling the clock. OK so that's fine.
Cheers
Jon
--
nvpublic