[U-Boot] [PATCH v2 09/20] tegra: Add EMC support for optimal memory timings

Simon Glass sjg at chromium.org
Fri Jan 20 00:59:37 CET 2012


Hi Stephen,

On Thu, Jan 19, 2012 at 1:58 PM, Stephen Warren <swarren at nvidia.com> wrote:
> On 01/13/2012 02:35 PM, Simon Glass wrote:
>> From: Jimmy Zhang <jimmzhang at nvidia.com>
>>
>> Add support for setting up the memory controller parameters. Boards
>> can set up an appropriate table in the device tree.
>>
>> Signed-off-by: Simon Glass <sjg at chromium.org>
>> ---
>> Changes in v2:
>> - Add debug() output to EMC
>> - Move EMC tables to device tree
>
> This patch doesn't fully handle the device tree binding. There are two
> alternatives:
>
> two-level:
>
> emc {
>    ...
>    emc-table at 190000 {
>        compatible = "nvidia,tegra20-emc-table";
>        ...
>    };
>    emc-table at 380000 {
>        compatible = "nvidia,tegra20-emc-table";
>        ...
>    };
> };
>
> three-level:
>
> emc {
>    ...
>    nvidia,use-ram-code;
>    emc-tables {
>        nvidia,ram-code = <0>;
>        emc-table at 190000 {
>            compatible = "nvidia,tegra20-emc-table";
>            ...
>        };
>        emc-table at 380000 {
>            compatible = "nvidia,tegra20-emc-table";
>            ...
>        };
>    };
>    emc-tables {
>        nvidia,ram-code = <1>;
>        emc-table at 190000 {
>            compatible = "nvidia,tegra20-emc-table";
>            ...
>        };
>        emc-table at 380000 {
>            compatible = "nvidia,tegra20-emc-table";
>            ...
>        };
>    };
> };
>
> Even if we don't fully implement support for both, we should detect the
> unsupported and flag an explicit error. But, it's pretty easy to support
> the other format.

OK I will look at which way to jump on this.

>
> BTW, does:
>
> +               node = fdtdec_next_compatible(blob, node,
> +                               COMPAT_NVIDIA_TEGRA20_EMC_TABLE);
>
> limit itself to searching child nodes?

No; I will add that to the docs.

Regards,
Simon

>
> --
> nvpublic


More information about the U-Boot mailing list